diff options
author | Vladimir Marko <vmarko@google.com> | 2018-07-23 15:30:52 +0100 |
---|---|---|
committer | Vladimir Marko <vmarko@google.com> | 2018-07-23 18:30:45 +0100 |
commit | fca0b491a34144acf6769ab9c5fb528ac81bd325 (patch) | |
tree | 3896bc10455308ed675886d8d8037d5358c1556d /compiler/optimizing/stack_map_test.cc | |
parent | fb9c672577ae9772557f72f9cecb77d4d24af585 (diff) |
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
Diffstat (limited to 'compiler/optimizing/stack_map_test.cc')
0 files changed, 0 insertions, 0 deletions