From f5754a011dd9b23a30f4f50dfe680a53b093c5bd Mon Sep 17 00:00:00 2001 From: Christian Konig Date: Thu, 21 Feb 2013 15:17:09 +0000 Subject: [PATCH] R600/SI: rework VOP3 classes MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Order the classes and add asm operands. Signed-off-by: Christian König Reviewed-by: Tom Stellard Reviewed-by: Michel Dänzer llvm-svn: 175751 --- llvm/lib/Target/R600/SIInstrInfo.td | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/llvm/lib/Target/R600/SIInstrInfo.td b/llvm/lib/Target/R600/SIInstrInfo.td index 0808f24..05325db 100644 --- a/llvm/lib/Target/R600/SIInstrInfo.td +++ b/llvm/lib/Target/R600/SIInstrInfo.td @@ -127,20 +127,6 @@ multiclass SMRD_Helper op, string asm, RegisterClass dstClass> { // Vector ALU classes //===----------------------------------------------------------------------===// -class VOP3_32 op, string opName, list pattern> : VOP3 < - op, (outs VReg_32:$dst), - (ins VSrc_32:$src0, VReg_32:$src1, VReg_32:$src2, i32imm:$src3, - i32imm:$src4, i32imm:$src5, i32imm:$src6), - opName, pattern ->; - -class VOP3_64 op, string opName, list pattern> : VOP3 < - op, (outs VReg_64:$dst), - (ins VSrc_64:$src0, VReg_64:$src1, VReg_64:$src2, - i32imm:$src3, i32imm:$src4, i32imm:$src5, i32imm:$src6), - opName, pattern ->; - multiclass VOP1_Helper op, RegisterClass drc, RegisterClass src, string opName, list pattern> { @@ -224,6 +210,20 @@ multiclass VOPC_64 op, string opName, ValueType vt = untyped, PatLeaf cond = COND_NULL> : VOPC_Helper ; +class VOP3_32 op, string opName, list pattern> : VOP3 < + op, (outs VReg_32:$dst), + (ins VSrc_32:$src0, VReg_32:$src1, VReg_32:$src2, + i32imm:$abs, i32imm:$clamp, i32imm:$omod, i32imm:$neg), + opName#" $dst, $src0, $src1, $src2, $abs, $clamp, $omod, $neg", pattern +>; + +class VOP3_64 op, string opName, list pattern> : VOP3 < + op, (outs VReg_64:$dst), + (ins VSrc_64:$src0, VReg_64:$src1, VReg_64:$src2, + i32imm:$abs, i32imm:$clamp, i32imm:$omod, i32imm:$neg), + opName#" $dst, $src0, $src1, $src2, $abs, $clamp, $omod, $neg", pattern +>; + //===----------------------------------------------------------------------===// // Vector I/O classes //===----------------------------------------------------------------------===// -- 2.7.4