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

Side by Side Diff: src/platform-macos.cc

Issue 546089: Fix issue 553: function frame is skipped in profile when compare stub is called. (Closed)
Patch Set: Introduced dedicated log event types, added stuff for DevTools Created 10 years, 11 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 | « src/platform-linux.cc ('k') | src/platform-win32.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 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 541 matching lines...) Expand 10 before | Expand all | Expand 10 after
552 #define REGISTER_FIELD(name) e ## name 552 #define REGISTER_FIELD(name) e ## name
553 #endif // __DARWIN_UNIX03 553 #endif // __DARWIN_UNIX03
554 #else 554 #else
555 #error Unsupported Mac OS X host architecture. 555 #error Unsupported Mac OS X host architecture.
556 #endif // V8_HOST_ARCH 556 #endif // V8_HOST_ARCH
557 557
558 if (thread_get_state(profiled_thread_, 558 if (thread_get_state(profiled_thread_,
559 flavor, 559 flavor,
560 reinterpret_cast<natural_t*>(&state), 560 reinterpret_cast<natural_t*>(&state),
561 &count) == KERN_SUCCESS) { 561 &count) == KERN_SUCCESS) {
562 sample.pc = state.REGISTER_FIELD(ip); 562 sample.pc = reinterpret_cast<Address>(state.REGISTER_FIELD(ip));
563 sample.sp = state.REGISTER_FIELD(sp); 563 sample.sp = reinterpret_cast<Address>(state.REGISTER_FIELD(sp));
564 sample.fp = state.REGISTER_FIELD(bp); 564 sample.fp = reinterpret_cast<Address>(state.REGISTER_FIELD(bp));
565 sampler_->SampleStack(&sample); 565 sampler_->SampleStack(&sample);
566 } 566 }
567 thread_resume(profiled_thread_); 567 thread_resume(profiled_thread_);
568 } 568 }
569 569
570 // We always sample the VM state. 570 // We always sample the VM state.
571 sample.state = Logger::state(); 571 sample.state = Logger::state();
572 // Invoke tick handler with program counter and stack pointer. 572 // Invoke tick handler with program counter and stack pointer.
573 sampler_->Tick(&sample); 573 sampler_->Tick(&sample);
574 574
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
634 634
635 // Deallocate Mach port for thread. 635 // Deallocate Mach port for thread.
636 if (IsProfiling()) { 636 if (IsProfiling()) {
637 mach_port_deallocate(data_->task_self_, data_->profiled_thread_); 637 mach_port_deallocate(data_->task_self_, data_->profiled_thread_);
638 } 638 }
639 } 639 }
640 640
641 #endif // ENABLE_LOGGING_AND_PROFILING 641 #endif // ENABLE_LOGGING_AND_PROFILING
642 642
643 } } // namespace v8::internal 643 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/platform-linux.cc ('k') | src/platform-win32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698