On Wed, Jul 30, 2014 at 3:59 PM, Boris Zbarsky <[email protected]> wrote:

> In SpiderMonkey, I'd think the !== version ends up with a getprop IC at
> worst and a direct slot load at best, followed by whatever the !== does (if
> we're lucky, just a tag test).
>

FWIW, it's a direct slot load and the !== will be folded because we end up
with int32 !== undefined. But as you said, here it's just DCE so it doesn't
really matter :) The compiler will also fold typeof int32 -> "number" and
then "number" !== "undefined".

Jan
_______________________________________________
dev-tech-js-engine-internals mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-js-engine-internals

Reply via email to