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

Side by Side Diff: runtime/vm/disassembler_x64.cc

Issue 11362210: Restrict immediate operands to smi where only smis are supported. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 1 month 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 | « runtime/vm/assembler_x64_test.cc ('k') | runtime/vm/flow_graph_optimizer.cc » ('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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/disassembler.h" 5 #include "vm/disassembler.h"
6 6
7 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32. 7 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32.
8 #if defined(TARGET_ARCH_X64) 8 #if defined(TARGET_ARCH_X64)
9 #include "platform/utils.h" 9 #include "platform/utils.h"
10 #include "vm/allocation.h" 10 #include "vm/allocation.h"
(...skipping 591 matching lines...) Expand 10 before | Expand all | Expand 10 after
602 mnem = "xor"; 602 mnem = "xor";
603 break; 603 break;
604 case 7: 604 case 7:
605 mnem = "cmp"; 605 mnem = "cmp";
606 break; 606 break;
607 default: 607 default:
608 UnimplementedInstruction(); 608 UnimplementedInstruction();
609 } 609 }
610 AppendToBuffer("%s%c ", mnem, operand_size_code()); 610 AppendToBuffer("%s%c ", mnem, operand_size_code());
611 int count = PrintRightOperand(data + 1); 611 int count = PrintRightOperand(data + 1);
612 AppendToBuffer(",0x"); 612 AppendToBuffer(",");
613 OperandSize immediate_size = byte_size_immediate ? BYTE_SIZE : operand_size(); 613 OperandSize immediate_size = byte_size_immediate ? BYTE_SIZE : operand_size();
614 count += PrintImmediate(data + 1 + count, immediate_size); 614 count += PrintImmediate(data + 1 + count, immediate_size);
615 return 1 + count; 615 return 1 + count;
616 } 616 }
617 617
618 618
619 // Returns number of bytes used, including *data. 619 // Returns number of bytes used, including *data.
620 int DisassemblerX64::F6F7Instruction(uint8_t* data) { 620 int DisassemblerX64::F6F7Instruction(uint8_t* data) {
621 ASSERT(*data == 0xF7 || *data == 0xF6); 621 ASSERT(*data == 0xF7 || *data == 0xF6);
622 uint8_t modrm = *(data + 1); 622 uint8_t modrm = *(data + 1);
(...skipping 1241 matching lines...) Expand 10 before | Expand all | Expand 10 after
1864 human_buffer, 1864 human_buffer,
1865 sizeof(human_buffer), 1865 sizeof(human_buffer),
1866 pc); 1866 pc);
1867 pc += instruction_length; 1867 pc += instruction_length;
1868 } 1868 }
1869 } 1869 }
1870 1870
1871 } // namespace dart 1871 } // namespace dart
1872 1872
1873 #endif // defined TARGET_ARCH_X64 1873 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « runtime/vm/assembler_x64_test.cc ('k') | runtime/vm/flow_graph_optimizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698