mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-19 08:15:31 +00:00
b2c3ca5adb
This means that our binary does not need to include concatenated strings such as "set CanvasRenderingContext2D.fillStyle". It only needs to contain the individual strings "CanvasRenderingContext2D" and "fillStyle" which are most likely already present in the binary. This change reduces the binary size on macOS x64 by around 200KB. Here's a diff of the impact on the code generated for Attr_Binding::get_specified in the Mac build. This change makes us generate slightly more code, which is very much offset by the reduction in the amount of strings we ship. @@ -15,22 +15,23 @@ movl 0x10(%rbx), %r12d cmpl (%rbx), %r12d jae loc_xxxxx movq 0x8(%rbx), %rax movq %r12, %rcx shlq $0x5, %rcx - leaq aGetAttrspecifi, %rdx ; "get Attr.specified" + leaq aAttr, %rdx ; "Attr" movq %rdx, (%rax,%rcx) - movq $0x0, 0x8(%rax,%rcx) + leaq aSpecified, %rdx ; "specified" + movq %rdx, 0x8(%rax,%rcx) leaq -40(%rbp), %rdx movq %rdx, 0x10(%rax,%rcx) - movl $0x71, 0x1c(%rax,%rcx) + movl $0x3a1, 0x1c(%rax,%rcx) leal 0x1(%r12), %eax movl %eax, 0x10(%rbx) movq %r15, %rdi call __ZNK7mozilla3dom4Attr9SpecifiedEv ; mozilla::dom::Attr::Specified() const movzxl %al, %eax movabsq $0xfff9000000000000, %rcx orq %rax, %rcx Depends on D9204 Differential Revision: https://phabricator.services.mozilla.com/D9205 --HG-- extra : moz-landing-system : lando |
||
---|---|---|
.. | ||
crashtests | ||
docs | ||
mozwebidlcodegen | ||
parser | ||
test | ||
AtomList.h | ||
BindingDeclarations.h | ||
Bindings.conf | ||
BindingUtils.cpp | ||
BindingUtils.h | ||
CallbackFunction.h | ||
CallbackInterface.cpp | ||
CallbackInterface.h | ||
CallbackObject.cpp | ||
CallbackObject.h | ||
Codegen.py | ||
Configuration.py | ||
Date.cpp | ||
Date.h | ||
DOMJSClass.h | ||
DOMJSProxyHandler.cpp | ||
DOMJSProxyHandler.h | ||
DOMString.h | ||
ErrorIPCUtils.h | ||
ErrorResult.h | ||
Errors.msg | ||
Exceptions.cpp | ||
Exceptions.h | ||
FakeString.h | ||
GenerateCSS2PropertiesWebIDL.py | ||
IterableIterator.cpp | ||
IterableIterator.h | ||
JSSlots.h | ||
mach_commands.py | ||
Makefile.in | ||
moz.build | ||
NonRefcountedDOMObject.h | ||
nsIScriptError.idl | ||
nsScriptError.cpp | ||
nsScriptError.h | ||
nsScriptErrorWithStack.cpp | ||
Nullable.h | ||
PrimitiveConversions.h | ||
ReadableStream.h | ||
Record.h | ||
RootedDictionary.h | ||
RootedOwningNonNull.h | ||
RootedRefPtr.h | ||
SimpleGlobalObject.cpp | ||
SimpleGlobalObject.h | ||
SpiderMonkeyInterface.h | ||
StructuredClone.cpp | ||
StructuredClone.h | ||
ToJSValue.cpp | ||
ToJSValue.h | ||
TypedArray.h | ||
UnionMember.h | ||
WebIDLGlobalNameHash.cpp | ||
WebIDLGlobalNameHash.h | ||
XrayExpandoClass.h |