OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1095 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1106 } | 1106 } |
1107 } else if (opcode == 0x2A) { | 1107 } else if (opcode == 0x2A) { |
1108 // CVTSI2SS: integer to XMM single conversion. | 1108 // CVTSI2SS: integer to XMM single conversion. |
1109 int mod, regop, rm; | 1109 int mod, regop, rm; |
1110 get_modrm(*current, &mod, ®op, &rm); | 1110 get_modrm(*current, &mod, ®op, &rm); |
1111 AppendToBuffer("%ss %s,", mnemonic, NameOfXMMRegister(regop)); | 1111 AppendToBuffer("%ss %s,", mnemonic, NameOfXMMRegister(regop)); |
1112 current += PrintRightOperand(current); | 1112 current += PrintRightOperand(current); |
1113 } else if (opcode == 0x2C) { | 1113 } else if (opcode == 0x2C) { |
1114 // CVTTSS2SI: | 1114 // CVTTSS2SI: |
1115 // Convert with truncation scalar single-precision FP to dword integer. | 1115 // Convert with truncation scalar single-precision FP to dword integer. |
1116 int mod, regop, rm; | 1116 // Assert that mod is not 3, so source is memory, not an XMM register. |
1117 get_modrm(*current, &mod, ®op, &rm); | 1117 ASSERT_NE(0xC0, *current & 0xC0); |
1118 AppendToBuffer("cvttss2si%c %s,", | 1118 current += PrintOperands("cvttss2si", REG_OPER_OP_ORDER, current); |
1119 operand_size_code(), NameOfCPURegister(regop)); | |
1120 current += PrintRightXMMOperand(current); | |
1121 } else if (opcode == 0x5A) { | 1119 } else if (opcode == 0x5A) { |
1122 // CVTSS2SD: | 1120 // CVTSS2SD: |
1123 // Convert scalar single-precision FP to scalar double-precision FP. | 1121 // Convert scalar single-precision FP to scalar double-precision FP. |
1124 int mod, regop, rm; | 1122 int mod, regop, rm; |
1125 get_modrm(*current, &mod, ®op, &rm); | 1123 get_modrm(*current, &mod, ®op, &rm); |
1126 AppendToBuffer("cvtss2sd %s,", NameOfXMMRegister(regop)); | 1124 AppendToBuffer("cvtss2sd %s,", NameOfXMMRegister(regop)); |
1127 current += PrintRightXMMOperand(current); | 1125 current += PrintRightXMMOperand(current); |
1128 } else { | 1126 } else { |
1129 UnimplementedInstruction(); | 1127 UnimplementedInstruction(); |
1130 } | 1128 } |
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1714 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { | 1712 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { |
1715 fprintf(f, " "); | 1713 fprintf(f, " "); |
1716 } | 1714 } |
1717 fprintf(f, " %s\n", buffer.start()); | 1715 fprintf(f, " %s\n", buffer.start()); |
1718 } | 1716 } |
1719 } | 1717 } |
1720 | 1718 |
1721 } // namespace disasm | 1719 } // namespace disasm |
1722 | 1720 |
1723 #endif // V8_TARGET_ARCH_X64 | 1721 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |