Lines Matching refs:ref
48 // the is_gray load to the ref field (ptr) load to avoid needing a load-load barrier between
57 MirrorType* ref = ref_addr->AsMirrorPtr();
58 MirrorType* old_ref = ref;
61 ref = reinterpret_cast<MirrorType*>(Mark(ref));
64 if (kAlwaysUpdateField && ref != old_ref) {
66 offset, old_ref, ref);
69 AssertToSpaceInvariant(obj, offset, ref);
70 return ref;
75 MirrorType* ref = ref_addr->AsMirrorPtr();
76 MirrorType* old_ref = ref;
80 ref = reinterpret_cast<MirrorType*>(Mark(old_ref));
82 if (ref != old_ref) {
84 offset, old_ref, ref);
87 AssertToSpaceInvariant(obj, offset, ref);
88 return ref;
102 MirrorType* ref = *root;
115 ref = reinterpret_cast<MirrorType*>(Mark(ref));
117 AssertToSpaceInvariant(gc_root_source, ref);
118 return ref;
121 return ref;
126 Runtime::Current()->GetHeap()->GetReadBarrierTable()->IsSet(ref)) {
127 MirrorType* old_ref = ref;
128 ref = reinterpret_cast<MirrorType*>(Mark(old_ref));
130 if (ref != old_ref) {
132 atomic_root->CompareExchangeStrongRelaxed(old_ref, ref);
135 AssertToSpaceInvariant(gc_root_source, ref);
136 return ref;
142 return ref;
150 MirrorType* ref = root->AsMirrorPtr();
156 ref = reinterpret_cast<MirrorType*>(Mark(ref));
158 AssertToSpaceInvariant(gc_root_source, ref);
159 return ref;
162 return ref;
167 Runtime::Current()->GetHeap()->GetReadBarrierTable()->IsSet(ref)) {
168 auto old_ref = mirror::CompressedReference<MirrorType>::FromMirrorPtr(ref);
169 ref = reinterpret_cast<MirrorType*>(Mark(ref));
170 auto new_ref = mirror::CompressedReference<MirrorType>::FromMirrorPtr(ref);
178 AssertToSpaceInvariant(gc_root_source, ref);
179 return ref;
181 return ref;
186 inline MirrorType* ReadBarrier::IsMarked(MirrorType* ref) {
190 return ref;
193 if (ref == nullptr) {
198 return ref;
202 Runtime::Current()->GetHeap()->ConcurrentCopyingCollector()->IsMarked(ref));
224 mirror::Object* ref) {
226 if (ref == nullptr || IsDuringStartup()) {
230 AssertToSpaceInvariant(obj, offset, ref);
235 mirror::Object* ref) {
237 if (ref == nullptr || IsDuringStartup()) {
241 AssertToSpaceInvariant(gc_root_source, ref);