[llvm] r214756 - R600/SI: Fix definitions for ds_read2 / ds_write2 instructions.

Matt Arsenault Matthew.Arsenault at amd.com
Mon Aug 4 11:49:22 PDT 2014


Author: arsenm
Date: Mon Aug  4 13:49:22 2014
New Revision: 214756

URL: http://llvm.org/viewvc/llvm-project?rev=214756&view=rev
Log:
R600/SI: Fix definitions for ds_read2 / ds_write2 instructions.

These were just wrong, using the wrong register classes
and store2 was missing an operand.

Modified:
    llvm/trunk/lib/Target/R600/SIInstrInfo.td
    llvm/trunk/lib/Target/R600/SIInstructions.td

Modified: llvm/trunk/lib/Target/R600/SIInstrInfo.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/R600/SIInstrInfo.td?rev=214756&r1=214755&r2=214756&view=diff
==============================================================================
--- llvm/trunk/lib/Target/R600/SIInstrInfo.td (original)
+++ llvm/trunk/lib/Target/R600/SIInstrInfo.td Mon Aug  4 13:49:22 2014
@@ -818,7 +818,8 @@ class DS_Store_Helper <bits<8> op, strin
 class DS_Store2_Helper <bits<8> op, string asm, RegisterClass regClass> : DS_1A <
   op,
   (outs),
-  (ins i1imm:$gds, VReg_32:$addr, regClass:$data0, u8imm:$offset0, u8imm:$offset1),
+  (ins i1imm:$gds, VReg_32:$addr, regClass:$data0, regClass:$data1,
+       u8imm:$offset0, u8imm:$offset1),
   asm#" $addr, $data0, $data1, $offset0, $offset1 [M0]",
   []> {
   let mayStore = 1;

Modified: llvm/trunk/lib/Target/R600/SIInstructions.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/R600/SIInstructions.td?rev=214756&r1=214755&r2=214756&view=diff
==============================================================================
--- llvm/trunk/lib/Target/R600/SIInstructions.td (original)
+++ llvm/trunk/lib/Target/R600/SIInstructions.td Mon Aug  4 13:49:22 2014
@@ -826,8 +826,8 @@ def DS_READ_U16 : DS_Load_Helper <0x0000
 def DS_READ_B64 : DS_Load_Helper <0x00000076, "DS_READ_B64", VReg_64>;
 
 // 2 forms.
-def DS_WRITE2_B32 : DS_Load2_Helper <0x0000000E, "DS_WRITE2_B32", VReg_64>;
-def DS_WRITE2_B64 : DS_Load2_Helper <0x0000004E, "DS_WRITE2_B64", VReg_128>;
+def DS_WRITE2_B32 : DS_Store2_Helper <0x0000000E, "DS_WRITE2_B32", VReg_32>;
+def DS_WRITE2_B64 : DS_Store2_Helper <0x0000004E, "DS_WRITE2_B64", VReg_64>;
 
 def DS_READ2_B32 : DS_Load2_Helper <0x00000037, "DS_READ2_B32", VReg_64>;
 def DS_READ2_B64 : DS_Load2_Helper <0x00000075, "DS_READ2_B64", VReg_128>;





More information about the llvm-commits mailing list