Ignore:
Timestamp:
Nov 2, 2019, 1:12:38 PM (6 years ago)
Author:
[email protected]
Message:

The offline assembler is wrong about which immediates are supported by and/or/xor on ARM64
https://bugs.webkit.org/show_bug.cgi?id=203752

Reviewed by Tadeu Zagallo.

See https://dinfuehr.github.io/blog/encoding-of-immediate-values-on-aarch64/ for the details of which immediates are supported.
This patch is a minimal fix, ideally we should refactor all of the code dealing with immediates in risc.rb, but considering that I don't know ruby and this code is poorly/not tested, I went for the simplest possible fix.

  • offlineasm/arm64.rb:
  • offlineasm/mips.rb:
  • offlineasm/risc.rb:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/offlineasm/mips.rb

    r251893 r251966  
    730730        result = riscLowerMisplacedImmediates(result, ["storeb", "storei", "storep"])
    731731        result = mipsLowerMisplacedImmediates(result)
    732         result = riscLowerMalformedImmediates(result, -0x7fff..0x7fff)
     732        result = riscLowerMalformedImmediates(result, -0x7fff..0x7fff, -0x7fff..0x7fff)
    733733        result = mipsLowerMisplacedAddresses(result)
    734734        result = riscLowerMisplacedAddresses(result)
Note: See TracChangeset for help on using the changeset viewer.