Remove special case for young-gen collection in ConcurrentCopying::IsMarked.
Method art::gc::collector::ConcurrentCopying::IsMarked contained a
short-circuit for non-region spaces in the case of young-generation
collection, that would return the reference as-is. This change disables
this code, as it seemed to break reference processing, which relies on
art::gc::collector::ConcurrentCopying::IsNullOrMarkedHeapReference and
art::gc::collector::ConcurrentCopying::IsMarked.
Test: ART run-tests & gtests, libcore tests, JDWP tests (host & device)
Test: Device/emulator boot test
Bug: 67628039
Bug: 12687968
Change-Id: Iab7a8261a2a13f2f36516ec267dd1b3f574f0324
diff --git a/runtime/gc/collector/concurrent_copying.cc b/runtime/gc/collector/concurrent_copying.cc
index dc00342..70b89cf 100644
--- a/runtime/gc/collector/concurrent_copying.cc
+++ b/runtime/gc/collector/concurrent_copying.cc
@@ -2689,10 +2689,6 @@
// At this point, `from_ref` should not be in the region space
// (i.e. within an "unused" region).
DCHECK(!region_space_->HasAddress(from_ref)) << from_ref;
- if (kEnableGenerationalConcurrentCopyingCollection && young_gen_) {
- // Only sweeps the from space.
- return from_ref;
- }
// from_ref is in a non-moving space.
if (immune_spaces_.ContainsObject(from_ref)) {
// An immune object is alive.