diff options
author | Chris Lattner <sabre@nondot.org> | 2007-02-25 05:07:49 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-02-25 05:07:49 +0000 |
commit | eb95d41cd364f3526d1c39455a0131185495c51a (patch) | |
tree | 3950d4d2a67eb54a8e1ba1781b99d60ed26a41f0 | |
parent | 456bc87e78af18331b9579069a059c723da517d9 (diff) |
Add XLForm_1_ext template, patch by Nicolas Geoffray.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34573 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/PowerPC/PPCInstrFormats.td | 38 |
1 files changed, 24 insertions, 14 deletions
diff --git a/lib/Target/PowerPC/PPCInstrFormats.td b/lib/Target/PowerPC/PPCInstrFormats.td index fc03653c24..6a4a59b593 100644 --- a/lib/Target/PowerPC/PPCInstrFormats.td +++ b/lib/Target/PowerPC/PPCInstrFormats.td @@ -349,21 +349,31 @@ class DSS_Form<bits<10> xo, dag OL, string asmstr, // 1.7.7 XL-Form class XLForm_1<bits<6> opcode, bits<10> xo, dag OL, string asmstr, - InstrItinClass itin> + InstrItinClass itin, list<dag> pattern> + : I<opcode, OL, asmstr, itin> { + bits<5> CRD; + bits<5> CRA; + bits<5> CRB; + + let Pattern = pattern; + + let Inst{6-10} = CRD; + let Inst{11-15} = CRA; + let Inst{16-20} = CRB; + let Inst{21-30} = xo; + let Inst{31} = 0; +} + +class XLForm_1_ext<bits<6> opcode, bits<10> xo, dag OL, string asmstr, + InstrItinClass itin, list<dag> pattern> : I<opcode, OL, asmstr, itin> { - bits<3> CRD; - bits<2> CRDb; - bits<3> CRA; - bits<2> CRAb; - bits<3> CRB; - bits<2> CRBb; - - let Inst{6-8} = CRD; - let Inst{9-10} = CRDb; - let Inst{11-13} = CRA; - let Inst{14-15} = CRAb; - let Inst{16-18} = CRB; - let Inst{19-20} = CRBb; + bits<5> CRD; + + let Pattern = pattern; + + let Inst{6-10} = CRD; + let Inst{11-15} = CRD; + let Inst{16-20} = CRD; let Inst{21-30} = xo; let Inst{31} = 0; } |