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, ®s)) { |
- sample_info->frames_count = 0; |
- sample_info->vm_state = OTHER; |
- sample_info->external_callback_entry = nullptr; |
+ RegisterState regs = state; |
+ if (TickSample::GetStackSample(this, ®s, 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() { |