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

Side by Side Diff: src/arm/simulator-arm.cc

Issue 1287383003: Re-reland: Remove register index/code indirection (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Updated to ToT 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stdarg.h> 5 #include <stdarg.h>
6 #include <stdlib.h> 6 #include <stdlib.h>
7 #include <cmath> 7 #include <cmath>
8 8
9 #if V8_TARGET_ARCH_ARM 9 #if V8_TARGET_ARCH_ARM
10 10
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
291 // Leave the debugger shell. 291 // Leave the debugger shell.
292 done = true; 292 done = true;
293 } else if ((strcmp(cmd, "p") == 0) || (strcmp(cmd, "print") == 0)) { 293 } else if ((strcmp(cmd, "p") == 0) || (strcmp(cmd, "print") == 0)) {
294 if (argc == 2 || (argc == 3 && strcmp(arg2, "fp") == 0)) { 294 if (argc == 2 || (argc == 3 && strcmp(arg2, "fp") == 0)) {
295 int32_t value; 295 int32_t value;
296 float svalue; 296 float svalue;
297 double dvalue; 297 double dvalue;
298 if (strcmp(arg1, "all") == 0) { 298 if (strcmp(arg1, "all") == 0) {
299 for (int i = 0; i < kNumRegisters; i++) { 299 for (int i = 0; i < kNumRegisters; i++) {
300 value = GetRegisterValue(i); 300 value = GetRegisterValue(i);
301 PrintF("%3s: 0x%08x %10d", Registers::Name(i), value, value); 301 PrintF("%3s: 0x%08x %10d", Register::from_code(i).ToString(),
302 value, value);
302 if ((argc == 3 && strcmp(arg2, "fp") == 0) && 303 if ((argc == 3 && strcmp(arg2, "fp") == 0) &&
303 i < 8 && 304 i < 8 &&
304 (i % 2) == 0) { 305 (i % 2) == 0) {
305 dvalue = GetRegisterPairDoubleValue(i); 306 dvalue = GetRegisterPairDoubleValue(i);
306 PrintF(" (%f)\n", dvalue); 307 PrintF(" (%f)\n", dvalue);
307 } else { 308 } else {
308 PrintF("\n"); 309 PrintF("\n");
309 } 310 }
310 } 311 }
311 for (int i = 0; i < DwVfpRegister::NumRegisters(); i++) { 312 for (int i = 0; i < DwVfpRegister::NumRegisters(); i++) {
(...skipping 3845 matching lines...) Expand 10 before | Expand all | Expand 10 after
4157 set_register(sp, current_sp + sizeof(uintptr_t)); 4158 set_register(sp, current_sp + sizeof(uintptr_t));
4158 return address; 4159 return address;
4159 } 4160 }
4160 4161
4161 } // namespace internal 4162 } // namespace internal
4162 } // namespace v8 4163 } // namespace v8
4163 4164
4164 #endif // USE_SIMULATOR 4165 #endif // USE_SIMULATOR
4165 4166
4166 #endif // V8_TARGET_ARCH_ARM 4167 #endif // V8_TARGET_ARCH_ARM
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698