From 6f342b2269e769a27dd0476cc4dc8a9c93c20235 Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Mon, 26 Jun 2017 23:08:26 +0200 Subject: Remove hasZealMode(mode) and callers --- js/src/gc/GCRuntime.h | 2 -- js/src/gc/Nursery.cpp | 7 ++----- js/src/gc/Zone.h | 6 +----- 3 files changed, 3 insertions(+), 12 deletions(-) (limited to 'js/src/gc') diff --git a/js/src/gc/GCRuntime.h b/js/src/gc/GCRuntime.h index 5252903f3..a426d759b 100644 --- a/js/src/gc/GCRuntime.h +++ b/js/src/gc/GCRuntime.h @@ -600,7 +600,6 @@ class GCRuntime void finishRoots(); void finish(); - inline bool hasZealMode(ZealMode mode); inline void clearZealMode(ZealMode mode); inline bool upcomingZealousGC(); inline bool needZealousGC(); @@ -1355,7 +1354,6 @@ class MOZ_RAII AutoMaybeStartBackgroundAllocation } }; -inline bool GCRuntime::hasZealMode(ZealMode mode) { return false; } inline void GCRuntime::clearZealMode(ZealMode mode) { } inline bool GCRuntime::upcomingZealousGC() { return false; } inline bool GCRuntime::needZealousGC() { return false; } diff --git a/js/src/gc/Nursery.cpp b/js/src/gc/Nursery.cpp index 3a3860d6d..72530b31b 100644 --- a/js/src/gc/Nursery.cpp +++ b/js/src/gc/Nursery.cpp @@ -219,11 +219,8 @@ js::Nursery::isEmpty() const MOZ_ASSERT(runtime_); if (!isEnabled()) return true; - - if (!runtime_->hasZealMode(ZealMode::GenerationalGC)) { - MOZ_ASSERT(currentStartChunk_ == 0); - MOZ_ASSERT(currentStartPosition_ == chunk(0).start()); - } + MOZ_ASSERT(currentStartChunk_ == 0); + MOZ_ASSERT(currentStartPosition_ == chunk(0).start()); return position() == currentStartPosition_; } diff --git a/js/src/gc/Zone.h b/js/src/gc/Zone.h index a3a6dc07f..84d6f03dd 100644 --- a/js/src/gc/Zone.h +++ b/js/src/gc/Zone.h @@ -253,11 +253,7 @@ struct Zone : public JS::shadow::Zone, // possibly at other times too. uint64_t gcNumber(); - bool compileBarriers() const { return compileBarriers(needsIncrementalBarrier()); } - bool compileBarriers(bool needsIncrementalBarrier) const { - return needsIncrementalBarrier || - runtimeFromMainThread()->hasZealMode(js::gc::ZealMode::VerifierPre); - } + bool compileBarriers() const { return needsIncrementalBarrier(); } enum ShouldUpdateJit { DontUpdateJit, UpdateJit }; void setNeedsIncrementalBarrier(bool needs, ShouldUpdateJit updateJit); -- cgit v1.2.3