Commit graph

56316 commits

Author SHA1 Message Date
Sönke Holz
da88d766b2 Kernel/riscv64: Make the kernel compile
This commits inserts TODOs into all necessary places to make the kernel
compile on riscv64!
2023-11-10 15:51:31 -07:00
Sönke Holz
b6ac2ed34d Kernel/riscv64: Implement RISC-V SmapDisabler 2023-11-10 15:51:31 -07:00
Sönke Holz
cb1b0c4101 Kernel/riscv64: Add initial PageDirectory header 2023-11-10 15:51:31 -07:00
Sönke Holz
fd8858ace2 Kernel/riscv64: Add RISC-V Syscall API 2023-11-10 15:51:31 -07:00
Sönke Holz
6824d2a788 Userland+Tests: Add initial riscv64 support 2023-11-10 10:30:08 -07:00
Michiel Visser
c6b2a07326 LibCrypto: Add static_assert to check that A = -3 mod p
This is required for some optimization made in the file. While this
should always be the case for the SECP256r1 curve, it is good to check
it anyway.
2023-11-10 09:54:00 -07:00
Michiel Visser
4f4034d1a4 LibCrypto: Also check Z when checking if point is on the curve 2023-11-10 09:54:00 -07:00
Michiel Visser
399dc211fa LibCrypto: Use simplified u256 constructor when reading big endian data 2023-11-10 09:54:00 -07:00
Michiel Visser
153cd3ecf0 LibCrypto: Use square-and-multiply loop for modular_inverse
Instead of using the hand unrolled version of the square-and-multiply
algorithm, we now simply use a loop.
2023-11-10 09:54:00 -07:00
Michiel Visser
5b658c341c LibCrypto: Change modular_add_order to match modular_add 2023-11-10 09:54:00 -07:00
Michiel Visser
d746c01716 LibCrypto: Simplify modular addition and subtraction
Instead of building the REDUCE_PRIME constant on the fly from the carry
flag, we now simply use the constant in combination with select. This
improves the readablility of the functions significantly.
2023-11-10 09:54:00 -07:00
Michiel Visser
5da070ba5e LibCrypto: Remove many magic constants and calculate them instead
Instead of having a large list of magical constants, we now only have
the curve prime, a, b, and order, which are all taken from the
specification. All the other helper constants are now calculated from
the curve paramters.
2023-11-10 09:54:00 -07:00
Nico Weber
323ba7404c LibPDF: Implement SampledFunction::evaluate() for some sampled functions
Things now work for functions that are all of:
* linear
* 1-D input
* 8 bits per sample
2023-11-10 15:03:30 +00:00
Nico Weber
fd1876441a LibPDF: Implement SampledFunction::create() 2023-11-10 15:03:30 +00:00
Andreas Kling
2520c46224 LibJS/JIT: Resolve the GetCalleeAndThisFromEnvironment cache at JIT time 2023-11-10 14:49:25 +01:00
Nico Weber
8f4966fc5c test_pdf.py: Output tweaks
* Count files that are password-protected
* Use `pdf --json` to groups by missing feature and then by file
  instead of by file first, feature second
* Count files that render with issues
* Print number of files without issues last
* Always print all crash stacks
2023-11-10 14:46:06 +01:00
Nico Weber
ed7549c64f pdf: Add a --json flag that currently affects only --debugging-stats 2023-11-10 14:46:06 +01:00
Nico Weber
cd9f4655ec LibPDF: Tweak implementation of postscript roll op
Since positive offsets roll to the right, it makes more sense
to do the big reverse first. Gets rid of an awkward minus sign.

No behavior change.
2023-11-10 14:45:38 +01:00
Nico Weber
b23ed86889 LibPDF: Implement StitchingFunction::evaluate() 2023-11-10 14:45:16 +01:00
Nico Weber
ba34ddeb21 LibPDF: Implement StitchingFunction creation 2023-11-10 14:45:16 +01:00
Simon Wanner
a3399fa13a LibJS/JIT: Expand Mul fast path to double & i32 combinations
Co-authored-by: Stephan Vedder <vedder@mbits.info>
2023-11-10 11:01:59 +01:00
Simon Wanner
867b8146cf LibJS/JIT: Expand Sub fast path to double & i32 combinations
Co-authored-by: Stephan Vedder <vedder@mbits.info>
2023-11-10 11:01:59 +01:00
Simon Wanner
5edab2679c LibJS/JIT: Expand Add fast path to double & i32 combinations
Co-authored-by: Stephan Vedder <vedder@mbits.info>
2023-11-10 11:01:59 +01:00
Simon Wanner
d91b376393 LibJS/JIT: Add helper for generating combined i32 & double fastpaths
Co-authored-by: Stephan Vedder <vedder@mbits.info>
2023-11-10 11:01:59 +01:00
Simon Wanner
578912aa6c LibJIT: Support unordered double comparison 2023-11-10 11:01:59 +01:00
Simon Wanner
a698c51a5b LibJIT: Add floating-point registers
Co-authored-by: Stephan Vedder <vedder@mbits.info>
2023-11-10 11:01:59 +01:00
Simon Wanner
5557f05bb5 LibX86: Support decoding F2 SSE instructions
Previously the F2 table was generated, but not used by the instruction
decoder.
2023-11-10 11:01:59 +01:00
Andrew Kaster
a0d8990c82 CMake: Bump CMake minimum up to 3.21 to work around CLion bug
Fix the recursive directory bug in CLion Nova EAP's CMake version in a
way that doesn't also break `./Meta/serenity.sh run lagom ladybird`.

