[webkit-reviews] review granted: [Bug 183746] FunctionPtr should be passed by value. : [Attachment 336056] proposed patch.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 19 11:06:38 PDT 2018


JF Bastien <jfbastien at apple.com> has granted Mark Lam <mark.lam at apple.com>'s
request for review:
Bug 183746: FunctionPtr should be passed by value.
https://bugs.webkit.org/show_bug.cgi?id=183746

Attachment 336056: proposed patch.

https://bugs.webkit.org/attachment.cgi?id=336056&action=review




--- Comment #3 from JF Bastien <jfbastien at apple.com> ---
Comment on attachment 336056
  --> https://bugs.webkit.org/attachment.cgi?id=336056
proposed patch.

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

r=me with suggested assert.

> Source/JavaScriptCore/assembler/MacroAssemblerCodeRef.h:129
> +static_assert(sizeof(FunctionPtr) == sizeof(void*), "");

You probably also want std::is_trivially_copyable<FunctionPtr>::value so that
passing it by values is just a register thing.


More information about the webkit-reviews mailing list