Skip to content

8252593: [TESTBUG] serviceability/jvmti/GetLocalVariable/GetLocalWithoutSuspendTest.java failed with JVMTI_ERROR_INVALID_SLOT #142

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

reinrich
Copy link
Member

@reinrich reinrich commented Sep 12, 2020

Continuing review [1] after transition to Git/Github.

I still cannot reproduce the issue.

RFC on alternatives:

  1. Integrate this change and ignore future JVMTI_ERROR_INVALID_SLOT
  2. Don't ignore JVMTI_ERROR_INVALID_SLOT but integrate the rest of this patch. If the test still fails with JVMTI_ERROR_INVALID_SLOT we will at least know the depth of the frame.
  3. Add trace code to VM_GetOrSetLocal in !PRODUCT or ASSERT configurations depending on an option or property.

Any other ideas?

I'm in favour of 1.

[1] http://mail.openjdk.java.net/pipermail/serviceability-dev/2020-September/032876.html


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8252593: [TESTBUG] serviceability/jvmti/GetLocalVariable/GetLocalWithoutSuspendTest.java failed with JVMTI_ERROR_INVALID_SLOT

Reviewers

Download

$ git fetch https://git.openjdk.java.net/jdk pull/142/head:pull/142
$ git checkout pull/142

…outSuspendTest.java failed with JVMTI_ERROR_INVALID_SLOT
@bridgekeeper
Copy link

bridgekeeper bot commented Sep 12, 2020

👋 Welcome back rrich! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Sep 12, 2020

@reinrich The following label will be automatically applied to this pull request: serviceability.

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 (add|remove) "label" command.

@openjdk openjdk bot added the serviceability serviceability-dev@openjdk.org label Sep 12, 2020
@reinrich reinrich marked this pull request as ready for review September 12, 2020 23:22
@openjdk openjdk bot added the rfr Pull request is ready for review label Sep 12, 2020
@mlbridge
Copy link

mlbridge bot commented Sep 12, 2020

Webrevs

@reinrich
Copy link
Member Author

Thanks @iignatev for providing the hint that helped finding the cause for the JVMTI_ERROR_INVALID_SLOT

https://bugs.openjdk.java.net/browse/JDK-8252593?focusedCommentId=14368599&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-14368599

I would like to take a different approach now for fixing this by making sure the JVMTI GetLocalObject() call refers to one of the recursiveMethod frames on stack.

How to do that? Can I close this PR and create a new branch JDK-8252593-2 and then a new PR?

@dcubed-ojdk
Copy link
Member

dcubed-ojdk commented Sep 15, 2020

You can also change the PR back to draft, revamp the changes and then
change the PR back to "ready for review" or whatever it's called.
However, I don't know the preferred protocol for such things.

@reinrich
Copy link
Member Author

Thanks @dcubed-ojdk ! I didn't know the PR can be converted back to draft. I will try that.

@reinrich reinrich marked this pull request as draft September 15, 2020 14:58
@openjdk openjdk bot removed the rfr Pull request is ready for review label Sep 15, 2020
@reinrich
Copy link
Member Author

I would like to take a different approach now for fixing this by making sure the JVMTI GetLocalObject() call refers to one of the recursiveMethod frames on stack.

After a closer look I don't think this is possible. The GetLocalObject() call should target a frame deep in the stack to prolongue the stackwalk. So the depth D will be large. This means the target thread has to wait in a frame that has more than D caller frames to make sure at D is a frame of recursiveMethod. This will make the test less sensitive as a regression test because if there is an unsafe stackwalk to find the target frame for the GetLocalObject() at depth D it will likely still succeed, because the target thread does not return from all the recursive activations of recursiveMethod.

So I'm still proposing the original fix which silently accepts JVMTI_ERROR_INVALID_SLOT.

@reinrich reinrich marked this pull request as ready for review September 15, 2020 19:21
@openjdk openjdk bot added the rfr Pull request is ready for review label Sep 15, 2020
@openjdk
Copy link

