Title: [228604] trunk/Source/_javascript_Core
Revision
228604
Author
[email protected]
Date
2018-02-18 09:12:56 -0800 (Sun, 18 Feb 2018)

Log Message

Offlineasm/MIPS: immediates need to be within 16-bit signed values
https://bugs.webkit.org/show_bug.cgi?id=182890

Patch by Dominik Inführ <[email protected]> on 2018-02-18
Reviewed by Michael Catanzaro.

In Sequence.getModifiedListMIPS(), we allow immediate values within
the range -0xffff..0xffff for immediates (addresses and other
immediates), but then in Immediate.mipsOperand() and
Address.mipsOperand() we raise if immediate values are not within
-0x7fff..0x7fff. This is inconsistent, and broke compilation on mips
since r228552 made the VM structure bigger meaning we address values
with bigger offsets in llint. This change restricts the allowed range,
so that a separate load of the value is done for values outside of
that range.

* offlineasm/mips.rb:

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (228603 => 228604)


--- trunk/Source/_javascript_Core/ChangeLog	2018-02-18 10:02:40 UTC (rev 228603)
+++ trunk/Source/_javascript_Core/ChangeLog	2018-02-18 17:12:56 UTC (rev 228604)
@@ -1,3 +1,22 @@
+2018-02-18  Dominik Inführ  <[email protected]>
+
+        Offlineasm/MIPS: immediates need to be within 16-bit signed values
+        https://bugs.webkit.org/show_bug.cgi?id=182890
+
+        Reviewed by Michael Catanzaro.
+
+        In Sequence.getModifiedListMIPS(), we allow immediate values within
+        the range -0xffff..0xffff for immediates (addresses and other
+        immediates), but then in Immediate.mipsOperand() and
+        Address.mipsOperand() we raise if immediate values are not within
+        -0x7fff..0x7fff. This is inconsistent, and broke compilation on mips
+        since r228552 made the VM structure bigger meaning we address values
+        with bigger offsets in llint. This change restricts the allowed range,
+        so that a separate load of the value is done for values outside of
+        that range.
+
+        * offlineasm/mips.rb:
+
 2018-02-17  Darin Adler  <[email protected]>
 
         Web Inspector: get rid of remaining uses of OptOutput<T>

Modified: trunk/Source/_javascript_Core/offlineasm/mips.rb (228603 => 228604)


--- trunk/Source/_javascript_Core/offlineasm/mips.rb	2018-02-18 10:02:40 UTC (rev 228603)
+++ trunk/Source/_javascript_Core/offlineasm/mips.rb	2018-02-18 17:12:56 UTC (rev 228604)
@@ -713,7 +713,7 @@
         result = riscLowerMalformedAddresses(result) {
             | node, address |
             if address.is_a? Address
-                (-0xffff..0xffff).include? address.offset.value
+                (-0x7fff..0x7fff).include? address.offset.value
             else
                 false
             end
@@ -721,7 +721,7 @@
         result = riscLowerMalformedAddressesDouble(result)
         result = riscLowerMisplacedImmediates(result, ["storeb", "storei", "storep"])
         result = mipsLowerMisplacedImmediates(result)
-        result = riscLowerMalformedImmediates(result, -0xffff..0xffff)
+        result = riscLowerMalformedImmediates(result, -0x7fff..0x7fff)
         result = mipsLowerMisplacedAddresses(result)
         result = riscLowerMisplacedAddresses(result)
         result = riscLowerRegisterReuse(result)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to