DForm_1, particularly used by store instructions, needs the immediate operand to
authorMisha Brukman <brukman+llvm@gmail.com>
Sat, 23 Oct 2004 06:08:38 +0000 (06:08 +0000)
committerMisha Brukman <brukman+llvm@gmail.com>
Sat, 23 Oct 2004 06:08:38 +0000 (06:08 +0000)
be listed second as that is how the instructions are usually created (and is the
correct asm syntax) so that it's assembled correctly from its constituents

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17183 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/PowerPC/PPCInstrFormats.td

index b4f868fb39eb190242ae27481d201c6f018e488a..880bcce95b9a45384ff8a0e8b27af6b0396156fc 100644 (file)
@@ -131,9 +131,21 @@ class DForm_base<bits<6> opcode, bit ppc64, bit vmx, dag OL, string asmstr>
 }
 
 class DForm_1<bits<6> opcode, bit ppc64, bit vmx, dag OL, string asmstr>
-  : DForm_base<opcode, ppc64, vmx, OL, asmstr> {
+  : I<opcode, ppc64, vmx, OL, asmstr> {
+  bits<5>  A;
+  bits<16> C;
+  bits<5>  B;
+  
+  let ArgCount = 3;
+  let Arg0Type = Gpr.Value;
   let Arg1Type = Disimm16.Value;
   let Arg2Type = Gpr.Value;
+  let Arg3Type = 0;
+  let Arg4Type = 0;
+  let Inst{6-10}  = A;
+  let Inst{11-15} = B;
+  let Inst{16-31} = C;
 }
 
 class DForm_2<bits<6> opcode, bit ppc64, bit vmx, dag OL, string asmstr>