Fix a stale reference use.
It is unsafe to use an expression like
klass.Get() == ResolveType()
where the `ResolveType()` call can invalidate the plain
pointer already retrieved from a Handle<>.
We fix this in HInstructionBuilder::BuildLoadClass() by
reordering the code and we change the prefix of related
functions from "Get" to "Resolve" to better express their
semantics. We also pass the ScopedObjectAccess helper all
the way to the `ResolveClassFrom()` to avoid constructing
a new one.
Test: m test-art-host-gtest
Test: testrunner.py --host
Bug: 31113334
Change-Id: I13c1ea356386f28fdc9548da781982f9774080f1
2 files changed