Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(114)

Side by Side Diff: src/x64/disasm-x64.cc

Issue 6529032: Merge 6168:6800 from bleeding_edge to experimental/gc branch. (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/gc/
Patch Set: Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/x64/deoptimizer-x64.cc ('k') | src/x64/frames-x64.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 1007 matching lines...) Expand 10 before | Expand all | Expand 10 after
1018 } else { 1018 } else {
1019 UnimplementedInstruction(); 1019 UnimplementedInstruction();
1020 } 1020 }
1021 } else { 1021 } else {
1022 get_modrm(*current, &mod, &regop, &rm); 1022 get_modrm(*current, &mod, &regop, &rm);
1023 if (opcode == 0x6E) { 1023 if (opcode == 0x6E) {
1024 AppendToBuffer("mov%c %s,", 1024 AppendToBuffer("mov%c %s,",
1025 rex_w() ? 'q' : 'd', 1025 rex_w() ? 'q' : 'd',
1026 NameOfXMMRegister(regop)); 1026 NameOfXMMRegister(regop));
1027 current += PrintRightOperand(current); 1027 current += PrintRightOperand(current);
1028 } else if (opcode == 0x6F) {
1029 AppendToBuffer("movdqa %s,",
1030 NameOfXMMRegister(regop));
1031 current += PrintRightOperand(current);
1028 } else if (opcode == 0x7E) { 1032 } else if (opcode == 0x7E) {
1029 AppendToBuffer("mov%c ", 1033 AppendToBuffer("mov%c ",
1030 rex_w() ? 'q' : 'd'); 1034 rex_w() ? 'q' : 'd');
1031 current += PrintRightOperand(current); 1035 current += PrintRightOperand(current);
1032 AppendToBuffer(", %s", NameOfXMMRegister(regop)); 1036 AppendToBuffer(", %s", NameOfXMMRegister(regop));
1037 } else if (opcode == 0x7F) {
1038 AppendToBuffer("movdqa ");
1039 current += PrintRightOperand(current);
1040 AppendToBuffer(", %s", NameOfXMMRegister(regop));
1033 } else { 1041 } else {
1034 const char* mnemonic = "?"; 1042 const char* mnemonic = "?";
1035 if (opcode == 0x57) { 1043 if (opcode == 0x57) {
1036 mnemonic = "xorpd"; 1044 mnemonic = "xorpd";
1037 } else if (opcode == 0x2E) { 1045 } else if (opcode == 0x2E) {
1038 mnemonic = "ucomisd"; 1046 mnemonic = "ucomisd";
1039 } else if (opcode == 0x2F) { 1047 } else if (opcode == 0x2F) {
1040 mnemonic = "comisd"; 1048 mnemonic = "comisd";
1049 } else if (opcode == 0x50) {
1050 mnemonic = "movmskpd";
1041 } else { 1051 } else {
1042 UnimplementedInstruction(); 1052 UnimplementedInstruction();
1043 } 1053 }
1044 AppendToBuffer("%s %s,", mnemonic, NameOfXMMRegister(regop)); 1054 AppendToBuffer("%s %s,", mnemonic, NameOfXMMRegister(regop));
1045 current += PrintRightXMMOperand(current); 1055 current += PrintRightXMMOperand(current);
1046 } 1056 }
1047 } 1057 }
1048 } else if (group_1_prefix_ == 0xF2) { 1058 } else if (group_1_prefix_ == 0xF2) {
1049 // Beginning of instructions with prefix 0xF2. 1059 // Beginning of instructions with prefix 0xF2.
1050 1060
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
1106 } 1116 }
1107 } else if (opcode == 0x2A) { 1117 } else if (opcode == 0x2A) {
1108 // CVTSI2SS: integer to XMM single conversion. 1118 // CVTSI2SS: integer to XMM single conversion.
1109 int mod, regop, rm; 1119 int mod, regop, rm;
1110 get_modrm(*current, &mod, &regop, &rm); 1120 get_modrm(*current, &mod, &regop, &rm);
1111 AppendToBuffer("%ss %s,", mnemonic, NameOfXMMRegister(regop)); 1121 AppendToBuffer("%ss %s,", mnemonic, NameOfXMMRegister(regop));
1112 current += PrintRightOperand(current); 1122 current += PrintRightOperand(current);
1113 } else if (opcode == 0x2C) { 1123 } else if (opcode == 0x2C) {
1114 // CVTTSS2SI: 1124 // CVTTSS2SI:
1115 // Convert with truncation scalar single-precision FP to dword integer. 1125 // Convert with truncation scalar single-precision FP to dword integer.
1116 // Assert that mod is not 3, so source is memory, not an XMM register. 1126 int mod, regop, rm;
1117 ASSERT_NE(0xC0, *current & 0xC0); 1127 get_modrm(*current, &mod, &regop, &rm);
1118 current += PrintOperands("cvttss2si", REG_OPER_OP_ORDER, current); 1128 AppendToBuffer("cvttss2si%c %s,",
1129 operand_size_code(), NameOfCPURegister(regop));
1130 current += PrintRightXMMOperand(current);
1119 } else if (opcode == 0x5A) { 1131 } else if (opcode == 0x5A) {
1120 // CVTSS2SD: 1132 // CVTSS2SD:
1121 // Convert scalar single-precision FP to scalar double-precision FP. 1133 // Convert scalar single-precision FP to scalar double-precision FP.
1122 int mod, regop, rm; 1134 int mod, regop, rm;
1123 get_modrm(*current, &mod, &regop, &rm); 1135 get_modrm(*current, &mod, &regop, &rm);
1124 AppendToBuffer("cvtss2sd %s,", NameOfXMMRegister(regop)); 1136 AppendToBuffer("cvtss2sd %s,", NameOfXMMRegister(regop));
1125 current += PrintRightXMMOperand(current); 1137 current += PrintRightXMMOperand(current);
1126 } else { 1138 } else {
1127 UnimplementedInstruction(); 1139 UnimplementedInstruction();
1128 } 1140 }
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after
1712 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { 1724 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) {
1713 fprintf(f, " "); 1725 fprintf(f, " ");
1714 } 1726 }
1715 fprintf(f, " %s\n", buffer.start()); 1727 fprintf(f, " %s\n", buffer.start());
1716 } 1728 }
1717 } 1729 }
1718 1730
1719 } // namespace disasm 1731 } // namespace disasm
1720 1732
1721 #endif // V8_TARGET_ARCH_X64 1733 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/deoptimizer-x64.cc ('k') | src/x64/frames-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698