diff options
author | 2024-09-20 14:25:58 +0100 | |
---|---|---|
committer | 2024-09-27 15:22:20 +0000 | |
commit | 8ab90b3199254090a308cdf2479b91db44ea00ef (patch) | |
tree | b1587d5fc4c72a516c7c25713a6e35e8a8f35ed1 | |
parent | aed7b8612d9c62e472c83783631a76bea9239ecf (diff) |
Remove volatile from GUARDED_BY variables
Test: art/test/testrunner/testrunner.py --host --64 --optimizing -b
Change-Id: Id0a3125bc8d85d6ca85759c95658a9f46a89b3bc
-rw-r--r-- | runtime/gc/heap.h | 8 | ||||
-rw-r--r-- | runtime/trace.cc | 2 | ||||
-rw-r--r-- | runtime/trace.h | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/runtime/gc/heap.h b/runtime/gc/heap.h index 2edb0ee8a8..13af888204 100644 --- a/runtime/gc/heap.h +++ b/runtime/gc/heap.h @@ -1499,16 +1499,16 @@ class Heap { // matter. // Collector type of the running GC. - volatile CollectorType collector_type_running_ GUARDED_BY(gc_complete_lock_); + CollectorType collector_type_running_ GUARDED_BY(gc_complete_lock_); // Cause of the last running or attempted GC or GC-like action. - volatile GcCause last_gc_cause_ GUARDED_BY(gc_complete_lock_); + GcCause last_gc_cause_ GUARDED_BY(gc_complete_lock_); // The thread currently running the GC. - volatile Thread* thread_running_gc_ GUARDED_BY(gc_complete_lock_); + Thread* thread_running_gc_ GUARDED_BY(gc_complete_lock_); // Last Gc type we ran. Used by WaitForConcurrentGc to know which Gc was waited on. - volatile collector::GcType last_gc_type_ GUARDED_BY(gc_complete_lock_); + collector::GcType last_gc_type_ GUARDED_BY(gc_complete_lock_); collector::GcType next_gc_type_; // Maximum size that the heap can reach. diff --git a/runtime/trace.cc b/runtime/trace.cc index 3b7f73284e..bc03c505c4 100644 --- a/runtime/trace.cc +++ b/runtime/trace.cc @@ -93,7 +93,7 @@ static constexpr size_t kScalingFactorEncodedEntries = 6; TraceClockSource Trace::default_clock_source_ = kDefaultTraceClockSource; -Trace* volatile Trace::the_trace_ = nullptr; +Trace* Trace::the_trace_ = nullptr; pthread_t Trace::sampling_pthread_ = 0U; std::unique_ptr<std::vector<ArtMethod*>> Trace::temp_stack_trace_; diff --git a/runtime/trace.h b/runtime/trace.h index 445cd7e3af..ffd70aa8e6 100644 --- a/runtime/trace.h +++ b/runtime/trace.h @@ -615,7 +615,7 @@ class Trace final : public instrumentation::InstrumentationListener, public Clas uint64_t timestamp_counter) REQUIRES_SHARED(Locks::mutator_lock_); // Singleton instance of the Trace or null when no method tracing is active. - static Trace* volatile the_trace_ GUARDED_BY(Locks::trace_lock_); + static Trace* the_trace_ GUARDED_BY(Locks::trace_lock_); // The default profiler clock source. static TraceClockSource default_clock_source_; |