Skip to content

8257460: Further CompilerOracle cleanup #1528

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 3 commits into from

Conversation

neliasso
Copy link

@neliasso neliasso commented Nov 30, 2020

I got some additional feedback on 8256508: "Improve CompileCommand flag" from Claes.

  1. The _type field in TypedMethodMatcher is not used any more. It is derived from the option.

  2. The verify_type argument is only used from whitebox API and the check should be pushed out to that code. The check is needed because the option is passed from java as a String and we need to verify that the value type matches the option type.

  3. The type parameter to TypedMethodMatcher::match isn't used.

  4. Some code only used for asserts was moved into assert


Progress

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

Issue

Reviewers

Download

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

@neliasso
Copy link
Author

/label hotspot-compiler
/label remove hotspot

@bridgekeeper
Copy link

bridgekeeper bot commented Nov 30, 2020

👋 Welcome back neliasso! 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 hotspot-compiler hotspot-compiler-dev@openjdk.org label Nov 30, 2020
@openjdk
Copy link

openjdk bot commented Nov 30, 2020

@neliasso
The hotspot-compiler label was successfully added.

@openjdk
Copy link

openjdk bot commented Nov 30, 2020

@neliasso The hotspot label was not set.

@neliasso neliasso marked this pull request as ready for review November 30, 2020 22:41
@openjdk openjdk bot added the rfr Pull request is ready for review label Nov 30, 2020
@mlbridge
Copy link

mlbridge bot commented Nov 30, 2020

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.

Good clean up.

@openjdk
Copy link

openjdk bot commented Nov 30, 2020

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

8257460: Further CompilerOracle cleanup

Reviewed-by: kvn, redestad, 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 25 new commits pushed to the master branch:

  • c5046ca: 8246739: InputStream.skipNBytes could be implemented more efficiently
  • 56b15fb: 8159746: (proxy) Support for default methods
  • 1433baf: 8253751: Dependencies of automatic modules are not propagated through module layers
  • e3d0f27: 8257231: assert(!is_mcall || (call_returns[block->_pre_order] <= (uint) current_offset))
  • eaf4db6: 8257502: Builds fail with new warnings after JDK-8256254
  • 2966d0d: 8257223: C2: Optimize RegMask::is_bound
  • 3a11009: 8256830: misc tests failed with "assert(env->is_enabled(JVMTI_EVENT_OBJECT_FREE)) failed: checking"
  • c859fb0: 8249836: java/io/IOException/LastErrorString.java should have bug-id as 1st word in @ignore
  • e0de28c: 8257424: RecordingStream does not specify the recording name
  • 60f2ba9: 8257487: Include configuration name in summary
  • ... and 15 more: https://git.openjdk.java.net/jdk/compare/41dbc139ab8485f940e65ce559c11f44251f8806...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 Nov 30, 2020
Copy link
Member

@cl4es cl4es left a comment

Choose a reason for hiding this comment

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

Thanks for doing this cleanup!

@@ -308,26 +304,15 @@ static void register_command(TypedMethodOptionMatcher* matcher,
}

template<typename T>
bool CompilerOracle::has_option_value(const methodHandle& method, enum CompileCommand option, T& value, bool verify_type) {
bool CompilerOracle::has_option_value(const methodHandle& method, enum CompileCommand option, T& value) {
enum OptionType type = option2type(option);
if (type == OptionType::Unknown) {
Copy link
Member

Choose a reason for hiding this comment

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

Could this be an assertion done inside option_matches_type?

Copy link
Author

Choose a reason for hiding this comment

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

I move it out to option_matches_type so that it won't affect the hot path. I did have to add an extra check to the compiler_directives_init that uses has_option_value and sent OptionType::Unknown for options that don't have a command. But better have it there than in the common path.

Copy link
Member

Choose a reason for hiding this comment

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

Good!

Copy link
Member

@TobiHartmann TobiHartmann left a comment

Choose a reason for hiding this comment

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

Looks good.

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.

Okay.

@neliasso
Copy link
Author

neliasso commented Dec 1, 2020

/integrate

@openjdk openjdk bot closed this Dec 1, 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 Dec 1, 2020
@openjdk
Copy link

openjdk bot commented Dec 1, 2020

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

  • 29d90b9: 8255968: Confusing error message for inaccessible constructor
  • c5046ca: 8246739: InputStream.skipNBytes could be implemented more efficiently
  • 56b15fb: 8159746: (proxy) Support for default methods
  • 1433baf: 8253751: Dependencies of automatic modules are not propagated through module layers
  • e3d0f27: 8257231: assert(!is_mcall || (call_returns[block->_pre_order] <= (uint) current_offset))
  • eaf4db6: 8257502: Builds fail with new warnings after JDK-8256254
  • 2966d0d: 8257223: C2: Optimize RegMask::is_bound
  • 3a11009: 8256830: misc tests failed with "assert(env->is_enabled(JVMTI_EVENT_OBJECT_FREE)) failed: checking"
  • c859fb0: 8249836: java/io/IOException/LastErrorString.java should have bug-id as 1st word in @ignore
  • e0de28c: 8257424: RecordingStream does not specify the recording name
  • ... and 16 more: https://git.openjdk.java.net/jdk/compare/41dbc139ab8485f940e65ce559c11f44251f8806...master

Your commit was automatically rebased without conflicts.

Pushed as commit 015e6e5.

💡 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.

4 participants