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

Side by Side Diff: src/profiler/cpu-profiler.cc

Issue 2105943002: Expose TickSample and its APIs in v8-profiler.h (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebase Created 4 years, 5 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/log.cc ('k') | src/profiler/profile-generator.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 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 "src/profiler/cpu-profiler.h" 5 #include "src/profiler/cpu-profiler.h"
6 6
7 #include "src/debug/debug.h" 7 #include "src/debug/debug.h"
8 #include "src/deoptimizer.h" 8 #include "src/deoptimizer.h"
9 #include "src/frames-inl.h" 9 #include "src/frames-inl.h"
10 #include "src/locked-queue-inl.h" 10 #include "src/locked-queue-inl.h"
11 #include "src/log-inl.h" 11 #include "src/log-inl.h"
12 #include "src/profiler/cpu-profiler-inl.h" 12 #include "src/profiler/cpu-profiler-inl.h"
13 #include "src/vm-state-inl.h" 13 #include "src/vm-state-inl.h"
14 14
15 #include "include/v8-profiler.h"
16
17 namespace v8 { 15 namespace v8 {
18 namespace internal { 16 namespace internal {
19 17
20 static const int kProfilerStackSize = 64 * KB; 18 static const int kProfilerStackSize = 64 * KB;
21 19
22 class CpuSampler : public sampler::Sampler { 20 class CpuSampler : public sampler::Sampler {
23 public: 21 public:
24 CpuSampler(Isolate* isolate, ProfilerEventsProcessor* processor) 22 CpuSampler(Isolate* isolate, ProfilerEventsProcessor* processor)
25 : sampler::Sampler(reinterpret_cast<v8::Isolate*>(isolate)), 23 : sampler::Sampler(reinterpret_cast<v8::Isolate*>(isolate)),
26 processor_(processor) {} 24 processor_(processor) {}
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
383 ReportBuiltinEventRecord* rec = &evt_rec.ReportBuiltinEventRecord_; 381 ReportBuiltinEventRecord* rec = &evt_rec.ReportBuiltinEventRecord_;
384 Builtins::Name id = static_cast<Builtins::Name>(i); 382 Builtins::Name id = static_cast<Builtins::Name>(i);
385 rec->start = builtins->builtin(id)->address(); 383 rec->start = builtins->builtin(id)->address();
386 rec->builtin_id = id; 384 rec->builtin_id = id;
387 processor_->Enqueue(evt_rec); 385 processor_->Enqueue(evt_rec);
388 } 386 }
389 } 387 }
390 388
391 } // namespace internal 389 } // namespace internal
392 } // namespace v8 390 } // namespace v8
OLDNEW
« no previous file with comments | « src/log.cc ('k') | src/profiler/profile-generator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698