8383631: Test vmTestbase/nsk/jdb/kill/kill003/kill003.java failed - possible NullPointerException#31048
8383631: Test vmTestbase/nsk/jdb/kill/kill003/kill003.java failed - possible NullPointerException#31048plummercj wants to merge 1 commit intoopenjdk:masterfrom
Conversation
|
👋 Welcome back cjplummer! A progress list of the required criteria for merging this PR into |
|
@plummercj This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 11 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
|
@plummercj The following label will be automatically applied to this pull request:
When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command. |
|
test |
|
Unfortunately this fix does not work with virtual threads because one of the prompts ends up being old-m-a-i-n[1] instead of main[1]. I'm going to need a different fix. I was working towards one yesterday which I abandoned after I found the solution in the PR. I'll see if I can get that fix working. |
The test sees the following output and is supposed to detect the "main[1]" prompt to indicate it is done with the "locals" command that was issued, and then issue a "cont" command:
[9:13:15.40] Sending command: locals
[9:13:15.560] reply[0]: Method arguments:
[9:13:15.561] reply[1]: args = instance of java.lang.String[3] (id=669)
[9:13:15.561] reply[2]: Local variables:
[9:13:15.561] reply[3]: main[1]
[9:13:15.561] Sending command: cont
However, the output instead looks like this:
[21:15:18.114] Sending command: locals
[21:15:18.515] reply[0]: Method arguments:
[21:15:18.515] reply[1]: args = instance of java.lang.String[3] (id=686)
[21:15:18.515] reply[2]: Local variables:
[21:15:18.515] Sending command: cont
[21:15:18.716] reply[0]: main[1] >
The JdbTest.findPrompt() code looks for a pattern of characters, followed by '[', then a number, then ']'. Unfortunately it matches the String[3] text you see in the output. Because of that the test thought the "locals" command had completed, and issued the "cont" command too soon, which gets the test out of sync.
Apparently some tests have had this same issue before and a solution was already available. You just need to set compoundPromptIdent to the prompt that the test expects (sans the square brackets part).
I also fixed a couple of comment typos I noticed in JdbTest while debugging this.
Tested by running kill003 a couple hundred times on the failing platform and with the failing JVM args.
Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/31048/head:pull/31048$ git checkout pull/31048Update a local copy of the PR:
$ git checkout pull/31048$ git pull https://git.openjdk.org/jdk.git pull/31048/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 31048View PR using the GUI difftool:
$ git pr show -t 31048Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/31048.diff
Using Webrev
Link to Webrev Comment