A test for this is in regressionTestsInWaiting/SyncLineNumberTest.sh.
Basically, it uses jdb to stop at a line (eg line 12) that contains
synchronized(object1) {
where the monitor for object1 is already locked. It then does
a 'next' which causes the thread to wait for the monitor. If the thread is
suspended, we find that its location is now the BCI for line 13. It should
still be the BCI of the monitorenter which will cause the line
number to be reported as 12.
This test passes on IA64.
See also
4787861 JDI: wrong location of step event after thrown exception
Basically, it uses jdb to stop at a line (eg line 12) that contains
synchronized(object1) {
where the monitor for object1 is already locked. It then does
a 'next' which causes the thread to wait for the monitor. If the thread is
suspended, we find that its location is now the BCI for line 13. It should
still be the BCI of the monitorenter which will cause the line
number to be reported as 12.
This test passes on IA64.
See also
4787861 JDI: wrong location of step event after thrown exception
- duplicates
-
JDK-4527285 frameloc001 fails in merlin - GetFrameLocation incorrect in -Xint mode
-
- Closed
-