Reviewers: antonm,
Description:
Fix auto suspension of the sampler thread.
BUG=http://crbug.com/78267
Please review this at http://codereview.chromium.org/6801060/
Affected files:
M src/isolate.h
Index: src/isolate.h
diff --git a/src/isolate.h b/src/isolate.h
index
638658ba7a67a21a4c6cc68cb05765c4cfc4ad5c..f7371cf09a838fd44054b2ca743e671b52e52b4d
100644
--- a/src/isolate.h
+++ b/src/isolate.h
@@ -897,10 +897,10 @@ class Isolate {
void SetCurrentVMState(StateTag state) {
if (RuntimeProfiler::IsEnabled()) {
- if (state == JS) {
- // JS or non-JS -> JS transition.
+ if (thread_local_top_.current_vm_state_ != JS && state == JS) {
+ // Non-JS -> JS transition.
RuntimeProfiler::IsolateEnteredJS(this);
- } else if (thread_local_top_.current_vm_state_ == JS) {
+ } else if (thread_local_top_.current_vm_state_ == JS && state != JS)
{
// JS -> non-JS transition.
ASSERT(RuntimeProfiler::IsSomeIsolateInJS());
RuntimeProfiler::IsolateExitedJS(this);
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev