More AVX: {ADD,SUB,MUL,DIV}{PD,PS}rr
[oota-llvm.git] / lib / Target / X86 / X86MCCodeEmitter.cpp
index adf4999ae5a78eab3efa2d7ab1a68ff6b58cf913..d553b74a6bc8497b8979c9c524a0abca57654139 100644 (file)
@@ -392,12 +392,16 @@ void X86MCCodeEmitter::EmitVEXOpcodePrefix(uint64_t TSFlags, unsigned &CurByte,
   // functionality of a SIMD prefix
   //
   //  0b00: None
-  //  0b01: 66 (not handled yet)
+  //  0b01: 66
   //  0b10: F3
   //  0b11: F2
   //
   unsigned char VEX_PP = 0;
 
+  // Encode the operand size opcode prefix as needed.
+  if (TSFlags & X86II::OpSize)
+    VEX_PP = 0x01;
+
   switch (TSFlags & X86II::Op0Mask) {
   default: assert(0 && "Invalid prefix!");
   case 0: break;  // No prefix!