Previously every file that included Executable.h (which is pretty much
most LibJS and LibHTML files, given that VM.h needs it) had the whole
definition of LibRegex, which was slowing down source parsing.
Window.h is a rather heavy file, so let's try not to include it in
header files when we can!
Element.h now also includes LibWeb/Bindings/Intrinsics.h, but that's
just out of my laziness. Most if not all objects call
`Bindings::ensure_web_prototype<>()` anyway, so I don't think we would
gain much by sticking the header to source files instead.
We needed to keep the old versions of these functions around before all
of the IDL interfaces were ported over to new AK String, but now that is
done, we can remove the deprecated versions of these functions.
When we hit the cache in GetGlobal, we don't need the identifier string
at all, so let's defer fetching it until after the cache miss.
7% speed-up on Kraken/imaging-gaussian-blur.js :^)
We were incorrectly offsetting the static position of abspos children of
flex containers by the padding twice. This was a misguided attempt to
adjust to the abspos containing block being the padding box, not the
content box.
Fixes#21344.
Also remove the hack for SVG documents, a well-formed SVG document has
the correct xmlns attribute set, which should be automatically picked up
by the builder now.
If we have a cached environment coordinate that hasn't been screwed
by eval(), we can get the value directly without instantiating a
Reference.
15% speed-up on Octane/zlib.js :^)
The POSIX specification for `find` says that: "Each path operand shall
be evaluated unaltered as it was provided, including all trailing
<slash> characters". This also matches the behavior of `find` on
FreeBSD and Linux.
The functions for registering and unregistering MarkedVector, Handle,
etc. were quite prominent in benchmark profiles.
4% speed-up on the entire Kraken benchmark :^)
(including: 7% speed-up on Kraken/imaging-gaussian-blur.js, the current
slowest subtest)
There were some unhandled paths due to the liberally typed XHR response
object. This patch flushes out those issues by using a tighter type set
in the Variant. (NonnullGCPtr<Object> instead of Value)
These functions all have a very common case that can be dealt with a
very simple inline check, often avoiding the need to call an out-of-line
function. This patch moves the common case to inline functions in a new
ValueInlines.h header (necessary due to header dependency issues..)
8% speed-up on the entire Kraken benchmark :^)
Replaces `set_tooltip_deprecated(string);` with
`set_tooltip(MUST(String::from_deprecated_string(string)));`
purely to get rid of the deprecated function in the following commit.