diff options
| author | Ulrich Weigand <ulrich.weigand@de.ibm.com> | 2016-04-11 14:35:39 +0000 |
|---|---|---|
| committer | Ulrich Weigand <ulrich.weigand@de.ibm.com> | 2016-04-11 14:35:39 +0000 |
| commit | 1bac911c580d803a4ff3a14e9ac9c3acbe921744 (patch) | |
| tree | 3cc09a6d9b8ce884d1883df8ef25da39f3010e41 /llvm/lib | |
| parent | 3b425ff232d69ab7326c8d0d43d5485a15e7911b (diff) | |
| download | bcm5719-llvm-1bac911c580d803a4ff3a14e9ac9c3acbe921744.tar.gz bcm5719-llvm-1bac911c580d803a4ff3a14e9ac9c3acbe921744.zip | |
[SystemZ] Add SVC instruction
This is going to be useful for inline assembly only.
Author: koriakin
Differential Revision: http://reviews.llvm.org/D18952
llvm-svn: 265943
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/SystemZ/SystemZInstrFormats.td | 11 | ||||
| -rw-r--r-- | llvm/lib/Target/SystemZ/SystemZInstrInfo.td | 4 |
2 files changed, 15 insertions, 0 deletions
diff --git a/llvm/lib/Target/SystemZ/SystemZInstrFormats.td b/llvm/lib/Target/SystemZ/SystemZInstrFormats.td index 3a81ed06089..24618a1c8cc 100644 --- a/llvm/lib/Target/SystemZ/SystemZInstrFormats.td +++ b/llvm/lib/Target/SystemZ/SystemZInstrFormats.td @@ -158,6 +158,17 @@ def getThreeOperandOpcode : InstrMapping { // //===----------------------------------------------------------------------===// +class InstI<bits<8> op, dag outs, dag ins, string asmstr, list<dag> pattern> + : InstSystemZ<2, outs, ins, asmstr, pattern> { + field bits<16> Inst; + field bits<16> SoftFail = 0; + + bits<8> I1; + + let Inst{15-8} = op; + let Inst{7-0} = I1; +} + class InstRI<bits<12> op, dag outs, dag ins, string asmstr, list<dag> pattern> : InstSystemZ<4, outs, ins, asmstr, pattern> { field bits<32> Inst; diff --git a/llvm/lib/Target/SystemZ/SystemZInstrInfo.td b/llvm/lib/Target/SystemZ/SystemZInstrInfo.td index 3628aa0a6ff..72833628b32 100644 --- a/llvm/lib/Target/SystemZ/SystemZInstrInfo.td +++ b/llvm/lib/Target/SystemZ/SystemZInstrInfo.td @@ -1570,6 +1570,10 @@ let mayLoad = 1, Defs = [CC] in defm SRST : StringRRE<"srst", 0xb25e, z_search_string>; // Other instructions for inline assembly +let hasSideEffects = 1, Defs = [CC], isCall = 1 in + def SVC : InstI<0x0A, (outs), (ins imm32zx8:$I1), + "svc\t$I1", + []>; let hasSideEffects = 1, Defs = [CC], mayStore = 1 in def STCK : InstS<0xB205, (outs), (ins bdaddr12only:$BD2), "stck\t$BD2", |

