Faster access to unresolved classes from compiled code.

Add two new load kinds to LoadClass, similar to kBssEntry
but using the access-checking entrypoint on the slow-path.
One is used for classes that are in the literal package and
the other for classes outside the literal package of the
compiling class. Associate new .bss entries with these load
kinds and update them from entrypoints based on the resolved
class properties. If the resolved class is public, both
types of entries can be updated, otherwise only the package
local entry can be updated and only if the defining class
loader of the class is the same as the caller's defining
class loader (which is identical for all code in an oat
file) because the run time access check for same package
requires both class loader and literal package name match.

Test: Additional tests in 727-checker-unresolved-class.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Test: aosp_blueline-userdebug boots.
Test: run-gtests.sh
Test: testrunner.py --target --optimizing
Bug: 161898207
Change-Id: I281e06ac2825caf81c6d7ee3128af833abd39992
20 files changed