Shrink UnlinkedFunctionExecutable more to put more instances in one MarkedBlock. Right now, 2 MarkedBlocks are allocated just after initialization of JSGlobalObject, and the second one only uses 8%. If we can shrink UnlinkedFunctionExecutable, we can make it only one MarkedBlock.
Created attachment 362197 [details] Patch
Comment on attachment 362197 [details] Patch Need to check the test. But it is strange because the test thinks source URL directive should be used even for function constructor.
Created attachment 362202 [details] Patch
Comment on attachment 362202 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=362202&action=review r=me > Source/JavaScriptCore/bytecode/UnlinkedFunctionExecutable.cpp:45 > +static_assert(sizeof(UnlinkedFunctionExecutable) <= 128, "UnlinkedFunctionExecutable should fit in a 128-byte cell to keep allocated block only one just after initializing JSGlobalObject."); I would rephrase the message as "UnlinkedFunctionExecutable should fit in a 128-byte cell to keep allocated blocks count to only one after initializing JSGlobalObject."
Comment on attachment 362202 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=362202&action=review Thank you! >> Source/JavaScriptCore/bytecode/UnlinkedFunctionExecutable.cpp:45 >> +static_assert(sizeof(UnlinkedFunctionExecutable) <= 128, "UnlinkedFunctionExecutable should fit in a 128-byte cell to keep allocated block only one just after initializing JSGlobalObject."); > > I would rephrase the message as "UnlinkedFunctionExecutable should fit in a 128-byte cell to keep allocated blocks count to only one after initializing JSGlobalObject." Sounds nice! Fixed.
Committed r241645: <https://trac.webkit.org/changeset/241645>
<rdar://problem/48136411>