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

Unified Diff: src/isolate.cc

Issue 769263002: Add support for enabling DCHECKs in release mode (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 6 years 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
Index: src/isolate.cc
diff --git a/src/isolate.cc b/src/isolate.cc
index 09ca02854f12282e81d70327209e7c0f52f1c903..65d9d0a43fca09f0dcd30081e29f9bb85cb3d793 100644
--- a/src/isolate.cc
+++ b/src/isolate.cc
@@ -118,7 +118,7 @@ base::Thread::LocalStorageKey Isolate::per_isolate_thread_data_key_;
base::LazyMutex Isolate::thread_data_table_mutex_ = LAZY_MUTEX_INITIALIZER;
Isolate::ThreadDataTable* Isolate::thread_data_table_ = NULL;
base::Atomic32 Isolate::isolate_counter_ = 0;
-#if DEBUG
+#if DCHECK_IS_ON
base::Atomic32 Isolate::isolate_key_created_ = 0;
#endif
@@ -160,7 +160,7 @@ void Isolate::InitializeOncePerProcess() {
base::LockGuard<base::Mutex> lock_guard(thread_data_table_mutex_.Pointer());
CHECK(thread_data_table_ == NULL);
isolate_key_ = base::Thread::CreateThreadLocalKey();
-#if DEBUG
+#if DCHECK_IS_ON
base::NoBarrier_Store(&isolate_key_created_, 1);
#endif
thread_id_key_ = base::Thread::CreateThreadLocalKey();
@@ -228,7 +228,7 @@ void Isolate::IterateDeferredHandles(ObjectVisitor* visitor) {
}
-#ifdef DEBUG
+#if DCHECK_IS_ON
bool Isolate::IsDeferredHandle(Object** handle) {
// Each DeferredHandles instance keeps the handles to one job in the
// concurrent recompilation queue, containing a list of blocks. Each block
@@ -2348,7 +2348,7 @@ Object* Isolate::FindCodeObject(Address a) {
}
-#ifdef DEBUG
+#if DCHECK_IS_ON
#define ISOLATE_FIELD_OFFSET(type, name, ignored) \
const intptr_t Isolate::name##_debug_offset_ = OFFSET_OF(Isolate, name##_);
ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET)

Powered by Google App Engine
This is Rietveld 408576698