mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 06:11:37 +00:00
d36e5a4ea5
Dictionaries that we never initialize with JS values don't need a full-featured Init() method. Instead, we output a cut-down Init() method that doesn't even take a JSContext and Value as argument, and skips as much work as it can. It uses constant-false for "is the value present?", but also, to avoid compilation errors due to use of `cx` and `val` in now-dead conversion code, it tells the native-to-JS conversion machinery that the value is always missing, which lets it skip most of the the work it would normally try to do and just output initialization to the default value. We only need to do this for members that have default values; the others either remain no-passed or are required members with no default-initialization behavior. This saves about 330KB of codesize on Linux64 without PGO and 285KB with PGO. Differential Revision: https://phabricator.services.mozilla.com/D48007 --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 | ||
RemoteObjectProxy.cpp | ||
RemoteObjectProxy.h | ||
RootedDictionary.h | ||
RootedOwningNonNull.h | ||
RootedRefPtr.h | ||
SimpleGlobalObject.cpp | ||
SimpleGlobalObject.h | ||
SpiderMonkeyInterface.h | ||
ToJSValue.cpp | ||
ToJSValue.h | ||
TypedArray.h | ||
UnionMember.h | ||
WebIDLGlobalNameHash.cpp | ||
WebIDLGlobalNameHash.h | ||
XrayExpandoClass.h |