From 65580ea35e1e2d203353539ed6a66cd6ced49fac Mon Sep 17 00:00:00 2001 From: "whesse@chromium.org" Date: Mon, 27 Jul 2009 18:51:46 +0000 Subject: [PATCH] X64: Fix buggy expression in disassembler. Fixes Issue 408: http://code.google.com/p/v8/issues/detail?id=408 Review URL: http://codereview.chromium.org/160174 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2544 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/x64/disasm-x64.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/x64/disasm-x64.cc b/src/x64/disasm-x64.cc index 4e91f31..83e3149 100644 --- a/src/x64/disasm-x64.cc +++ b/src/x64/disasm-x64.cc @@ -1350,7 +1350,7 @@ int DisassemblerX64::InstructionDecode(v8::internal::Vector out_buffer, const char* memory_location = NameOfAddress( reinterpret_cast( *reinterpret_cast(data + 1))); - if (*data & 0x2 == 0x2) { // Opcode 0xA3 + if (*data == 0xA3) { // Opcode 0xA3 AppendToBuffer("movzxlq rax,(%s)", memory_location); } else { // Opcode 0xA1 AppendToBuffer("movzxlq (%s),rax", memory_location); @@ -1362,7 +1362,7 @@ int DisassemblerX64::InstructionDecode(v8::internal::Vector out_buffer, // New x64 instruction mov rax,(imm_64). const char* memory_location = NameOfAddress( *reinterpret_cast(data + 1)); - if (*data & 0x2 == 0x2) { // Opcode 0xA3 + if (*data == 0xA3) { // Opcode 0xA3 AppendToBuffer("movq rax,(%s)", memory_location); } else { // Opcode 0xA1 AppendToBuffer("movq (%s),rax", memory_location); -- 2.7.4