[webkit-reviews] review granted: [Bug 69734] Improve Null or Undefined test in 32_64 DFG : [Attachment 110315] the patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Oct 9 19:27:24 PDT 2011


Darin Adler <darin at apple.com> has granted Yuqiang Xian
<yuqiang.xian at intel.com>'s request for review:
Bug 69734: Improve Null or Undefined test in 32_64 DFG
https://bugs.webkit.org/show_bug.cgi?id=69734

Attachment 110315: the patch
https://bugs.webkit.org/attachment.cgi?id=110315&action=review

------- Additional Comments from Darin Adler <darin at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=110315&action=review


> Source/JavaScriptCore/dfg/DFGJITCodeGenerator32_64.cpp:1178
> +	   ASSERT((JSValue::UndefinedTag + 1 == JSValue::NullTag) &&
(JSValue::NullTag & 0x1));

This assertion is written in an oblique way and could instead be written to
directly mirror what the code relies on:

    COMPILE_ASSERT((JSValue::UndefinedTag | 1) == JSValue::NullTag);

> Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp:460
> +    ASSERT((JSValue::UndefinedTag + 1 == JSValue::NullTag) &&
(JSValue::NullTag & 0x1));

Ditto.

> Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp:560
> +    ASSERT((JSValue::UndefinedTag + 1 == JSValue::NullTag) &&
(JSValue::NullTag & 0x1));

Ditto.


More information about the webkit-reviews mailing list