summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/include/llvm/Target/GenericOpcodes.td23
-rw-r--r--llvm/include/llvm/Target/Target.td13
2 files changed, 26 insertions, 10 deletions
diff --git a/llvm/include/llvm/Target/GenericOpcodes.td b/llvm/include/llvm/Target/GenericOpcodes.td
new file mode 100644
index 00000000000..2578c9d04f6
--- /dev/null
+++ b/llvm/include/llvm/Target/GenericOpcodes.td
@@ -0,0 +1,23 @@
+//===-- GenericOpcodes.td - Opcodes used with GlobalISel ---*- tablegen -*-===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file defines the generic opcodes used with GlobalISel.
+// After instruction selection, these opcodes should not appear.
+//
+//===----------------------------------------------------------------------===//
+
+// Generic addition.
+def G_ADD : Instruction {
+ let OutOperandList = (outs unknown:$dst);
+ let InOperandList = (ins unknown:$src1, unknown:$src2);
+ let AsmString = "";
+ let hasSideEffects = 0;
+ let isCommutable = 1;
+}
+// TODO: Add the other generic opcodes.
diff --git a/llvm/include/llvm/Target/Target.td b/llvm/include/llvm/Target/Target.td
index 2e8897df8e6..c5e8cfe5e9b 100644
--- a/llvm/include/llvm/Target/Target.td
+++ b/llvm/include/llvm/Target/Target.td
@@ -914,16 +914,9 @@ def FAULTING_LOAD_OP : Instruction {
let mayLoad = 1;
}
-// Generic opcode used by the IRTranslator.
-// After ISel, this opcode should not appear.
-def G_ADD : Instruction {
- let OutOperandList = (outs unknown:$dst);
- let InOperandList = (ins unknown:$src1, unknown:$src2);
- let AsmString = "";
- let hasSideEffects = 0;
- let isCommutable = 1;
-}
-// TODO: Add the other generic opcodes.
+// Generic opcodes used in GlobalISel.
+include "llvm/Target/GenericOpcodes.td"
+
}
//===----------------------------------------------------------------------===//
OpenPOWER on IntegriCloud