[webkit-reviews] review granted: [Bug 190751] [JSC] sub op with 0 should be optimized : [Attachment 359653] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jan 21 10:08:34 PST 2019


Mark Lam <mark.lam at apple.com> has granted Yusuke Suzuki <ysuzuki at apple.com>'s
request for review:
Bug 190751: [JSC] sub op with 0 should be optimized
https://bugs.webkit.org/show_bug.cgi?id=190751

Attachment 359653: Patch

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




--- Comment #7 from Mark Lam <mark.lam at apple.com> ---
Comment on attachment 359653
  --> https://bugs.webkit.org/attachment.cgi?id=359653
Patch

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

r=me

> Source/JavaScriptCore/offlineasm/arm64.rb:506
> +		   unless operands[0] == operands[2]

Why not express this as "if operands[0] != operands[2]"?

> Source/JavaScriptCore/offlineasm/x86.rb:794
> +		   unless operands[0] == operands[2]

Why not express this as "if operands[0] != operands[2]"?

> Source/JavaScriptCore/offlineasm/x86.rb:801
> +		   $asm.puts "add#{x86Suffix(kind)}
#{orderOperands(operands[0].x86Operand(kind), operands[2].x86Operand(kind))}"

For completeness, you can make this line conditional on "if Immediate.new(nil,
0) != operands[0]".


More information about the webkit-reviews mailing list