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

8285793: C2: optimization of mask checks in counted loops fail in the presence of cast nodes #8447

Closed
wants to merge 2 commits into from

Conversation

rwestrel
Copy link
Contributor

@rwestrel rwestrel commented Apr 28, 2022

This showed up when working with a panama micro benchmark. Optimization of:

if ((base + (offset << 2)) & 3) != 0) {
}

into:

if ((base & 3) != 0) {

fails if the subgraph contains cast nodes.


Progress

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

Issue

  • JDK-8285793: C2: optimization of mask checks in counted loops fail in the presence of cast nodes

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/8447/head:pull/8447
$ git checkout pull/8447

Update a local copy of the PR:
$ git checkout pull/8447
$ git pull https://git.openjdk.java.net/jdk pull/8447/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 8447

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

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/8447.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Apr 28, 2022

👋 Welcome back roland! 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 Apr 28, 2022

@rwestrel 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 label Apr 28, 2022
@openjdk openjdk bot added the rfr label Apr 28, 2022
@mlbridge
Copy link

mlbridge bot commented Apr 28, 2022

Webrevs

Copy link
Contributor

@vnkozlov vnkozlov left a comment

Looks good. Let me test it.

Copy link
Contributor

@vnkozlov vnkozlov left a comment

Tobias already submitted testing.

@openjdk
Copy link

openjdk bot commented Apr 28, 2022

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

8285793: C2: optimization  of mask checks in counted loops fail in the presence of cast nodes

Reviewed-by: kvn, thartmann

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

  • 669ac61: 8274597: Some of the dnd tests time out and fail intermittently
  • 269eae6: 8285515: (dc) DatagramChannel.disconnect fails with "Invalid argument" on macOS 12.4 beta2
  • c4f7a85: 8285828: runtime/execstack/TestCheckJDK.java fails with zipped debug symbols
  • d3606a3: 8285390: PPC64: Handle integral division overflow during parsing
  • f42631e: 8285523: Improve test java/io/FileOutputStream/OpenNUL.java
  • b71e8c1: 8285711: riscv: RVC: Support disassembler show-bytes option
  • e406662: 8282711: Accelerate Math.signum function for AVX and AVX512 target.
  • 0a4a640: 8285301: C2: assert(!requires_atomic_access) failed: can't ensure atomicity
  • 40f19c0: 8264666: Change implementation of safeAdd/safeMult in the LCMSImageLayout class
  • 1e28fcb: 8155701: The compiler fails with an AssertionError: typeSig ERROR
  • ... and 75 more: https://git.openjdk.java.net/jdk/compare/dc6358444b34a4861758a6b41aeebbe737345106...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 label Apr 28, 2022
Copy link
Member

@TobiHartmann TobiHartmann left a comment

Looks good. All tests passed.

@rwestrel
Copy link
Contributor Author

rwestrel commented Apr 29, 2022

@TobiHartmann @vnkozlov thanks for the reviews and testing

@rwestrel
Copy link
Contributor Author

rwestrel commented Apr 29, 2022

/integrate

@openjdk
Copy link

openjdk bot commented Apr 29, 2022

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

  • 669ac61: 8274597: Some of the dnd tests time out and fail intermittently
  • 269eae6: 8285515: (dc) DatagramChannel.disconnect fails with "Invalid argument" on macOS 12.4 beta2
  • c4f7a85: 8285828: runtime/execstack/TestCheckJDK.java fails with zipped debug symbols
  • d3606a3: 8285390: PPC64: Handle integral division overflow during parsing
  • f42631e: 8285523: Improve test java/io/FileOutputStream/OpenNUL.java
  • b71e8c1: 8285711: riscv: RVC: Support disassembler show-bytes option
  • e406662: 8282711: Accelerate Math.signum function for AVX and AVX512 target.
  • 0a4a640: 8285301: C2: assert(!requires_atomic_access) failed: can't ensure atomicity
  • 40f19c0: 8264666: Change implementation of safeAdd/safeMult in the LCMSImageLayout class
  • 1e28fcb: 8155701: The compiler fails with an AssertionError: typeSig ERROR
  • ... and 75 more: https://git.openjdk.java.net/jdk/compare/dc6358444b34a4861758a6b41aeebbe737345106...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated label Apr 29, 2022
@openjdk openjdk bot closed this Apr 29, 2022
@openjdk openjdk bot removed ready rfr labels Apr 29, 2022
@openjdk
Copy link

openjdk bot commented Apr 29, 2022

@rwestrel Pushed as commit e98ac23.

💡 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 integrated
3 participants