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

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

Issue 1192103004: VM: New calling convention for generated code. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: fixed comments Created 5 years, 3 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
« no previous file with comments | « runtime/vm/deopt_instructions.cc ('k') | runtime/vm/disassembler_ia32.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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_ARM. 7 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM.
8 #if defined(TARGET_ARCH_ARM) 8 #if defined(TARGET_ARCH_ARM)
9 9
10 #include "platform/assert.h" 10 #include "platform/assert.h"
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 }; 102 };
103 103
104 104
105 // Print the condition guarding the instruction. 105 // Print the condition guarding the instruction.
106 void ARMDecoder::PrintCondition(Instr* instr) { 106 void ARMDecoder::PrintCondition(Instr* instr) {
107 Print(cond_names[instr->ConditionField()]); 107 Print(cond_names[instr->ConditionField()]);
108 } 108 }
109 109
110 110
111 // These register names are defined in a way to match the native disassembler 111 // These register names are defined in a way to match the native disassembler
112 // formatting, except for register aliases ctx (r9) and pp (r10). 112 // formatting, except for register alias pp (r9).
113 // See for example the command "objdump -d <binary file>". 113 // See for example the command "objdump -d <binary file>".
114 static const char* reg_names[kNumberOfCpuRegisters] = { 114 static const char* reg_names[kNumberOfCpuRegisters] = {
115 "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", 115 "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7",
116 "r8", "ctx", "pp", "fp", "ip", "sp", "lr", "pc", 116 "r8", "pp", "r10", "fp", "ip", "sp", "lr", "pc",
117 }; 117 };
118 118
119 119
120 // Print the register name according to the active name converter. 120 // Print the register name according to the active name converter.
121 void ARMDecoder::PrintRegister(int reg) { 121 void ARMDecoder::PrintRegister(int reg) {
122 ASSERT(0 <= reg); 122 ASSERT(0 <= reg);
123 ASSERT(reg < kNumberOfCpuRegisters); 123 ASSERT(reg < kNumberOfCpuRegisters);
124 Print(reg_names[reg]); 124 Print(reg_names[reg]);
125 } 125 }
126 126
(...skipping 1404 matching lines...) Expand 10 before | Expand all | Expand 10 after
1531 int32_t instruction_bits = Instr::At(pc)->InstructionBits(); 1531 int32_t instruction_bits = Instr::At(pc)->InstructionBits();
1532 OS::SNPrint(hex_buffer, hex_size, "%08x", instruction_bits); 1532 OS::SNPrint(hex_buffer, hex_size, "%08x", instruction_bits);
1533 if (out_instr_size) { 1533 if (out_instr_size) {
1534 *out_instr_size = Instr::kInstrSize; 1534 *out_instr_size = Instr::kInstrSize;
1535 } 1535 }
1536 } 1536 }
1537 1537
1538 } // namespace dart 1538 } // namespace dart
1539 1539
1540 #endif // defined TARGET_ARCH_ARM 1540 #endif // defined TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « runtime/vm/deopt_instructions.cc ('k') | runtime/vm/disassembler_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698