I notice in art/build/art.go, ART_READ_BARRIER_TYPE can be set to BROOKS. Once I made the change and build, compiler gives me error about noreturn of function mirror::Object::SetReadBarrierState, I have to change the declaration from
#ifndef USE_BAKER_OR_BROOKS_READ_BARRIER
NO_RETURN
#endif
ALWAYS_INLINE void SetReadBarrierState(uint32_t rb_state) REQUIRES_SHARED(Locks::mutator_lock_);
to
#ifndef USE_BAKER_READ_BARRIER
NO_RETURN
#endif
ALWAYS_INLINE void SetReadBarrierState(uint32_t rb_state) REQUIRES_SHARED(Locks::mutator_lock_);
Then compiler gives me another error:
art/runtime/gc/collector/concurrent_copying.cc:2311:3: error: static_assert failed "Object header size does not match"
static_assert(kObjectHeaderSize == sizeof(mirror::HeapReference<mirror::Class>) +
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
Is BROOKS barrier type still supported?