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

8345156: C2: Add bailouts next to a few asserts #22482

Closed
wants to merge 2 commits into from

Conversation

danielogh
Copy link
Contributor

@danielogh danielogh commented Dec 2, 2024

This patch associates product bailouts with a few existing debug asserts. The criteria are that there have been product bugs associated with failing these asserts in the past, and that there are not too many callers to the method where the compilation is now cancelled or any measurable impact on compilation time.

Testing: T1-T4 and extra testing. Tested compilation time with -XX:+CITime on performance benchmarks and the effect was not measurable.


Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issue

  • JDK-8345156: C2: Add bailouts next to a few asserts (Sub-task - P4)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/22482/head:pull/22482
$ git checkout pull/22482

Update a local copy of the PR:
$ git checkout pull/22482
$ git pull https://git.openjdk.org/jdk.git pull/22482/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 22482

View PR using the GUI difftool:
$ git pr show -t 22482

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/22482.diff

Using Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Dec 2, 2024

👋 Welcome back danielogh! 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 2, 2024

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

8345156: C2: Add bailouts next to a few asserts

Reviewed-by: kvn, epeter

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

  • 69e664d: 8345632: [ASAN] memory leak in get_numbered_property_as_sorted_string function
  • 842b363: 8345698: Remove tier1_compiler_not_xcomp from github actions
  • 458979d: 8344611: Add missing classpath exception
  • 83ea013: 8345629: Remove expired flags in JDK 25
  • c517ffb: 8339910: RISC-V: crc32 intrinsic with carry-less multiplication
  • e0d6398: 8344575: Examine usage of ReflectUtil.forName() in java.sql.rowset - XmlReaderContentHandler
  • 470701f: 8340969: jdk/jfr/startupargs/TestStartDuration.java should be marked as flagless
  • 573bcb6: 8345664: Use simple parameter type names in @link and @see tags
  • 4966419: 8334733: Remove obsolete @enablePreview from tests after JDK-8334714
  • 0e2a285: 8344833: CTW: Make failing on zero classes optional
  • ... and 153 more: https://git.openjdk.org/jdk/compare/f5ebda43709984214a25e23926860fea2ba5819a...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.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@vnkozlov, @eme64) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

@openjdk openjdk bot added the rfr Pull request is ready for review label Dec 2, 2024
@openjdk
Copy link

openjdk bot commented Dec 2, 2024

@danielogh The following label will be automatically applied to this pull request:

  • hotspot-compiler

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.

@openjdk openjdk bot added the hotspot-compiler hotspot-compiler-dev@openjdk.org label Dec 2, 2024
@mlbridge
Copy link

mlbridge bot commented Dec 2, 2024

Webrevs

Copy link
Contributor

@vnkozlov vnkozlov left a comment

Choose a reason for hiding this comment

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

How you found places where to add failing() check?
To be useful it should be preceded by a failure recording.

Comment on lines 1358 to +1359
verify_anti_dependences(block, n);
if (C->failing()) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't see where record_failure() is called from verify_anti_dependences().

Comment on lines 1534 to +1535
LCA = insert_anti_dependences(LCA, self);
if (C->failing()) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Same here. I don't see where record_failure() is called from insert_anti_dependences().
And there are a lot of assets there.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is intended to cover insert_anti_dependences : memory_early_block : assert_dom : record_failure("unschedulable graph");

Copy link
Contributor

@vnkozlov vnkozlov left a comment

Choose a reason for hiding this comment

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

Good.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Dec 3, 2024
Copy link
Contributor

@eme64 eme64 left a comment

Choose a reason for hiding this comment

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

Nice work @danielogh ! Looks reasonable :)

@danielogh
Copy link
Contributor Author

Thanks for the reviews!

@danielogh
Copy link
Contributor Author

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Dec 9, 2024
@openjdk
Copy link

openjdk bot commented Dec 9, 2024

@danielogh
Your change (at version 2ab2473) is now ready to be sponsored by a Committer.

@vnkozlov
Copy link
Contributor

vnkozlov commented Dec 9, 2024

/sponsor

@openjdk
Copy link

openjdk bot commented Dec 9, 2024

Going to push as commit 480b508.
Since your change was applied there have been 171 commits pushed to the master branch:

  • b120404: 8345793: Update copyright year to 2024 for the build system in files where it was missed
  • 7aa0cbc: 8345614: Improve AnnotationFormatError message for duplicate annotation interfaces
  • 35c0053: 8345405: Add JMH showing the regression in 8341649
  • 166c127: 8345726: Update mx in RunTestPrebuiltSpec to reflect change in JDK-8345302
  • e821d59: 8345589: Simplify Windows definition of strtok_r
  • 153dc6d: 8345133: Test sun/security/tools/jarsigner/TsacertOptionTest.java failed: Warning found in stdout
  • d7ef3ac: 8345684: OperatingSystemMXBean.getSystemCpuLoad() throws NPE
  • 830173f: 8344068: Windows x86-64: Out of CodeBuffer space when generating final stubs
  • 69e664d: 8345632: [ASAN] memory leak in get_numbered_property_as_sorted_string function
  • 842b363: 8345698: Remove tier1_compiler_not_xcomp from github actions
  • ... and 161 more: https://git.openjdk.org/jdk/compare/f5ebda43709984214a25e23926860fea2ba5819a...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Dec 9, 2024
@openjdk openjdk bot closed this Dec 9, 2024
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review sponsor Pull request is ready to be sponsored labels Dec 9, 2024
@openjdk
Copy link

openjdk bot commented Dec 9, 2024

@vnkozlov @danielogh Pushed as commit 480b508.

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hotspot-compiler hotspot-compiler-dev@openjdk.org integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

3 participants