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

Side by Side Diff: src/frames.cc

Issue 565047: * Add the partial context snapshot to the VM executable if... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/partial_snapshots/
Patch Set: Created 10 years, 10 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 | Annotate | Revision Log
« src/api.cc ('K') | « src/bootstrapper.cc ('k') | src/heap.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 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 thread->set_stack_is_cooked(false); 352 thread->set_stack_is_cooked(false);
353 } 353 }
354 354
355 355
356 void StackFrame::Cook() { 356 void StackFrame::Cook() {
357 Code* code = this->code(); 357 Code* code = this->code();
358 ASSERT(code->IsCode()); 358 ASSERT(code->IsCode());
359 for (StackHandlerIterator it(this, top_handler()); !it.done(); it.Advance()) { 359 for (StackHandlerIterator it(this, top_handler()); !it.done(); it.Advance()) {
360 it.handler()->Cook(code); 360 it.handler()->Cook(code);
361 } 361 }
362 printf("Cook %p (%d)\n", (void*)(pc()), code->kind());
363 ASSERT(code->contains(pc())); 362 ASSERT(code->contains(pc()));
364 set_pc(AddressFrom<Address>(pc() - code->instruction_start())); 363 set_pc(AddressFrom<Address>(pc() - code->instruction_start()));
365 } 364 }
366 365
367 366
368 void StackFrame::Uncook() { 367 void StackFrame::Uncook() {
369 Code* code = this->code(); 368 Code* code = this->code();
370 ASSERT(code->IsCode()); 369 ASSERT(code->IsCode());
371 for (StackHandlerIterator it(this, top_handler()); !it.done(); it.Advance()) { 370 for (StackHandlerIterator it(this, top_handler()); !it.done(); it.Advance()) {
372 it.handler()->Uncook(code); 371 it.handler()->Uncook(code);
373 } 372 }
374 set_pc(code->instruction_start() + OffsetFrom(pc())); 373 set_pc(code->instruction_start() + OffsetFrom(pc()));
375 printf("Uncook %p (%d)\n", (void*)(pc()), code->kind());
376 ASSERT(code->contains(pc())); 374 ASSERT(code->contains(pc()));
377 } 375 }
378 376
379 377
380 StackFrame::Type StackFrame::GetCallerState(State* state) const { 378 StackFrame::Type StackFrame::GetCallerState(State* state) const {
381 ComputeCallerState(state); 379 ComputeCallerState(state);
382 return ComputeType(state); 380 return ComputeType(state);
383 } 381 }
384 382
385 383
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after
752 reg_code[i++] = r; 750 reg_code[i++] = r;
753 751
754 ASSERT(i == kNumJSCallerSaved); 752 ASSERT(i == kNumJSCallerSaved);
755 } 753 }
756 ASSERT(0 <= n && n < kNumJSCallerSaved); 754 ASSERT(0 <= n && n < kNumJSCallerSaved);
757 return reg_code[n]; 755 return reg_code[n];
758 } 756 }
759 757
760 758
761 } } // namespace v8::internal 759 } } // namespace v8::internal
OLDNEW
« src/api.cc ('K') | « src/bootstrapper.cc ('k') | src/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698