[core] Only clear precompile on R or above
This commit is contained in:
parent
a08c5402bc
commit
2d8a9932f2
|
|
@ -42,6 +42,7 @@ namespace {
|
||||||
uint32_t access_flags = read32((char *) method + OFFSET_access_flags_in_ArtMethod);
|
uint32_t access_flags = read32((char *) method + OFFSET_access_flags_in_ArtMethod);
|
||||||
LOGI("setNonCompilable: access flags is 0x%x", access_flags);
|
LOGI("setNonCompilable: access flags is 0x%x", access_flags);
|
||||||
access_flags |= kAccCompileDontBother;
|
access_flags |= kAccCompileDontBother;
|
||||||
|
if (SDKVersion >= __ANDROID_API_R__)
|
||||||
access_flags &= ~kAccPreCompiled;
|
access_flags &= ~kAccPreCompiled;
|
||||||
write32((char *) method + OFFSET_access_flags_in_ArtMethod, access_flags);
|
write32((char *) method + OFFSET_access_flags_in_ArtMethod, access_flags);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue