diff options
author | Konstantin Tokarev <annulen@yandex.ru> | 2016-08-25 19:20:41 +0300 |
---|---|---|
committer | Konstantin Tokarev <annulen@yandex.ru> | 2017-02-02 12:30:55 +0000 |
commit | 6882a04fb36642862b11efe514251d32070c3d65 (patch) | |
tree | b7959826000b061fd5ccc7512035c7478742f7b0 /Source/JavaScriptCore/offlineasm/instructions.rb | |
parent | ab6df191029eeeb0b0f16f127d553265659f739e (diff) | |
download | qtwebkit-6882a04fb36642862b11efe514251d32070c3d65.tar.gz |
Imported QtWebKit TP3 (git b57bc6801f1876c3220d5a4bfea33d620d477443)
Change-Id: I3b1d8a2808782c9f34d50240000e20cb38d3680f
Reviewed-by: Konstantin Tokarev <annulen@yandex.ru>
Diffstat (limited to 'Source/JavaScriptCore/offlineasm/instructions.rb')
-rw-r--r-- | Source/JavaScriptCore/offlineasm/instructions.rb | 46 |
1 files changed, 33 insertions, 13 deletions
diff --git a/Source/JavaScriptCore/offlineasm/instructions.rb b/Source/JavaScriptCore/offlineasm/instructions.rb index a54827ef8..244928746 100644 --- a/Source/JavaScriptCore/offlineasm/instructions.rb +++ b/Source/JavaScriptCore/offlineasm/instructions.rb @@ -22,6 +22,7 @@ # THE POSSIBILITY OF SUCH DAMAGE. require "config" +require "set" # Interesting invariant, which we take advantage of: branching instructions # always begin with "b", and no non-branching instructions begin with "b". @@ -29,6 +30,7 @@ require "config" MACRO_INSTRUCTIONS = [ + "emit", "addi", "andi", "lshifti", @@ -206,8 +208,6 @@ MACRO_INSTRUCTIONS = "tqs", "tqz", "tqnz", - "peekq", - "pokeq", "bqeq", "bqneq", "bqa", @@ -249,6 +249,7 @@ MACRO_INSTRUCTIONS = "bnz", "leai", "leap", + "memfence" ] X86_INSTRUCTIONS = @@ -259,10 +260,23 @@ X86_INSTRUCTIONS = ARM_INSTRUCTIONS = [ - "smulli", - "addis", - "subis", - "oris" + "clrbp", + "mvlbl" + ] + +ARM64_INSTRUCTIONS = + [ + "pcrtoaddr", # Address from PC relative offset - adr instruction + "nopFixCortexA53Err835769" # nop on Cortex-A53 (nothing otherwise) + ] + +RISC_INSTRUCTIONS = + [ + "smulli", # Multiply two 32-bit words and produce a 64-bit word + "addis", # Add integers and set a flag. + "subis", # Same, but for subtraction. + "oris", # Same, but for bitwise or. + "addps" # addis but for pointers. ] MIPS_INSTRUCTIONS = @@ -270,6 +284,7 @@ MIPS_INSTRUCTIONS = "la", "movz", "movn", + "setcallreg", "slt", "sltu", "pichdr" @@ -277,6 +292,9 @@ MIPS_INSTRUCTIONS = SH4_INSTRUCTIONS = [ + "flushcp", + "alignformova", + "mova", "shllx", "shlrx", "shld", @@ -285,15 +303,17 @@ SH4_INSTRUCTIONS = "loaddReversedAndIncrementAddress", "storedReversedAndDecrementAddress", "ldspr", - "stspr" + "stspr", + "setargs" ] CXX_INSTRUCTIONS = [ - "cloopCrash", # no operands - "cloopCallJSFunction", # operands: callee - "cloopCallNative", # operands: callee - "cloopCallSlowPath", # operands: callTarget, currentFrame, currentPC + "cloopCrash", # no operands + "cloopCallJSFunction", # operands: callee + "cloopCallNative", # operands: callee + "cloopCallSlowPath", # operands: callTarget, currentFrame, currentPC + "cloopCallSlowPathVoid", # operands: callTarget, currentFrame, currentPC # For debugging only: # Takes no operands but simply emits whatever follows in // comments as @@ -304,9 +324,9 @@ CXX_INSTRUCTIONS = "cloopDo", # no operands ] -INSTRUCTIONS = MACRO_INSTRUCTIONS + X86_INSTRUCTIONS + ARM_INSTRUCTIONS + MIPS_INSTRUCTIONS + SH4_INSTRUCTIONS + CXX_INSTRUCTIONS +INSTRUCTIONS = MACRO_INSTRUCTIONS + X86_INSTRUCTIONS + ARM_INSTRUCTIONS + ARM64_INSTRUCTIONS + RISC_INSTRUCTIONS + MIPS_INSTRUCTIONS + SH4_INSTRUCTIONS + CXX_INSTRUCTIONS -INSTRUCTION_PATTERN = Regexp.new('\\A((' + INSTRUCTIONS.join(')|(') + '))\\Z') +INSTRUCTION_SET = INSTRUCTIONS.to_set def isBranch(instruction) instruction =~ /^b/ |