DO NOT MERGE: Change IMC logging to LOG(WARNING)
LOG(DEBUG) is discarded for release apps, upgrade temporary logging
to LOG(WARNING). Also change the unique ID to 'APPCOMPAT_IMC', should
be unique enough.
Same as I3a7986746922e9c4d7304ac6463e06a3bec199db, should be reverted
by dbrazdil@ ASAP.
Bug: 2131483
Test: manual
Change-Id: I2d81594db7a95ac64019a118fed3f188c2ebfda5
diff --git a/runtime/class_linker.cc b/runtime/class_linker.cc
index 857e07a..44297f1 100644
--- a/runtime/class_linker.cc
+++ b/runtime/class_linker.cc
@@ -3745,7 +3745,7 @@
// (b) class loader context
// (c) if it used the public API, as opposed to using reflection on DexPathList
// (d) if the dex files are being registered with IMC
- // "76m1yHF5" is used as a random char sequence for easy grep-ing.
+ // "APPCOMPAT_IMC" is used as a grep-able tag.
if (dex_file.loaded_with_imc_ != DexFile::kNotLoadedWithImc) {
ScopedObjectAccessUnchecked soa(self);
StackHandleScope<1> hs(self);
@@ -3754,8 +3754,8 @@
soa.AddLocalReference<jobject>(class_loader));
std::unique_ptr<ClassLoaderContext> context = ClassLoaderContext::CreateContextForClassLoader(
jclass_loader.get(), /* dex_elements= */ nullptr);
- LOG(DEBUG) << "76m1yHF5"
- << ", pkg_name=" << Runtime::Current()->GetProcessPackageName()
+ LOG(WARNING) << "APPCOMPAT_IMC"
+ << " pkg_name=" << Runtime::Current()->GetProcessPackageName()
<< ", context=" << context->EncodeContextForOatFile(/* base_dir= */ "")
<< ", used_public_api="
<< (dex_file.loaded_with_imc_ == DexFile::kLoadedWithImcPublicApi ? "true" : "false")