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

8268963: [IR Framework] Some default regexes matching on PrintOptoAssembly in IRNode.java do not work on all platforms #4931

Closed
wants to merge 1 commit into from

Conversation

chhagedorn
Copy link
Member

@chhagedorn chhagedorn commented Jul 29, 2021

The test TestIRMatching verifies that the various default regexes work as expected. This test however, does not work for some default regexes matching the PrintOptoAssembly output on aarch64, x86, PPC and s390 due to slightly different formats/emitted instructions. This patch includes:

  • Default regex fixes which required some refactoring in IRNode to make them work properly (includes composite regex format/processing, checks on the application of default regexes etc.).
  • TestIRMatching fixes to adapt for the changes of the default regexes for different platforms.
  • TestIRMatching refactoring to better report errors (bulk reporting).
  • Added timeout to TestIRMatching which is hit on PPC.
  • Added checks to skip rules containing certain default regexes that cannot be used when certain conditions are met (e.g. CHECKCAST_ARRAYCOPY cannot be used on s390 as there is no stub for it in C2). This also includes an improved log reporting from the test VM (where these conditions are checked) to allow the user to be informed about skipped IR rules.

These changes were tested on x86, x64, aarch64, PPC and s390 with all framework JTreg tests:

testlibrary_tests/ir_framework/tests testlibrary_tests/ir_framework/examples

Thanks to @TheRealMDoerr for helping with the testing on PPC and s390.

I additionally applied the changes to Valhalla and tested the converted inline type tests with flag settings from tier1-9.

I thought about splitting these changes into separate tasks but all of these changes are somehow related/required to tackle this default regex problem. I therefore included these fixes in a single change.

Thanks,
Christian


Progress

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

Issue

  • JDK-8268963: [IR Framework] Some default regexes matching on PrintOptoAssembly in IRNode.java do not work on all platforms

Reviewers

Reviewing

Using git

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

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

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 4931

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

Using diff file

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

@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented Jul 29, 2021

👋 Welcome back chagedorn! 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 openjdk bot added the rfr label Jul 29, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Jul 29, 2021

@chhagedorn 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 Jul 29, 2021
@chhagedorn chhagedorn changed the title 8268963: Some default regexes matching on PrintOptoAssembly in IRNode.java do not work on all platforms 8268963: [IR Framework] Some default regexes matching on PrintOptoAssembly in IRNode.java do not work on all platforms Jul 29, 2021
@mlbridge
Copy link

@mlbridge mlbridge bot commented Jul 29, 2021

Webrevs

Copy link
Contributor

@vnkozlov vnkozlov left a comment

Good.

@openjdk
Copy link

@openjdk openjdk bot commented Jul 29, 2021

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

8268963: [IR Framework] Some default regexes matching on PrintOptoAssembly in IRNode.java do not work on all platforms

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

  • b59418f: 8270060: (jdeprscan) tools/jdeprscan/tests/jdk/jdeprscan/TestRelease.java failed with class file for jdk.internal.util.random.RandomSupport not found
  • 4f42eb6: 8269523: runtime/Safepoint/TestAbortOnVMOperationTimeout.java failed when expecting 'VM operation took too long'
  • 77fbd99: 8270341: Test serviceability/dcmd/gc/HeapDumpAllTest.java timed-out
  • 048fb2c: Merge
  • 286d313: 8271489: (doc) Clarify Filter Factory example
  • d09b028: 8271396: Spelling errors
  • 489e5fd: 8268019: C2: assert(no_dead_loop) failed: dead loop detected
  • 6afcf5f: 8270886: Crash in PhaseIdealLoop::verify_strip_mined_scheduling
  • a0504cf: Merge
  • 20d2dc1: 8271403: mark hotspot runtime/memory tests which ignore external VM flags
  • ... and 31 more: https://git.openjdk.java.net/jdk/compare/45d277feb04a51faa3858099336fc67dfb222542...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 Jul 29, 2021
Copy link
Member

@TobiHartmann TobiHartmann left a comment

Looks good to me.

@chhagedorn
Copy link
Member Author

@chhagedorn chhagedorn commented Jul 30, 2021

Thanks Vladimir and Tobias for your reviews!

@chhagedorn
Copy link
Member Author

@chhagedorn chhagedorn commented Jul 30, 2021

/integrate

@openjdk
Copy link

@openjdk openjdk bot commented Jul 30, 2021

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

  • b59418f: 8270060: (jdeprscan) tools/jdeprscan/tests/jdk/jdeprscan/TestRelease.java failed with class file for jdk.internal.util.random.RandomSupport not found
  • 4f42eb6: 8269523: runtime/Safepoint/TestAbortOnVMOperationTimeout.java failed when expecting 'VM operation took too long'
  • 77fbd99: 8270341: Test serviceability/dcmd/gc/HeapDumpAllTest.java timed-out
  • 048fb2c: Merge
  • 286d313: 8271489: (doc) Clarify Filter Factory example
  • d09b028: 8271396: Spelling errors
  • 489e5fd: 8268019: C2: assert(no_dead_loop) failed: dead loop detected
  • 6afcf5f: 8270886: Crash in PhaseIdealLoop::verify_strip_mined_scheduling
  • a0504cf: Merge
  • 20d2dc1: 8271403: mark hotspot runtime/memory tests which ignore external VM flags
  • ... and 31 more: https://git.openjdk.java.net/jdk/compare/45d277feb04a51faa3858099336fc67dfb222542...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot closed this Jul 30, 2021
@openjdk openjdk bot added integrated and removed ready rfr labels Jul 30, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Jul 30, 2021

@chhagedorn Pushed as commit 9856ace.

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

@chhagedorn chhagedorn deleted the JDK-8268963 branch Oct 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hotspot-compiler integrated
3 participants