forked from OSchip/llvm-project
Attempt to handle MRMInitReg in emitVEXOpcodePrefix. Hopefully fixes PR12711.
llvm-svn: 155896
This commit is contained in:
parent
48221c5c54
commit
d32ebcc36b
|
@ -939,7 +939,18 @@ void Emitter<CodeEmitter>::emitVEXOpcodePrefix(uint64_t TSFlags,
|
||||||
// Classify VEX_B, VEX_4V, VEX_R, VEX_X
|
// Classify VEX_B, VEX_4V, VEX_R, VEX_X
|
||||||
unsigned CurOp = 0;
|
unsigned CurOp = 0;
|
||||||
switch (TSFlags & X86II::FormMask) {
|
switch (TSFlags & X86II::FormMask) {
|
||||||
case X86II::MRMInitReg: llvm_unreachable("FIXME: Remove this!");
|
case X86II::MRMInitReg:
|
||||||
|
// Duplicate register.
|
||||||
|
if (X86II::isX86_64ExtendedReg(MI.getOperand(CurOp).getReg()))
|
||||||
|
VEX_R = 0x0;
|
||||||
|
|
||||||
|
if (HasVEX_4V)
|
||||||
|
VEX_4V = getVEXRegisterEncoding(MI, CurOp);
|
||||||
|
if (X86II::isX86_64ExtendedReg(MI.getOperand(CurOp).getReg()))
|
||||||
|
VEX_B = 0x0;
|
||||||
|
if (HasVEX_4VOp3)
|
||||||
|
VEX_4V = getVEXRegisterEncoding(MI, CurOp);
|
||||||
|
break;
|
||||||
case X86II::MRMDestMem: {
|
case X86II::MRMDestMem: {
|
||||||
// MRMDestMem instructions forms:
|
// MRMDestMem instructions forms:
|
||||||
// MemAddr, src1(ModR/M)
|
// MemAddr, src1(ModR/M)
|
||||||
|
|
Loading…
Reference in New Issue