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

Unified Diff: src/api.cc

Issue 2189513002: Move SimulatorHelper into V8 out of profiler clients. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Update Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/v8-profiler.h ('k') | src/log.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index 571f2ca3c5800810d93853080ab825b743722056..5e9b7bfb0adc3658e642309098fde9964bce489c 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -7647,20 +7647,14 @@ bool Isolate::GetHeapCodeAndMetadataStatistics(
void Isolate::GetStackSample(const RegisterState& state, void** frames,
size_t frames_limit, SampleInfo* sample_info) {
-#if defined(USE_SIMULATOR)
- RegisterState regs;
- i::Isolate* isolate = reinterpret_cast<i::Isolate*>(this);
- if (!i::SimulatorHelper::FillRegisters(isolate, &regs)) {
- sample_info->frames_count = 0;
- sample_info->vm_state = OTHER;
- sample_info->external_callback_entry = nullptr;
+ RegisterState regs = state;
+ if (TickSample::GetStackSample(this, &regs, TickSample::kSkipCEntryFrame,
+ frames, frames_limit, sample_info)) {
return;
}
-#else
- const RegisterState& regs = state;
-#endif
- TickSample::GetStackSample(this, regs, TickSample::kSkipCEntryFrame, frames,
- frames_limit, sample_info);
+ sample_info->frames_count = 0;
+ sample_info->vm_state = OTHER;
+ sample_info->external_callback_entry = nullptr;
}
size_t Isolate::NumberOfPhantomHandleResetsSinceLastCall() {
« no previous file with comments | « include/v8-profiler.h ('k') | src/log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698