openjdk bot commented Sep 15, 2020

@reinrich This change now passes all automated pre-integration checks. In addition to the automated checks, the change must also fulfill all project specific requirements

After integration, the commit message will be:

8252593: [TESTBUG] serviceability/jvmti/GetLocalVariable/GetLocalWithoutSuspendTest.java failed with JVMTI_ERROR_INVALID_SLOT

Reviewed-by: sspitsyn, cjplummer
  • If you would like to add a summary, use the /summary command.
  • To credit additional contributors, use the /contributor command.
  • To add additional solved issues, use the /issue command.

Since the source branch of this PR was last updated there have been 58 commits pushed to the master branch:

  • a67f890: 8253050: jfr disassemble command processes --max-chunks incorrectly
  • f972155: 8252196: ZGC: TestUncommit.java fails due to "Exception: Uncommitted too fast" again(2)
  • a9993f9: 8253275: Remove unused methods after CMS removal
  • 4ac6934: 8253232: G1Analytics::compute_pause_time_ratios() uses wrong pause times in calculation
  • 53a4ef2: 8202473: A type variable with multiple bounds does not correctly place type annotation
  • b87a159: 8252100: NumberOverflow in class MemoryCache
  • 9a7dcdc: 8253261: Disable CDS full module graph until JDK-8253081 is fixed
  • 1c84cfa: 8253130: bug7072653.java failed "Popup window height ... is wrong"
  • ce93cbc: 8253125: vmTestbase/nsk/stress/stack/stack017.java timed out
  • d250f9e: 8253244: Shenandoah: cleanup includes in Shenandoah root processor files
  • ... and 48 more: https://git.openjdk.java.net/jdk/compare/952518640a50ce86ca6f295867cfde93f6ac8b26...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid automatic rebasing, please merge master into your branch, and then specify the current head hash when integrating, like this: /integrate a67f890fc63989779e1babee17fd234398a95b22.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Sep 15, 2020
@reinrich
Copy link
Member Author

Thanks Serguei and Chris. I'll integrate this tomorrow.

@reinrich
Copy link
Member Author

/integrate

@openjdk openjdk bot closed this Sep 17, 2020
@openjdk openjdk bot added integrated Pull request has been integrated and removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Sep 17, 2020
@openjdk
Copy link

openjdk bot commented Sep 17, 2020

@reinrich Since your change was applied there have been 58 commits pushed to the master branch:

  • a67f890: 8253050: jfr disassemble command processes --max-chunks incorrectly
  • f972155: 8252196: ZGC: TestUncommit.java fails due to "Exception: Uncommitted too fast" again(2)
  • a9993f9: 8253275: Remove unused methods after CMS removal
  • 4ac6934: 8253232: G1Analytics::compute_pause_time_ratios() uses wrong pause times in calculation
  • 53a4ef2: 8202473: A type variable with multiple bounds does not correctly place type annotation
  • b87a159: 8252100: NumberOverflow in class MemoryCache
  • 9a7dcdc: 8253261: Disable CDS full module graph until JDK-8253081 is fixed
  • 1c84cfa: 8253130: bug7072653.java failed "Popup window height ... is wrong"
  • ce93cbc: 8253125: vmTestbase/nsk/stress/stack/stack017.java timed out
  • d250f9e: 8253244: Shenandoah: cleanup includes in Shenandoah root processor files
  • ... and 48 more: https://git.openjdk.java.net/jdk/compare/952518640a50ce86ca6f295867cfde93f6ac8b26...master

Your commit was automatically rebased without conflicts.

Pushed as commit a4c6a99.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@reinrich reinrich deleted the JDK-8252593 branch September 17, 2020 13:20
robehn pushed a commit to robehn/jdk that referenced this pull request Nov 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integrated Pull request has been integrated serviceability serviceability-dev@openjdk.org
Development

Successfully merging this pull request may close these issues.

4 participants