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

Unified Diff: src/sampler.cc

Issue 633363002: Get rid of isolate state. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: updates Created 6 years, 2 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 | « src/isolate.cc ('k') | src/v8threads.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/sampler.cc
diff --git a/src/sampler.cc b/src/sampler.cc
index 4633712f1c4743bbbbdc459e2a9fc231c04a739b..95b7f4bc330033d441dc0bb7ae01ea4940653f01 100644
--- a/src/sampler.cc
+++ b/src/sampler.cc
@@ -335,7 +335,7 @@ void SignalHandler::HandleProfilerSignal(int signal, siginfo_t* info,
USE(info);
if (signal != SIGPROF) return;
Isolate* isolate = Isolate::UnsafeCurrent();
- if (isolate == NULL || !isolate->IsInitialized() || !isolate->IsInUse()) {
+ if (isolate == NULL || !isolate->IsInUse()) {
// We require a fully initialized and entered isolate.
return;
}
@@ -542,7 +542,6 @@ class SamplerThread : public base::Thread {
// profiled. We must not suspend.
for (int i = 0; i < active_samplers_.length(); ++i) {
Sampler* sampler = active_samplers_.at(i);
- if (!sampler->isolate()->IsInitialized()) continue;
if (!sampler->IsProfiling()) continue;
sampler->DoSample();
}
@@ -572,7 +571,6 @@ SamplerThread* SamplerThread::instance_ = NULL;
//
DISABLE_ASAN void TickSample::Init(Isolate* isolate,
const v8::RegisterState& regs) {
- DCHECK(isolate->IsInitialized());
timestamp = base::TimeTicks::HighResolutionNow();
pc = reinterpret_cast<Address>(regs.pc);
state = isolate->current_vm_state();
@@ -612,7 +610,6 @@ DISABLE_ASAN void TickSample::Init(Isolate* isolate,
void TickSample::GetStackSample(Isolate* isolate, const v8::RegisterState& regs,
void** frames, size_t frames_limit,
v8::SampleInfo* sample_info) {
- DCHECK(isolate->IsInitialized());
sample_info->frames_count = 0;
sample_info->vm_state = isolate->current_vm_state();
if (sample_info->vm_state == GC) return;
« no previous file with comments | « src/isolate.cc ('k') | src/v8threads.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698