ART: Change lock dumping
Return dex registers as well as dex PCs from FindLocksAtDexPc.
It is necessary to return the registers as the register used for
a monitor-enter operation may be aliased and overwritten by the
time the requested dex PC is reached.
It is at this point necessary to return a set of registers as
optimizations may have eliminated dead registers, and the verifier
has no notion of liveness.
A client of FindLocksAtDexPc should not assume that all registers
can be successfully retrieved from a stack frame, with the possibility
of none. Only a properly verified method (i.e., lock verification succeeded)
implies that at least one register should work for all locks held at
any point in the program.
Bug: 68703210
Test: art/test/testrunner/testrunner.py -b --host -t 167
Change-Id: I9027787e395cf8df0e7699a606665edb2ecb5136
diff --git a/test/Android.bp b/test/Android.bp
index 2d526d2..01e424d 100644
--- a/test/Android.bp
+++ b/test/Android.bp
@@ -364,8 +364,9 @@
"141-class-unload/jni_unload.cc",
"148-multithread-gc-annotations/gc_coverage.cc",
"149-suspend-all-stress/suspend_all.cc",
- "203-multi-checkpoint/multi_checkpoint.cc",
"154-gc-loop/heap_interface.cc",
+ "167-visit-locks/visit_locks.cc",
+ "203-multi-checkpoint/multi_checkpoint.cc",
"454-get-vreg/get_vreg_jni.cc",
"457-regs/regs_jni.cc",
"461-get-reference-vreg/get_reference_vreg_jni.cc",