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

Side by Side Diff: src/frames.cc

Issue 335027: Reverted 3130-3131 since they don't work on mac. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 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 | « src/frames.h ('k') | src/handles.h » ('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 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 376 matching lines...) Expand 10 before | Expand all | Expand 10 after
387 return ExitFrame::GetStateForFramePointer(fp, state); 387 return ExitFrame::GetStateForFramePointer(fp, state);
388 } 388 }
389 389
390 390
391 Code* EntryConstructFrame::code() const { 391 Code* EntryConstructFrame::code() const {
392 return Heap::js_construct_entry_code(); 392 return Heap::js_construct_entry_code();
393 } 393 }
394 394
395 395
396 Code* ExitFrame::code() const { 396 Code* ExitFrame::code() const {
397 const int offset = ExitFrameConstants::kCodeOffset; 397 return Heap::c_entry_code();
398 Object* code = Memory::Object_at(fp() + offset);
399 if (code->IsSmi()) {
400 return Heap::c_entry_debug_break_code();
401 } else {
402 return Code::cast(code);
403 }
404 } 398 }
405 399
406 400
407 void ExitFrame::ComputeCallerState(State* state) const { 401 void ExitFrame::ComputeCallerState(State* state) const {
408 // Setup the caller state. 402 // Setup the caller state.
409 state->sp = caller_sp(); 403 state->sp = caller_sp();
410 state->fp = Memory::Address_at(fp() + ExitFrameConstants::kCallerFPOffset); 404 state->fp = Memory::Address_at(fp() + ExitFrameConstants::kCallerFPOffset);
411 state->pc_address 405 state->pc_address
412 = reinterpret_cast<Address*>(fp() + ExitFrameConstants::kCallerPCOffset); 406 = reinterpret_cast<Address*>(fp() + ExitFrameConstants::kCallerPCOffset);
413 } 407 }
414 408
415 409
416 Address ExitFrame::GetCallerStackPointer() const { 410 Address ExitFrame::GetCallerStackPointer() const {
417 return fp() + ExitFrameConstants::kCallerSPDisplacement; 411 return fp() + ExitFrameConstants::kCallerSPDisplacement;
418 } 412 }
419 413
420 414
415 Code* ExitDebugFrame::code() const {
416 return Heap::c_entry_debug_break_code();
417 }
418
419
421 Address StandardFrame::GetExpressionAddress(int n) const { 420 Address StandardFrame::GetExpressionAddress(int n) const {
422 const int offset = StandardFrameConstants::kExpressionsOffset; 421 const int offset = StandardFrameConstants::kExpressionsOffset;
423 return fp() + offset - n * kPointerSize; 422 return fp() + offset - n * kPointerSize;
424 } 423 }
425 424
426 425
427 int StandardFrame::ComputeExpressionsCount() const { 426 int StandardFrame::ComputeExpressionsCount() const {
428 const int offset = 427 const int offset =
429 StandardFrameConstants::kExpressionsOffset + kPointerSize; 428 StandardFrameConstants::kExpressionsOffset + kPointerSize;
430 Address base = fp() + offset; 429 Address base = fp() + offset;
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
735 reg_code[i++] = r; 734 reg_code[i++] = r;
736 735
737 ASSERT(i == kNumJSCallerSaved); 736 ASSERT(i == kNumJSCallerSaved);
738 } 737 }
739 ASSERT(0 <= n && n < kNumJSCallerSaved); 738 ASSERT(0 <= n && n < kNumJSCallerSaved);
740 return reg_code[n]; 739 return reg_code[n];
741 } 740 }
742 741
743 742
744 } } // namespace v8::internal 743 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/frames.h ('k') | src/handles.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698