diff options
author | Dan Gohman <dan433584@gmail.com> | 2016-10-25 16:55:52 +0000 |
---|---|---|
committer | Dan Gohman <dan433584@gmail.com> | 2016-10-25 16:55:52 +0000 |
commit | f50d964bdb0674db3e7f18d06a2d1964e0dbd731 (patch) | |
tree | 2deb35973b98edbdd41cadfef6871e2f6e27dcaa /llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td | |
parent | c1472b509202b168e9a4b4a468eaa4a12769a38d (diff) | |
download | bcm5719-llvm-f50d964bdb0674db3e7f18d06a2d1964e0dbd731.tar.gz bcm5719-llvm-f50d964bdb0674db3e7f18d06a2d1964e0dbd731.zip |
[WebAssembly] Add immediate fields to call_indirect and memory operators.
call_indirect, grow_memory, and current_memory now have immediate
operands in the 0xd binary encoding.
llvm-svn: 285085
Diffstat (limited to 'llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td')
-rw-r--r-- | llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td b/llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td index f4906e9fca2..41bfcbc9e0e 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td +++ b/llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td @@ -35,7 +35,8 @@ multiclass CALL<WebAssemblyRegClass vt, string prefix> { [(set vt:$dst, (WebAssemblycall1 I32:$callee))], "PSEUDO CALL INDIRECT\t$callee">; } // isCodeGenOnly = 1 - def CALL_INDIRECT_#vt : I<(outs vt:$dst), (ins variable_ops), + + def CALL_INDIRECT_#vt : I<(outs vt:$dst), (ins i32imm:$flags, variable_ops), [], !strconcat(prefix, "call_indirect\t$dst"), 0x11>; @@ -54,8 +55,9 @@ multiclass SIMD_CALL<ValueType vt, string prefix> { (WebAssemblycall1 I32:$callee))], "PSEUDO CALL INDIRECT\t$callee">; } // isCodeGenOnly = 1 + def CALL_INDIRECT_#vt : SIMD_I<(outs V128:$dst), - (ins variable_ops), + (ins i32imm:$flags, variable_ops), [], !strconcat(prefix, "call_indirect\t$dst"), 0x11>; @@ -79,7 +81,8 @@ let Uses = [SP32, SP64], isCall = 1 in { [(WebAssemblycall0 I32:$callee)], "PSEUDO CALL INDIRECT\t$callee">; } // isCodeGenOnly = 1 - def CALL_INDIRECT_VOID : I<(outs), (ins variable_ops), + + def CALL_INDIRECT_VOID : I<(outs), (ins i32imm:$flags, variable_ops), [], "call_indirect\t", 0x11>; } // Uses = [SP32,SP64], isCall = 1 |