This brings the Lagom minimum required closer to the Serenity minimum
required. Which is still fine, because the serenity.sh script knows how
to build CMake from source if a developer's local copy is too old.
2023-11-10 09:36:22 +01:00
Ali Mohammad Pur
32e6fd9715 LibTLS: Do not defer flushing alert packets
There's a good chance the TLS socket instance will be deleted before the
deferred invocation fires, and there's no real reason to defer flushes
of alerts anyway as they are usually sent on errors.
Fixes #21800.
2023-11-10 09:02:58 +01:00
Andrew Kaster
7eda36bbf4 CMake: Don't recursively include Ladybird/Lagom in buggy CMake versions
Ran into this with the new EAP for CLion Nova. When using Ladybird as
source directory, we would recursively look in Ladybird --> Lagom -->
Ladybird when exporting components. This seems to be because
ENABLE_LAGOM_LADYBIRD is set to ON by Ladybird's CMakeLists and
something about their build, when invoked from their IDE, has buggy
behavior around the SUBDIRECTORIES directory property.
2023-11-10 08:32:12 +01:00
iliadsh
94b47ff03b LibJS: Add GetByValue fast path for simple array access 2023-11-10 08:22:44 +01:00
iliadsh
f91c3e9ac3 LibJS: Expose offset to m_indexed_properties 2023-11-10 08:22:44 +01:00
iliadsh
cb933a3e4a LibJS: Expose offset of m_array_size 2023-11-10 08:22:44 +01:00
iliadsh
32364d66aa LibJS: Expose offset of is_simple_storage 2023-11-10 08:22:44 +01:00
iliadsh
d9aebeb372 LibJS: Expose offset of elements in IndexedProperties 2023-11-10 08:22:44 +01:00
iliadsh
eb937631bb LibJS: Expose offset of may_interfere_with_indexed_property_access 2023-11-10 08:22:44 +01:00
iliadsh
ee4948b9e7 LibJS: Devirtualize is_simple_storage() 2023-11-10 08:22:44 +01:00
iliadsh
89da731aa6 LibJS+LibWeb: Devirtualize may_interfere_with_indexed_property_access() 2023-11-10 08:22:44 +01:00
david072
7f501d4d8a Taskbar/QuickLaunchWidget: Ensure config backwards compatibility
The QuickLaunchWidget can now also parse the old config format, so that
we stay compatible with the old format. After loading, it deletes the
old config values and saves them in the new format.
2023-11-09 23:35:52 +01:00
david072
620b3bd492 Taskbar/QuickLaunchWidget: Show a tooltip with the entry's name on hover 2023-11-09 23:35:52 +01:00
david072
2d29a96dbe Taskbar/QuickLaunchWidget: Small cleanup 2023-11-09 23:35:52 +01:00
david072
e100c1458a Taskbar/QuickLaunchWidget: Reorder methods to make .cpp and .h match
This makes it a bit easier to find things in my opinion.
2023-11-09 23:35:52 +01:00
david072
13b98d01c0 Taskbar/QuickLaunchWidget: Properly save Quick Launch Entries
The entries in the QuickLaunchWidget are now saved properly. This means
that the format with which they are saved needed to be changed, since we
now also need to store the order of the entries. To do this, the entries
are now saved using the following value format: "<index>:<path>". When
loading, we simply parse this structure out and sort by the index,
before parsing the path into `QuickLaunchEntry`s.
2023-11-09 23:35:52 +01:00
david072
84340c4ca7 Taskbar/QuickLaunchWidget: Allow reordering the entries :^)
You can now drag the entries in the QuickLaunchWidget to reorder them!
2023-11-09 23:35:52 +01:00
david072
63cac2839d Taskbar/QuickLaunchWidget: Do rendering ourselves
The QuickLaunchWidget now renders the buttons on its own, in preparation
for allowing the user to reorder the widget's entries.
2023-11-09 23:35:52 +01:00
david072
70f7c10ab9 Taskbar+WindowServer: Adding to Quick Launch via windows :^)
You can now add applications to Quick Launch via the context
menu option of their windows. Clicking it creates an event with the
stored PID of the process that created the window. The Taskbar receives
the event and tells the QuickLaunchWidget to add the PID, which then
gets the executable using /sys/kernel/processes. It also looks for an
AppFile using the name from the process object and if there is one, it
uses that, since it should contain a better formatted name.
2023-11-09 23:35:52 +01:00
david072
4386182be1 LibGUI+WindowServer: Store the source process' PID in the Window classes
The "Window" classes in LibGUI and WindowServer now store the PID of the
process that created the window. LibGUI's Window obtains the PID in the
constructor via getpid(), and passes it in Window::show() to
WindowServer via the create_window() IPC route. WindowServer then saves
it in its own Window class.
This allows us to find the process that created a window in order to add
process-specific actions to the window.
2023-11-09 23:35:52 +01:00
david072
124611b256 AppFile: Add helpers for dealing with AppFile paths 2023-11-09 23:35:52 +01:00
Nico Weber
5af6e1c042 LibPDF: Implement DeviceNColorSpace 2023-11-09 23:33:49 +01:00
Nico Weber
0f07049935 LibPDF: Add ColorSpaceFamily::operator==
No behavior change.
2023-11-09 23:33:49 +01:00