summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibX86
AgeCommit message (Collapse)Author
2021-06-11AK+LibX86: Generalize u128/256 to AK::UFixedBigIntHendiadyoin1
Doing these as custom classes might be faster, especially when writing them in SSE, but this would cause a lot of Code duplication and due to the nature of constexprs and the intelligence of the compiler they might be using SSE/MMX either way
2021-05-31LibX86: Replace fprintf(stderr) with warnln()Linus Groh
2021-05-21Revert "Userland: static vs non-static constexpr variables"Linus Groh
This reverts commit 800ea8ea969835297dc7e7da345a45b9dc5e751a. Booting the system no longer worked after these changes.
2021-05-21Userland: static vs non-static constexpr variablesLenny Maiorani
Problem: - `static` variables consume memory and sometimes are less optimizable. - `static const` variables can be `constexpr`, usually. - `static` function-local variables require an initialization check every time the function is run. Solution: - If a global `static` variable is only used in a single function then move it into the function and make it non-`static` and `constexpr`. - Make all global `static` variables `constexpr` instead of `const`. - Change function-local `static const[expr]` variables to be just `constexpr`.
2021-05-07LibX86: Convert StringBuilder::appendf() => AK::FormatAndreas Kling
2021-05-01LibX86+UserspaceEmulator: Add MMX insns prototypesHendiadyoin1
2021-04-29Everywhere: Use "the SerenityOS developers." in copyright headersLinus Groh
We had some inconsistencies before: - Sometimes "The", sometimes "the" - Sometimes trailing ".", sometimes no trailing "." I picked the most common one (lowecase "the", trailing ".") and applied it to all copyright headers. By using the exact same string everywhere we can ensure nothing gets missed during a global search (and replace), and that these inconsistencies are not spread any further (as copyright headers are commonly copied to new files).
2021-04-23UE+LibX86: Support bigger reads and writesHendiadyoin1
2021-04-23LibX86: Add basic u128 and u256 constainersHendiadyoin1
These support all bitwise operations
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-04-21LibX86: Convert String::format() => String::formatted()Andreas Kling
2021-04-15Everything: Add `-Wnon-virtual-dtor` flagNicholas-Baron
This flag warns on classes which have `virtual` functions but do not have a `virtual` destructor. This patch adds both the flag and missing destructors. The access level of the destructors was determined by a two rules of thumb: 1. A destructor should have a similar or lower access level to that of a constructor. 2. Having a `private` destructor implicitly deletes the default constructor, which is probably undesirable for "interface" types (classes with only virtual functions and no data). In short, most of the added destructors are `protected`, unless the compiler complained about access.
2021-04-10AK+Everywhere: Make StdLibExtras templates less wrapper-yAnotherTest
This commit makes the user-facing StdLibExtras templates and utilities arguably more nice-looking by removing the need to reach into the wrapper structs generated by them to get the value/type needed. The C++ standard library had to invent `_v` and `_t` variants (likely because of backwards compat), but we don't need to cater to any codebase except our own, so might as well have good things for free. :^)
2021-03-09LibX86: Don't use "if (foo) [[unlikely]] { }" for now (to please clang)Andreas Kling
2021-03-09UserspaceEmulator+LibX86: Sprinkle some [[unlikely]] and ALWAYS_INLINEAndreas Kling
2021-02-23Everywhere: Rename ASSERT => VERIFYAndreas Kling
(...and ASSERT_NOT_REACHED => VERIFY_NOT_REACHED) Since all of these checks are done in release builds as well, let's rename them to VERIFY to prevent confusion, as everyone is used to assertions being compiled out in release. We can introduce a new ASSERT macro that is specifically for debug checks, but I'm doing this wholesale conversion first since we've accumulated thousands of these already, and it's not immediately obvious which ones are suitable for ASSERT.
2021-02-02LibX86: Don't assert just because insn has no immediate bytesAndreas Kling
It's perfectly fine to not have immediate bytes. Many insns don't :^)
2021-01-31LibX86: sanity check for Instruction read sizeThomas Mangin
During "Emulator hacking: Let's make the userspace emulator go faster!", the switch implented in read() was inlined (toward the end of the video). This patch restore the assert check for any read other than 8, 16 or 32 bits was lost during the code conversion.
2021-01-22Libraries: Add missing headersBen Wiederhake
A C++ source file containing just #include <LibFoo/Bar.h> should always compile cleanly. This patch adds missing header inclusions that could have caused weird error messages if they were used in a different context. Also, this confused QtCreator.
2021-01-12Libraries: Move to Userland/Libraries/Andreas Kling