OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1014 int mod, regop, rm; | 1014 int mod, regop, rm; |
1015 if (opcode == 0x3A) { | 1015 if (opcode == 0x3A) { |
1016 byte third_byte = *current; | 1016 byte third_byte = *current; |
1017 current = data + 3; | 1017 current = data + 3; |
1018 if (third_byte == 0x17) { | 1018 if (third_byte == 0x17) { |
1019 get_modrm(*current, &mod, ®op, &rm); | 1019 get_modrm(*current, &mod, ®op, &rm); |
1020 AppendToBuffer("extractps "); // reg/m32, xmm, imm8 | 1020 AppendToBuffer("extractps "); // reg/m32, xmm, imm8 |
1021 current += PrintRightOperand(current); | 1021 current += PrintRightOperand(current); |
1022 AppendToBuffer(", %s, %d", NameOfCPURegister(regop), (*current) & 3); | 1022 AppendToBuffer(", %s, %d", NameOfCPURegister(regop), (*current) & 3); |
1023 current += 1; | 1023 current += 1; |
| 1024 } else if (third_byte == 0x0b) { |
| 1025 get_modrm(*current, &mod, ®op, &rm); |
| 1026 // roundsd xmm, xmm/m64, imm8 |
| 1027 AppendToBuffer("roundsd %s, ", NameOfCPURegister(regop)); |
| 1028 current += PrintRightOperand(current); |
| 1029 AppendToBuffer(", %d", (*current) & 3); |
| 1030 current += 1; |
1024 } else { | 1031 } else { |
1025 UnimplementedInstruction(); | 1032 UnimplementedInstruction(); |
1026 } | 1033 } |
1027 } else { | 1034 } else { |
1028 get_modrm(*current, &mod, ®op, &rm); | 1035 get_modrm(*current, &mod, ®op, &rm); |
1029 if (opcode == 0x6E) { | 1036 if (opcode == 0x6E) { |
1030 AppendToBuffer("mov%c %s,", | 1037 AppendToBuffer("mov%c %s,", |
1031 rex_w() ? 'q' : 'd', | 1038 rex_w() ? 'q' : 'd', |
1032 NameOfXMMRegister(regop)); | 1039 NameOfXMMRegister(regop)); |
1033 current += PrintRightOperand(current); | 1040 current += PrintRightOperand(current); |
(...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1777 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { | 1784 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { |
1778 fprintf(f, " "); | 1785 fprintf(f, " "); |
1779 } | 1786 } |
1780 fprintf(f, " %s\n", buffer.start()); | 1787 fprintf(f, " %s\n", buffer.start()); |
1781 } | 1788 } |
1782 } | 1789 } |
1783 | 1790 |
1784 } // namespace disasm | 1791 } // namespace disasm |
1785 | 1792 |
1786 #endif // V8_TARGET_ARCH_X64 | 1793 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |