| Index: src/cpu-profiler.cc
|
| diff --git a/src/cpu-profiler.cc b/src/cpu-profiler.cc
|
| index 3d9dc6780b2aefac2f45ae619281ccbf5c036d3c..b1af621cccc1a3425e87534faafa8b14cea77c7f 100644
|
| --- a/src/cpu-profiler.cc
|
| +++ b/src/cpu-profiler.cc
|
| @@ -64,14 +64,15 @@ void ProfilerEventsProcessor::Enqueue(const CodeEventsContainer& event) {
|
|
|
| void ProfilerEventsProcessor::AddCurrentStack(Isolate* isolate) {
|
| TickSampleEventRecord record(last_code_event_id_);
|
| - TickSample* sample = &record.sample;
|
| - sample->state = isolate->current_vm_state();
|
| - sample->pc = reinterpret_cast<Address>(sample); // Not NULL.
|
| - for (StackTraceFrameIterator it(isolate);
|
| - !it.done() && sample->frames_count < TickSample::kMaxFramesCount;
|
| - it.Advance()) {
|
| - sample->stack[sample->frames_count++] = it.frame()->pc();
|
| + RegisterState regs;
|
| + StackFrameIterator it(isolate);
|
| + if (!it.done()) {
|
| + StackFrame* frame = it.frame();
|
| + regs.sp = frame->sp();
|
| + regs.fp = frame->fp();
|
| + regs.pc = frame->pc();
|
| }
|
| + record.sample.Init(isolate, regs);
|
| ticks_from_vm_buffer_.Enqueue(record);
|
| }
|
|
|
| @@ -260,7 +261,7 @@ void CpuProfiler::CodeCreateEvent(Logger::LogEventsAndTags tag,
|
| Code* code,
|
| SharedFunctionInfo* shared,
|
| CompilationInfo* info,
|
| - Name* source, int line) {
|
| + Name* source, int line, int column) {
|
| if (FilterOutCodeCreateEvent(tag)) return;
|
| CodeEventsContainer evt_rec(CodeEventRecord::CODE_CREATION);
|
| CodeCreateEventRecord* rec = &evt_rec.CodeCreateEventRecord_;
|
| @@ -270,7 +271,8 @@ void CpuProfiler::CodeCreateEvent(Logger::LogEventsAndTags tag,
|
| profiles_->GetFunctionName(shared->DebugName()),
|
| CodeEntry::kEmptyNamePrefix,
|
| profiles_->GetName(source),
|
| - line);
|
| + line,
|
| + column);
|
| if (info) {
|
| rec->entry->set_no_frame_ranges(info->ReleaseNoFrameRanges());
|
| }
|
|
|