Skip to content
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

8258652: Assert in JvmtiThreadState::cur_stack_depth() can noticeably slow down debugging single stepping #1835

Closed
wants to merge 3 commits into from

Conversation

plummercj
Copy link
Contributor

@plummercj plummercj commented Dec 18, 2020

There is an assert in JvmtiThreadState::cur_stack_depth() that tends to slow down single stepping a lot when running the debuggee with a debug jvm. See CR for details. The fix is to allow disabling of this assert using the new EnableJVMTIStackDepthAsserts global, which defaults to true.


Progress

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

Issue

  • JDK-8258652: Assert in JvmtiThreadState::cur_stack_depth() can noticeably slow down debugging single stepping

Reviewers

Download

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

@bridgekeeper
Copy link

bridgekeeper bot commented Dec 18, 2020

👋 Welcome back cjplummer! 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 Dec 18, 2020

@plummercj The following labels will be automatically applied to this pull request:

  • hotspot
  • serviceability

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing lists. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added serviceability serviceability-dev@openjdk.org hotspot hotspot-dev@openjdk.org labels Dec 18, 2020
@dholmes-ora
Copy link
Member

This works but I'm concerned if this sets a precedent for adding expensive assertions? Do we already have similar flags?

@plummercj
Copy link
Contributor Author

plummercj commented Jan 7, 2021

This works but I'm concerned if this sets a precedent for adding expensive assertions? Do we already have similar flags?

@dholmes-ora The one expensive assert is already there. I have since removed the two additional expensive asserts for the incr() and decr() APIs. I don't know of any other similar flag.

@plummercj plummercj marked this pull request as ready for review January 8, 2021 21:47
@openjdk openjdk bot added the rfr Pull request is ready for review label Jan 8, 2021
@mlbridge
Copy link

mlbridge bot commented Jan 8, 2021

Webrevs

@plummercj
Copy link
Contributor Author

Ping! Still need 2 reviews for this one too.

Copy link
Contributor

@sspitsyn sspitsyn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Thanks,
Serguei

@openjdk
Copy link

openjdk bot commented Jan 13, 2021

@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:

8258652: Assert in JvmtiThreadState::cur_stack_depth() can noticeably slow down debugging single stepping

Reviewed-by: sspitsyn, dholmes, amenkov

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 299 new commits pushed to the master branch:

  • a6b2162: 8259278: Optimize Vector API slice and unslice operations
  • da6bcf9: 8255019: Shenandoah: Split STW and concurrent mark into separate classes
  • aba3431: 8258956: Memory Leak in StringCoding on ThreadLocal resultCached StringCoding.Result
  • 8554fe6: 8253866: Security Libs Terminology Refresh
  • c2a3c7e: 8259727: Remove redundant "target" arguments to methods in Links
  • 1620664: 8259723: Move Table class to formats.html package
  • 38a1201: 8258912: Remove JVM options CountJNICalls and CountJVMCalls
  • be57cf1: 8226416: MonitorUsedDeflationThreshold can cause repeated async deflation requests
  • c822eda: 8259699: Reduce char[] copying in URLEncoder.encode(String, Charset)
  • ff3e6e4: 8259773: Incorrect encoding of AVX-512 kmovq instruction
  • ... and 289 more: https://git.openjdk.java.net/jdk/compare/6e824b3f51591c48b47fcad71f25c1d9dbc3740a...master

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 master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Jan 13, 2021
Copy link
Member

@dholmes-ora dholmes-ora left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Thanks,
David

@plummercj
Copy link
Contributor Author

/integrate

@openjdk openjdk bot closed this Jan 14, 2021
@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 Jan 14, 2021
@openjdk
Copy link

openjdk bot commented Jan 14, 2021

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

  • d18d26e: 8259350: Add some internal debugging APIs to the debug agent
  • a6b2162: 8259278: Optimize Vector API slice and unslice operations
  • da6bcf9: 8255019: Shenandoah: Split STW and concurrent mark into separate classes
  • aba3431: 8258956: Memory Leak in StringCoding on ThreadLocal resultCached StringCoding.Result
  • 8554fe6: 8253866: Security Libs Terminology Refresh
  • c2a3c7e: 8259727: Remove redundant "target" arguments to methods in Links
  • 1620664: 8259723: Move Table class to formats.html package
  • 38a1201: 8258912: Remove JVM options CountJNICalls and CountJVMCalls
  • be57cf1: 8226416: MonitorUsedDeflationThreshold can cause repeated async deflation requests
  • c822eda: 8259699: Reduce char[] copying in URLEncoder.encode(String, Charset)
  • ... and 290 more: https://git.openjdk.java.net/jdk/compare/6e824b3f51591c48b47fcad71f25c1d9dbc3740a...master

Your commit was automatically rebased without conflicts.

Pushed as commit 4f881ba.

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

@plummercj plummercj deleted the JDK-8258652 branch March 12, 2021 23:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hotspot hotspot-dev@openjdk.org integrated Pull request has been integrated serviceability serviceability-dev@openjdk.org
4 participants