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

Unified Diff: src/global-handles.cc

Issue 12984006: Disable zapping of global handles in release mode. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed Jakob Kummerow's offline comments. Created 7 years, 9 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 | « build/common.gypi ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/global-handles.cc
diff --git a/src/global-handles.cc b/src/global-handles.cc
index 14c00f1997e2e2f3f83d31a79b5598142d988974..cb3115abfca7db7ce9baec4a29c9da134437c223 100644
--- a/src/global-handles.cc
+++ b/src/global-handles.cc
@@ -72,7 +72,7 @@ class GlobalHandles::Node {
Internals::kNodeIsPartiallyDependentShift);
}
-#ifdef DEBUG
+#ifdef ENABLE_EXTRA_CHECKS
~Node() {
// TODO(1428): if it's a weak handle we should have invoked its callback.
// Zap the values for eager trapping.
@@ -111,10 +111,9 @@ class GlobalHandles::Node {
void Release(GlobalHandles* global_handles) {
ASSERT(state() != FREE);
set_state(FREE);
- // TODO(mstarzinger): Put behind debug flag once embedders are stabilized.
- object_ = reinterpret_cast<Object*>(kGlobalHandleZapValue);
-#ifdef DEBUG
+#ifdef ENABLE_EXTRA_CHECKS
// Zap the values for eager trapping.
+ object_ = reinterpret_cast<Object*>(kGlobalHandleZapValue);
class_id_ = v8::HeapProfiler::kPersistentHandleNoClassId;
set_independent(false);
set_partially_dependent(false);
« no previous file with comments | « build/common.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698