[webkit-reviews] review granted: [Bug 224162] [JSC] Shrink some of Vectors in JSC : [Attachment 425113] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Apr 3 16:26:06 PDT 2021

Sam Weinig <sam at webkit.org> has granted Yusuke Suzuki <ysuzuki at apple.com>'s
request for review:
Bug 224162: [JSC] Shrink some of Vectors in JSC

Attachment 425113: Patch


--- Comment #4 from Sam Weinig <sam at webkit.org> ---
Comment on attachment 425113
  --> https://bugs.webkit.org/attachment.cgi?id=425113

View in context: https://bugs.webkit.org/attachment.cgi?id=425113&action=review

> Source/JavaScriptCore/bytecode/DeleteByStatus.cpp:137
> +	   result.shrinkToFit();

For cases like this, might it make sense to have

> Source/JavaScriptCore/heap/JITStubRoutineSet.cpp:129
>      m_routines.shrink(dstIndex);
> +    m_routines.shrinkToFit();

Could these be combined into to just m_routines.shrinkCapacity(dstIndex)?

More information about the webkit-reviews mailing list