Fix new bss roots assertion during marking phase
Earlier we are asserting that a bss root can only be a class. But it's
also possible to be a string.
Also enables 092-locale art-test.
Bug: 288532125
Bug: 288603111
Test: art/test/testrunner/testrunner.py --host -t 092-locale
Change-Id: I1e64f571b4ab7121b75c0902b2b4477dc086f13b
diff --git a/runtime/class_linker.cc b/runtime/class_linker.cc
index 687ab09..9aa29b8 100644
--- a/runtime/class_linker.cc
+++ b/runtime/class_linker.cc
@@ -2424,7 +2424,7 @@
for (GcRoot<mirror::Object>& root : oat_file->GetBssGcRoots()) {
ObjPtr<mirror::Object> old_ref = root.Read<kWithoutReadBarrier>();
if (old_ref != nullptr) {
- DCHECK(old_ref->IsClass());
+ DCHECK(old_ref->IsClass() || old_ref->IsString());
root.VisitRoot(visitor, RootInfo(kRootStickyClass));
ObjPtr<mirror::Object> new_ref = root.Read<kWithoutReadBarrier>();
// Concurrent moving GC marked new roots through the to-space invariant.
diff --git a/test/knownfailures.json b/test/knownfailures.json
index ff0b267..adf201c 100644
--- a/test/knownfailures.json
+++ b/test/knownfailures.json
@@ -1580,11 +1580,5 @@
"tests": ["2262-miranda-methods"],
"variant": "jvm",
"description": ["jvm doesn't seem to support calling miranda methods via CallNonVirtual."]
- },
- {
- "tests": ["092-locale"],
- "env_vars": {"ART_USE_READ_BARRIER": "false"},
- "bug": "b/288532125",
- "description": ["Crashes during shutdown"]
}
]