| 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 1255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1266 AppendToBuffer("ret 0x%x", *reinterpret_cast<uint16_t*>(data + 1)); | 1266 AppendToBuffer("ret 0x%x", *reinterpret_cast<uint16_t*>(data + 1)); |
| 1267 data += 3; | 1267 data += 3; |
| 1268 break; | 1268 break; |
| 1269 | 1269 |
| 1270 case 0x69: // fall through | 1270 case 0x69: // fall through |
| 1271 case 0x6B: { | 1271 case 0x6B: { |
| 1272 int mod, regop, rm; | 1272 int mod, regop, rm; |
| 1273 get_modrm(*(data + 1), &mod, ®op, &rm); | 1273 get_modrm(*(data + 1), &mod, ®op, &rm); |
| 1274 int32_t imm = *data == 0x6B ? *(data + 2) | 1274 int32_t imm = *data == 0x6B ? *(data + 2) |
| 1275 : *reinterpret_cast<int32_t*>(data + 2); | 1275 : *reinterpret_cast<int32_t*>(data + 2); |
| 1276 AppendToBuffer("imul %s,%s,0x%x", NameOfCPURegister(regop), | 1276 AppendToBuffer("imul%c %s,%s,0x%x", |
| 1277 operand_size_code(), |
| 1278 NameOfCPURegister(regop), |
| 1277 NameOfCPURegister(rm), imm); | 1279 NameOfCPURegister(rm), imm); |
| 1278 data += 2 + (*data == 0x6B ? 1 : 4); | 1280 data += 2 + (*data == 0x6B ? 1 : 4); |
| 1279 break; | 1281 break; |
| 1280 } | 1282 } |
| 1281 | 1283 |
| 1282 case 0x81: // fall through | 1284 case 0x81: // fall through |
| 1283 case 0x83: // 0x81 with sign extension bit set | 1285 case 0x83: // 0x81 with sign extension bit set |
| 1284 data += PrintImmediateOp(data); | 1286 data += PrintImmediateOp(data); |
| 1285 break; | 1287 break; |
| 1286 | 1288 |
| (...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1626 fprintf(f, "%02x", *bp); | 1628 fprintf(f, "%02x", *bp); |
| 1627 } | 1629 } |
| 1628 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { | 1630 for (int i = 6 - static_cast<int>(pc - prev_pc); i >= 0; i--) { |
| 1629 fprintf(f, " "); | 1631 fprintf(f, " "); |
| 1630 } | 1632 } |
| 1631 fprintf(f, " %s\n", buffer.start()); | 1633 fprintf(f, " %s\n", buffer.start()); |
| 1632 } | 1634 } |
| 1633 } | 1635 } |
| 1634 | 1636 |
| 1635 } // namespace disasm | 1637 } // namespace disasm |
| OLD | NEW |