diff options
author | Evan Cheng <evan.cheng@apple.com> | 2006-02-14 21:52:51 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2006-02-14 21:52:51 +0000 |
commit | ee50a1ae27a9d50dc292ef7ae9a902a9bdd1a1b4 (patch) | |
tree | 473df8cf0d3dd78cda78b94f2cb6a14399f49a36 /lib/Target/X86/X86CodeEmitter.cpp | |
parent | 576c1419215b9f3b421ab74ff97acb3f2503c904 (diff) | |
download | external_llvm-ee50a1ae27a9d50dc292ef7ae9a902a9bdd1a1b4.zip external_llvm-ee50a1ae27a9d50dc292ef7ae9a902a9bdd1a1b4.tar.gz external_llvm-ee50a1ae27a9d50dc292ef7ae9a902a9bdd1a1b4.tar.bz2 |
Don't special case XS, XD prefixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26183 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86/X86CodeEmitter.cpp')
-rw-r--r-- | lib/Target/X86/X86CodeEmitter.cpp | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/lib/Target/X86/X86CodeEmitter.cpp b/lib/Target/X86/X86CodeEmitter.cpp index 5ef53d3..5208f52 100644 --- a/lib/Target/X86/X86CodeEmitter.cpp +++ b/lib/Target/X86/X86CodeEmitter.cpp @@ -362,30 +362,25 @@ void Emitter::emitInstruction(const MachineInstr &MI) { // Emit the operand size opcode prefix as needed. if (Desc.TSFlags & X86II::OpSize) MCE.emitByte(0x66); - // Emit the double precision sse fp opcode prefix as needed. - if ((Desc.TSFlags & X86II::Op0Mask) == X86II::XD) { - MCE.emitByte(0xF2); MCE.emitByte(0x0F); - } - - // Emit the double precision sse fp opcode prefix as needed. - if ((Desc.TSFlags & X86II::Op0Mask) == X86II::XS) { - MCE.emitByte(0xF3); MCE.emitByte(0x0F); - } - switch (Desc.TSFlags & X86II::Op0Mask) { case X86II::TB: MCE.emitByte(0x0F); // Two-byte opcode prefix break; + case X86II::REP: break; // already handled. + case X86II::XS: // F3 0F + MCE.emitByte(0xF3); + MCE.emitByte(0x0F); + break; + case X86II::XD: // F2 0F + MCE.emitByte(0xF2); + MCE.emitByte(0x0F); + break; case X86II::D8: case X86II::D9: case X86II::DA: case X86II::DB: case X86II::DC: case X86II::DD: case X86II::DE: case X86II::DF: MCE.emitByte(0xD8+ (((Desc.TSFlags & X86II::Op0Mask)-X86II::D8) >> X86II::Op0Shift)); break; // Two-byte opcode prefix - case X86II::REP: - case X86II::XS: - case X86II::XD: - break; // already handled. default: assert(0 && "Invalid prefix!"); case 0: break; // No prefix! } |