diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:41:05 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:41:05 +0000 |
commit | 01095a5d43bbfde13731688ddcf6048ebb8b7721 (patch) | |
tree | 4def12e759965de927d963ac65840d663ef9d1ea /include/llvm/Target/GenericOpcodes.td | |
parent | f0f4822ed4b66e3579e92a89f368f8fb860e218e (diff) |
Diffstat (limited to 'include/llvm/Target/GenericOpcodes.td')
-rw-r--r-- | include/llvm/Target/GenericOpcodes.td | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/include/llvm/Target/GenericOpcodes.td b/include/llvm/Target/GenericOpcodes.td new file mode 100644 index 0000000000000..b4d95508f0a50 --- /dev/null +++ b/include/llvm/Target/GenericOpcodes.td @@ -0,0 +1,46 @@ +//===-- 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. +// +//===----------------------------------------------------------------------===// + +//------------------------------------------------------------------------------ +// Binary ops. +//------------------------------------------------------------------------------ +// Generic addition. +def G_ADD : Instruction { + let OutOperandList = (outs unknown:$dst); + let InOperandList = (ins unknown:$src1, unknown:$src2); + let hasSideEffects = 0; + let isCommutable = 1; +} + +// Generic bitwise or. +def G_OR : Instruction { + let OutOperandList = (outs unknown:$dst); + let InOperandList = (ins unknown:$src1, unknown:$src2); + let hasSideEffects = 0; + let isCommutable = 1; +} + +//------------------------------------------------------------------------------ +// Branches. +//------------------------------------------------------------------------------ +// Generic unconditional branch. +def G_BR : Instruction { + let OutOperandList = (outs); + let InOperandList = (ins unknown:$src1); + let hasSideEffects = 0; + let isBranch = 1; + let isTerminator = 1; +} + +// TODO: Add the other generic opcodes. |