1 //===- X86InstrInfo.cpp - X86 Instruction Information -----------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file was developed by the LLVM research group and is distributed under
6 // the University of Illinois Open Source License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This file contains the X86 implementation of the TargetInstrInfo class.
12 //===----------------------------------------------------------------------===//
14 #include "X86InstrInfo.h"
16 #include "X86GenInstrInfo.inc"
17 #include "X86InstrBuilder.h"
18 #include "X86Subtarget.h"
19 #include "X86TargetMachine.h"
20 #include "llvm/ADT/STLExtras.h"
21 #include "llvm/CodeGen/MachineInstrBuilder.h"
22 #include "llvm/CodeGen/LiveVariables.h"
23 #include "llvm/CodeGen/SSARegMap.h"
24 #include "llvm/Target/TargetOptions.h"
25 #include "llvm/Support/CommandLine.h"
30 EnableConvert3Addr("enable-x86-conv-3-addr",
31 cl::desc("Enable convertToThreeAddress for X86"));
34 X86InstrInfo::X86InstrInfo(X86TargetMachine &tm)
35 : TargetInstrInfo(X86Insts, array_lengthof(X86Insts)),
36 TM(tm), RI(tm, *this) {
39 bool X86InstrInfo::isMoveInstr(const MachineInstr& MI,
41 unsigned& destReg) const {
42 MachineOpCode oc = MI.getOpcode();
43 if (oc == X86::MOV8rr || oc == X86::MOV16rr ||
44 oc == X86::MOV32rr || oc == X86::MOV64rr ||
45 oc == X86::MOV16to16_ || oc == X86::MOV32to32_ ||
46 oc == X86::MOV_Fp3232 || oc == X86::MOVSSrr || oc == X86::MOVSDrr ||
47 oc == X86::MOV_Fp3264 || oc == X86::MOV_Fp6432 || oc == X86::MOV_Fp6464 ||
48 oc == X86::FsMOVAPSrr || oc == X86::FsMOVAPDrr ||
49 oc == X86::MOVAPSrr || oc == X86::MOVAPDrr ||
50 oc == X86::MOVSS2PSrr || oc == X86::MOVSD2PDrr ||
51 oc == X86::MOVPS2SSrr || oc == X86::MOVPD2SDrr ||
52 oc == X86::MMX_MOVD64rr || oc == X86::MMX_MOVQ64rr) {
53 assert(MI.getNumOperands() >= 2 &&
54 MI.getOperand(0).isRegister() &&
55 MI.getOperand(1).isRegister() &&
56 "invalid register-register move instruction");
57 sourceReg = MI.getOperand(1).getReg();
58 destReg = MI.getOperand(0).getReg();
64 unsigned X86InstrInfo::isLoadFromStackSlot(MachineInstr *MI,
65 int &FrameIndex) const {
66 switch (MI->getOpcode()) {
79 case X86::MMX_MOVD64rm:
80 case X86::MMX_MOVQ64rm:
81 if (MI->getOperand(1).isFrameIndex() && MI->getOperand(2).isImmediate() &&
82 MI->getOperand(3).isRegister() && MI->getOperand(4).isImmediate() &&
83 MI->getOperand(2).getImmedValue() == 1 &&
84 MI->getOperand(3).getReg() == 0 &&
85 MI->getOperand(4).getImmedValue() == 0) {
86 FrameIndex = MI->getOperand(1).getFrameIndex();
87 return MI->getOperand(0).getReg();
94 unsigned X86InstrInfo::isStoreToStackSlot(MachineInstr *MI,
95 int &FrameIndex) const {
96 switch (MI->getOpcode()) {
109 case X86::MMX_MOVD64mr:
110 case X86::MMX_MOVQ64mr:
111 case X86::MMX_MOVNTQmr:
112 if (MI->getOperand(0).isFrameIndex() && MI->getOperand(1).isImmediate() &&
113 MI->getOperand(2).isRegister() && MI->getOperand(3).isImmediate() &&
114 MI->getOperand(1).getImmedValue() == 1 &&
115 MI->getOperand(2).getReg() == 0 &&
116 MI->getOperand(3).getImmedValue() == 0) {
117 FrameIndex = MI->getOperand(0).getFrameIndex();
118 return MI->getOperand(4).getReg();
126 bool X86InstrInfo::isReallyTriviallyReMaterializable(MachineInstr *MI) const {
127 switch (MI->getOpcode()) {
140 case X86::MMX_MOVD64rm:
141 case X86::MMX_MOVQ64rm:
142 // Loads from constant pools are trivially rematerializable.
143 return MI->getOperand(1).isRegister() && MI->getOperand(2).isImmediate() &&
144 MI->getOperand(3).isRegister() && MI->getOperand(4).isConstantPoolIndex() &&
145 MI->getOperand(1).getReg() == 0 &&
146 MI->getOperand(2).getImmedValue() == 1 &&
147 MI->getOperand(3).getReg() == 0;
149 // All other instructions marked M_REMATERIALIZABLE are always trivially
154 /// hasLiveCondCodeDef - True if MI has a condition code def, e.g. EFLAGS, that
155 /// is not marked dead.
156 static bool hasLiveCondCodeDef(MachineInstr *MI) {
157 if (!EnableConvert3Addr)
159 for (unsigned i = 0, e = MI->getNumOperands(); i != e; ++i) {
160 MachineOperand &MO = MI->getOperand(i);
161 if (MO.isRegister() && MO.isDef() &&
162 MO.getReg() == X86::EFLAGS && !MO.isDead()) {
169 /// convertToThreeAddress - This method must be implemented by targets that
170 /// set the M_CONVERTIBLE_TO_3_ADDR flag. When this flag is set, the target
171 /// may be able to convert a two-address instruction into a true
172 /// three-address instruction on demand. This allows the X86 target (for
173 /// example) to convert ADD and SHL instructions into LEA instructions if they
174 /// would require register copies due to two-addressness.
176 /// This method returns a null pointer if the transformation cannot be
177 /// performed, otherwise it returns the new instruction.
180 X86InstrInfo::convertToThreeAddress(MachineFunction::iterator &MFI,
181 MachineBasicBlock::iterator &MBBI,
182 LiveVariables &LV) const {
183 MachineInstr *MI = MBBI;
184 // All instructions input are two-addr instructions. Get the known operands.
185 unsigned Dest = MI->getOperand(0).getReg();
186 unsigned Src = MI->getOperand(1).getReg();
188 MachineInstr *NewMI = NULL;
189 // FIXME: 16-bit LEA's are really slow on Athlons, but not bad on P4's. When
190 // we have better subtarget support, enable the 16-bit LEA generation here.
191 bool DisableLEA16 = true;
193 switch (MI->getOpcode()) {
194 default: break; // All others need to check for live condition code defs.
195 case X86::SHUFPSrri: {
196 assert(MI->getNumOperands() == 4 && "Unknown shufps instruction!");
197 if (!TM.getSubtarget<X86Subtarget>().hasSSE2()) return 0;
199 unsigned A = MI->getOperand(0).getReg();
200 unsigned B = MI->getOperand(1).getReg();
201 unsigned C = MI->getOperand(2).getReg();
202 unsigned M = MI->getOperand(3).getImm();
203 if (B != C) return 0;
204 NewMI = BuildMI(get(X86::PSHUFDri), A).addReg(B).addImm(M);
208 assert(MI->getNumOperands() >= 3 && "Unknown shift instruction!");
209 // NOTE: LEA doesn't produce flags like shift does, but LLVM never uses
210 // the flags produced by a shift yet, so this is safe.
211 unsigned Dest = MI->getOperand(0).getReg();
212 unsigned Src = MI->getOperand(1).getReg();
213 unsigned ShAmt = MI->getOperand(2).getImm();
214 if (ShAmt == 0 || ShAmt >= 4) return 0;
216 NewMI = BuildMI(get(X86::LEA64r), Dest)
217 .addReg(0).addImm(1 << ShAmt).addReg(Src).addImm(0);
221 assert(MI->getNumOperands() >= 3 && "Unknown shift instruction!");
222 // NOTE: LEA doesn't produce flags like shift does, but LLVM never uses
223 // the flags produced by a shift yet, so this is safe.
224 unsigned Dest = MI->getOperand(0).getReg();
225 unsigned Src = MI->getOperand(1).getReg();
226 unsigned ShAmt = MI->getOperand(2).getImm();
227 if (ShAmt == 0 || ShAmt >= 4) return 0;
229 unsigned Opc = TM.getSubtarget<X86Subtarget>().is64Bit() ?
230 X86::LEA64_32r : X86::LEA32r;
231 NewMI = BuildMI(get(Opc), Dest)
232 .addReg(0).addImm(1 << ShAmt).addReg(Src).addImm(0);
236 assert(MI->getNumOperands() >= 3 && "Unknown shift instruction!");
237 // NOTE: LEA doesn't produce flags like shift does, but LLVM never uses
238 // the flags produced by a shift yet, so this is safe.
239 unsigned Dest = MI->getOperand(0).getReg();
240 unsigned Src = MI->getOperand(1).getReg();
241 unsigned ShAmt = MI->getOperand(2).getImm();
242 if (ShAmt == 0 || ShAmt >= 4) return 0;
245 // If 16-bit LEA is disabled, use 32-bit LEA via subregisters.
246 SSARegMap *RegMap = MFI->getParent()->getSSARegMap();
247 unsigned Opc = TM.getSubtarget<X86Subtarget>().is64Bit()
248 ? X86::LEA64_32r : X86::LEA32r;
249 unsigned leaInReg = RegMap->createVirtualRegister(&X86::GR32RegClass);
250 unsigned leaOutReg = RegMap->createVirtualRegister(&X86::GR32RegClass);
253 BuildMI(get(X86::INSERT_SUBREG), leaInReg).addReg(Src).addImm(2);
254 Ins->copyKillDeadInfo(MI);
256 NewMI = BuildMI(get(Opc), leaOutReg)
257 .addReg(0).addImm(1 << ShAmt).addReg(leaInReg).addImm(0);
260 BuildMI(get(X86::EXTRACT_SUBREG), Dest).addReg(leaOutReg).addImm(2);
261 Ext->copyKillDeadInfo(MI);
263 MFI->insert(MBBI, Ins); // Insert the insert_subreg
264 LV.instructionChanged(MI, NewMI); // Update live variables
265 LV.addVirtualRegisterKilled(leaInReg, NewMI);
266 MFI->insert(MBBI, NewMI); // Insert the new inst
267 LV.addVirtualRegisterKilled(leaOutReg, Ext);
268 MFI->insert(MBBI, Ext); // Insert the extract_subreg
271 NewMI = BuildMI(get(X86::LEA16r), Dest)
272 .addReg(0).addImm(1 << ShAmt).addReg(Src).addImm(0);
278 if (!hasLiveCondCodeDef(MI))
279 switch (MI->getOpcode()) {
282 assert(MI->getNumOperands() >= 2 && "Unknown inc instruction!");
283 NewMI = addRegOffset(BuildMI(get(X86::LEA32r), Dest), Src, 1);
287 if (DisableLEA16) return 0;
288 assert(MI->getNumOperands() >= 2 && "Unknown inc instruction!");
289 NewMI = addRegOffset(BuildMI(get(X86::LEA16r), Dest), Src, 1);
293 assert(MI->getNumOperands() >= 2 && "Unknown dec instruction!");
294 NewMI = addRegOffset(BuildMI(get(X86::LEA32r), Dest), Src, -1);
298 if (DisableLEA16) return 0;
299 assert(MI->getNumOperands() >= 2 && "Unknown dec instruction!");
300 NewMI = addRegOffset(BuildMI(get(X86::LEA16r), Dest), Src, -1);
303 assert(MI->getNumOperands() >= 3 && "Unknown add instruction!");
304 NewMI = addRegReg(BuildMI(get(X86::LEA32r), Dest), Src,
305 MI->getOperand(2).getReg());
308 if (DisableLEA16) return 0;
309 assert(MI->getNumOperands() >= 3 && "Unknown add instruction!");
310 NewMI = addRegReg(BuildMI(get(X86::LEA16r), Dest), Src,
311 MI->getOperand(2).getReg());
315 assert(MI->getNumOperands() >= 3 && "Unknown add instruction!");
316 if (MI->getOperand(2).isImmediate())
317 NewMI = addRegOffset(BuildMI(get(X86::LEA32r), Dest), Src,
318 MI->getOperand(2).getImmedValue());
322 if (DisableLEA16) return 0;
323 assert(MI->getNumOperands() >= 3 && "Unknown add instruction!");
324 if (MI->getOperand(2).isImmediate())
325 NewMI = addRegOffset(BuildMI(get(X86::LEA16r), Dest), Src,
326 MI->getOperand(2).getImmedValue());
329 if (DisableLEA16) return 0;
331 assert(MI->getNumOperands() >= 3 && MI->getOperand(2).isImmediate() &&
332 "Unknown shl instruction!");
333 unsigned ShAmt = MI->getOperand(2).getImmedValue();
334 if (ShAmt == 1 || ShAmt == 2 || ShAmt == 3) {
336 AM.Scale = 1 << ShAmt;
338 unsigned Opc = MI->getOpcode() == X86::SHL32ri ? X86::LEA32r :X86::LEA16r;
339 NewMI = addFullAddress(BuildMI(get(Opc), Dest), AM);
345 NewMI->copyKillDeadInfo(MI);
346 LV.instructionChanged(MI, NewMI); // Update live variables
347 MFI->insert(MBBI, NewMI); // Insert the new inst
352 /// commuteInstruction - We have a few instructions that must be hacked on to
355 MachineInstr *X86InstrInfo::commuteInstruction(MachineInstr *MI) const {
356 // FIXME: Can commute cmoves by changing the condition!
357 switch (MI->getOpcode()) {
358 case X86::SHRD16rri8: // A = SHRD16rri8 B, C, I -> A = SHLD16rri8 C, B, (16-I)
359 case X86::SHLD16rri8: // A = SHLD16rri8 B, C, I -> A = SHRD16rri8 C, B, (16-I)
360 case X86::SHRD32rri8: // A = SHRD32rri8 B, C, I -> A = SHLD32rri8 C, B, (32-I)
361 case X86::SHLD32rri8: // A = SHLD32rri8 B, C, I -> A = SHRD32rri8 C, B, (32-I)
362 case X86::SHRD64rri8: // A = SHRD64rri8 B, C, I -> A = SHLD64rri8 C, B, (64-I)
363 case X86::SHLD64rri8:{// A = SHLD64rri8 B, C, I -> A = SHRD64rri8 C, B, (64-I)
366 switch (MI->getOpcode()) {
367 default: assert(0 && "Unreachable!");
368 case X86::SHRD16rri8: Size = 16; Opc = X86::SHLD16rri8; break;
369 case X86::SHLD16rri8: Size = 16; Opc = X86::SHRD16rri8; break;
370 case X86::SHRD32rri8: Size = 32; Opc = X86::SHLD32rri8; break;
371 case X86::SHLD32rri8: Size = 32; Opc = X86::SHRD32rri8; break;
372 case X86::SHRD64rri8: Size = 64; Opc = X86::SHLD64rri8; break;
373 case X86::SHLD64rri8: Size = 64; Opc = X86::SHRD64rri8; break;
375 unsigned Amt = MI->getOperand(3).getImmedValue();
376 unsigned A = MI->getOperand(0).getReg();
377 unsigned B = MI->getOperand(1).getReg();
378 unsigned C = MI->getOperand(2).getReg();
379 bool BisKill = MI->getOperand(1).isKill();
380 bool CisKill = MI->getOperand(2).isKill();
381 return BuildMI(get(Opc), A).addReg(C, false, false, CisKill)
382 .addReg(B, false, false, BisKill).addImm(Size-Amt);
385 return TargetInstrInfo::commuteInstruction(MI);
389 static X86::CondCode GetCondFromBranchOpc(unsigned BrOpc) {
391 default: return X86::COND_INVALID;
392 case X86::JE: return X86::COND_E;
393 case X86::JNE: return X86::COND_NE;
394 case X86::JL: return X86::COND_L;
395 case X86::JLE: return X86::COND_LE;
396 case X86::JG: return X86::COND_G;
397 case X86::JGE: return X86::COND_GE;
398 case X86::JB: return X86::COND_B;
399 case X86::JBE: return X86::COND_BE;
400 case X86::JA: return X86::COND_A;
401 case X86::JAE: return X86::COND_AE;
402 case X86::JS: return X86::COND_S;
403 case X86::JNS: return X86::COND_NS;
404 case X86::JP: return X86::COND_P;
405 case X86::JNP: return X86::COND_NP;
406 case X86::JO: return X86::COND_O;
407 case X86::JNO: return X86::COND_NO;
411 unsigned X86::GetCondBranchFromCond(X86::CondCode CC) {
413 default: assert(0 && "Illegal condition code!");
414 case X86::COND_E: return X86::JE;
415 case X86::COND_NE: return X86::JNE;
416 case X86::COND_L: return X86::JL;
417 case X86::COND_LE: return X86::JLE;
418 case X86::COND_G: return X86::JG;
419 case X86::COND_GE: return X86::JGE;
420 case X86::COND_B: return X86::JB;
421 case X86::COND_BE: return X86::JBE;
422 case X86::COND_A: return X86::JA;
423 case X86::COND_AE: return X86::JAE;
424 case X86::COND_S: return X86::JS;
425 case X86::COND_NS: return X86::JNS;
426 case X86::COND_P: return X86::JP;
427 case X86::COND_NP: return X86::JNP;
428 case X86::COND_O: return X86::JO;
429 case X86::COND_NO: return X86::JNO;
433 /// GetOppositeBranchCondition - Return the inverse of the specified condition,
434 /// e.g. turning COND_E to COND_NE.
435 X86::CondCode X86::GetOppositeBranchCondition(X86::CondCode CC) {
437 default: assert(0 && "Illegal condition code!");
438 case X86::COND_E: return X86::COND_NE;
439 case X86::COND_NE: return X86::COND_E;
440 case X86::COND_L: return X86::COND_GE;
441 case X86::COND_LE: return X86::COND_G;
442 case X86::COND_G: return X86::COND_LE;
443 case X86::COND_GE: return X86::COND_L;
444 case X86::COND_B: return X86::COND_AE;
445 case X86::COND_BE: return X86::COND_A;
446 case X86::COND_A: return X86::COND_BE;
447 case X86::COND_AE: return X86::COND_B;
448 case X86::COND_S: return X86::COND_NS;
449 case X86::COND_NS: return X86::COND_S;
450 case X86::COND_P: return X86::COND_NP;
451 case X86::COND_NP: return X86::COND_P;
452 case X86::COND_O: return X86::COND_NO;
453 case X86::COND_NO: return X86::COND_O;
457 bool X86InstrInfo::isUnpredicatedTerminator(const MachineInstr *MI) const {
458 const TargetInstrDescriptor *TID = MI->getInstrDescriptor();
459 if (TID->Flags & M_TERMINATOR_FLAG) {
460 // Conditional branch is a special case.
461 if ((TID->Flags & M_BRANCH_FLAG) != 0 && (TID->Flags & M_BARRIER_FLAG) == 0)
463 if ((TID->Flags & M_PREDICABLE) == 0)
465 return !isPredicated(MI);
470 // For purposes of branch analysis do not count FP_REG_KILL as a terminator.
471 static bool isBrAnalysisUnpredicatedTerminator(const MachineInstr *MI,
472 const X86InstrInfo &TII) {
473 if (MI->getOpcode() == X86::FP_REG_KILL)
475 return TII.isUnpredicatedTerminator(MI);
478 bool X86InstrInfo::AnalyzeBranch(MachineBasicBlock &MBB,
479 MachineBasicBlock *&TBB,
480 MachineBasicBlock *&FBB,
481 std::vector<MachineOperand> &Cond) const {
482 // If the block has no terminators, it just falls into the block after it.
483 MachineBasicBlock::iterator I = MBB.end();
484 if (I == MBB.begin() || !isBrAnalysisUnpredicatedTerminator(--I, *this))
487 // Get the last instruction in the block.
488 MachineInstr *LastInst = I;
490 // If there is only one terminator instruction, process it.
491 if (I == MBB.begin() || !isBrAnalysisUnpredicatedTerminator(--I, *this)) {
492 if (!isBranch(LastInst->getOpcode()))
495 // If the block ends with a branch there are 3 possibilities:
496 // it's an unconditional, conditional, or indirect branch.
498 if (LastInst->getOpcode() == X86::JMP) {
499 TBB = LastInst->getOperand(0).getMachineBasicBlock();
502 X86::CondCode BranchCode = GetCondFromBranchOpc(LastInst->getOpcode());
503 if (BranchCode == X86::COND_INVALID)
504 return true; // Can't handle indirect branch.
506 // Otherwise, block ends with fall-through condbranch.
507 TBB = LastInst->getOperand(0).getMachineBasicBlock();
508 Cond.push_back(MachineOperand::CreateImm(BranchCode));
512 // Get the instruction before it if it's a terminator.
513 MachineInstr *SecondLastInst = I;
515 // If there are three terminators, we don't know what sort of block this is.
516 if (SecondLastInst && I != MBB.begin() &&
517 isBrAnalysisUnpredicatedTerminator(--I, *this))
520 // If the block ends with X86::JMP and a conditional branch, handle it.
521 X86::CondCode BranchCode = GetCondFromBranchOpc(SecondLastInst->getOpcode());
522 if (BranchCode != X86::COND_INVALID && LastInst->getOpcode() == X86::JMP) {
523 TBB = SecondLastInst->getOperand(0).getMachineBasicBlock();
524 Cond.push_back(MachineOperand::CreateImm(BranchCode));
525 FBB = LastInst->getOperand(0).getMachineBasicBlock();
529 // If the block ends with two X86::JMPs, handle it. The second one is not
530 // executed, so remove it.
531 if (SecondLastInst->getOpcode() == X86::JMP &&
532 LastInst->getOpcode() == X86::JMP) {
533 TBB = SecondLastInst->getOperand(0).getMachineBasicBlock();
535 I->eraseFromParent();
539 // Otherwise, can't handle this.
543 unsigned X86InstrInfo::RemoveBranch(MachineBasicBlock &MBB) const {
544 MachineBasicBlock::iterator I = MBB.end();
545 if (I == MBB.begin()) return 0;
547 if (I->getOpcode() != X86::JMP &&
548 GetCondFromBranchOpc(I->getOpcode()) == X86::COND_INVALID)
551 // Remove the branch.
552 I->eraseFromParent();
556 if (I == MBB.begin()) return 1;
558 if (GetCondFromBranchOpc(I->getOpcode()) == X86::COND_INVALID)
561 // Remove the branch.
562 I->eraseFromParent();
567 X86InstrInfo::InsertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
568 MachineBasicBlock *FBB,
569 const std::vector<MachineOperand> &Cond) const {
570 // Shouldn't be a fall through.
571 assert(TBB && "InsertBranch must not be told to insert a fallthrough");
572 assert((Cond.size() == 1 || Cond.size() == 0) &&
573 "X86 branch conditions have one component!");
575 if (FBB == 0) { // One way branch.
577 // Unconditional branch?
578 BuildMI(&MBB, get(X86::JMP)).addMBB(TBB);
580 // Conditional branch.
581 unsigned Opc = GetCondBranchFromCond((X86::CondCode)Cond[0].getImm());
582 BuildMI(&MBB, get(Opc)).addMBB(TBB);
587 // Two-way Conditional branch.
588 unsigned Opc = GetCondBranchFromCond((X86::CondCode)Cond[0].getImm());
589 BuildMI(&MBB, get(Opc)).addMBB(TBB);
590 BuildMI(&MBB, get(X86::JMP)).addMBB(FBB);
594 bool X86InstrInfo::BlockHasNoFallThrough(MachineBasicBlock &MBB) const {
595 if (MBB.empty()) return false;
597 switch (MBB.back().getOpcode()) {
598 case X86::RET: // Return.
603 case X86::JMP: // Uncond branch.
604 case X86::JMP32r: // Indirect branch.
605 case X86::JMP64r: // Indirect branch (64-bit).
606 case X86::JMP32m: // Indirect branch through mem.
607 case X86::JMP64m: // Indirect branch through mem (64-bit).
609 default: return false;
614 ReverseBranchCondition(std::vector<MachineOperand> &Cond) const {
615 assert(Cond.size() == 1 && "Invalid X86 branch condition!");
616 Cond[0].setImm(GetOppositeBranchCondition((X86::CondCode)Cond[0].getImm()));
620 const TargetRegisterClass *X86InstrInfo::getPointerRegClass() const {
621 const X86Subtarget *Subtarget = &TM.getSubtarget<X86Subtarget>();
622 if (Subtarget->is64Bit())
623 return &X86::GR64RegClass;
625 return &X86::GR32RegClass;