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

8303948: HsErrFileUtils.checkHsErrFileContent() fails to check the last pattern. #12970

Closed
wants to merge 3 commits into from

Conversation

varada1110
Copy link
Contributor

@varada1110 varada1110 commented Mar 10, 2023

When last pattern in deque [positivePatternStack] is not matching in HsErrFile, it comes out of the loop and check whether the positivePatternStack is empty or not, which turns to be empty because the pollFirst() removes the pattern.

This has been noticed in the TestSigInfoInHsErrFile.java where the segfault address for AIX is set as "0x0*1400" instead of "0xffffffffffffffff", which should throw the expected error but the error is neglected due to empty deque and the test is passed.

JBS issue : 8303948


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-8303948: HsErrFileUtils.checkHsErrFileContent() fails to check the last pattern.

Reviewers

Reviewing

Using git

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

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

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 12970

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

Using diff file

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

@bridgekeeper
Copy link

bridgekeeper bot commented Mar 10, 2023

👋 Welcome back varada1110! 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 Pull request is ready for review label Mar 10, 2023
@openjdk
Copy link

openjdk bot commented Mar 10, 2023

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

  • hotspot-runtime

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-runtime hotspot-runtime-dev@openjdk.org label Mar 10, 2023
@mlbridge
Copy link

mlbridge bot commented Mar 10, 2023

Webrevs

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.

This fix seems correct - thanks.

@openjdk
Copy link

openjdk bot commented Mar 13, 2023

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

8303948: HsErrFileUtils.checkHsErrFileContent() fails to check the last pattern.

Reviewed-by: dholmes, stuefe

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

  • bbca7c3: 8304542: Convert use of internal VM::classFileVersion to ClassFileFormatVersion
  • f593a6b: 8303018: Unicode Emoji Properties
  • bc0ed73: 8304303: implement VirtualThread class notifyJvmti methods as C2 intrinsics
  • 2d0d057: 8304016: Add BitMap find_last suite of functions
  • 42723dc: 8304420: Regression ~11% with Javac-Generates on all platforms in b14
  • 19f2edd: 8304541: Modules THROW_MSG_ should return nullptr instead of JNI_FALSE
  • 622f239: 8304163: Move jdk.internal.module.ModuleInfoWriter to the test library
  • 4c8c993: 8304364: [AIX] Build erroneously determines build disk is non-local when using GNU-utils df on AIX
  • 4ed7350: 8304393: Provide method to iterate over regions of humongous object in G1
  • eb73fa8: 8301715: CDS should be disabled in exploded JDK
  • ... and 144 more: https://git.openjdk.org/jdk/compare/8cfd74f76afc9e5d50c52104fef9974784718dd4...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 (@dholmes-ora, @tstuefe) 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 ready Pull request is ready to be integrated label Mar 13, 2023
@varada1110
Copy link
Contributor Author

This fix seems correct - thanks.

Thanks @dholmes-ora for reviewing the changes.

@varada1110
Copy link
Contributor Author

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Mar 13, 2023
@openjdk
Copy link

openjdk bot commented Mar 13, 2023

@varada1110
Your change (at version a456548) is now ready to be sponsored by a Committer.

@dholmes-ora
Copy link
Member

Hotspot changes, including tests, require two reviewers. I'll try to get someone else to review and sponsor once done.

Copy link
Member

@tstuefe tstuefe left a comment

Choose a reason for hiding this comment

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

@varada1110 Ouch, thank you for finding that. Let's see how many tests now start failing :-/

Could a slightly more elegant patch not be to change the condition after the loop not from

< if (!positivePatternStack.isEmpty()) {
> if (currentPositivePattern != null) {

?

But I leave that up to you. Patch is also fine in its current form.

@varada1110
Copy link
Contributor Author

@varada1110 Ouch, thank you for finding that. Let's see how many tests now start failing :-/

Could a slightly more elegant patch not be to change the condition after the loop not from

< if (!positivePatternStack.isEmpty()) {
> if (currentPositivePattern != null) {

?

But I leave that up to you. Patch is also fine in its current form.

Thank you @tstuefe for the suggestion. I have made the changes please review it

@openjdk openjdk bot removed the sponsor Pull request is ready to be sponsored label Mar 17, 2023
Copy link
Member

@tstuefe tstuefe left a comment

Choose a reason for hiding this comment

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

Still good.

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.

So checking for null-ness covers the case of the last pattern not matching, regardless of whether there are any other patterns still to be checked. Yep that logic seems fine.

A nit with the explanatory comment though.

@tstuefe
Copy link
Member

tstuefe commented Mar 20, 2023

Still good to go

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.

Looks good. Thanks. I will sponsor now.

@dholmes-ora
Copy link
Member

/sponsor

@openjdk
Copy link

openjdk bot commented Mar 21, 2023

@dholmes-ora The PR has been updated since the change author (@varada1110) issued the integrate command - the author must perform this command again.

@varada1110
Copy link
Contributor Author

@dholmes-ora The PR has been updated since the change author (@varada1110) issued the integrate command - the author must perform this command again.

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Mar 21, 2023
@openjdk
Copy link

openjdk bot commented Mar 21, 2023

@varada1110
Your change (at version 22c1843) is now ready to be sponsored by a Committer.

@dholmes-ora
Copy link
Member

/sponsor

@openjdk
Copy link

openjdk bot commented Mar 21, 2023

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

  • bbca7c3: 8304542: Convert use of internal VM::classFileVersion to ClassFileFormatVersion
  • f593a6b: 8303018: Unicode Emoji Properties
  • bc0ed73: 8304303: implement VirtualThread class notifyJvmti methods as C2 intrinsics
  • 2d0d057: 8304016: Add BitMap find_last suite of functions
  • 42723dc: 8304420: Regression ~11% with Javac-Generates on all platforms in b14
  • 19f2edd: 8304541: Modules THROW_MSG_ should return nullptr instead of JNI_FALSE
  • 622f239: 8304163: Move jdk.internal.module.ModuleInfoWriter to the test library
  • 4c8c993: 8304364: [AIX] Build erroneously determines build disk is non-local when using GNU-utils df on AIX
  • 4ed7350: 8304393: Provide method to iterate over regions of humongous object in G1
  • eb73fa8: 8301715: CDS should be disabled in exploded JDK
  • ... and 144 more: https://git.openjdk.org/jdk/compare/8cfd74f76afc9e5d50c52104fef9974784718dd4...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Mar 21, 2023
@openjdk openjdk bot closed this Mar 21, 2023
@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 Mar 21, 2023
@openjdk
Copy link

openjdk bot commented Mar 21, 2023

@dholmes-ora @varada1110 Pushed as commit a72ba38.

💡 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-runtime hotspot-runtime-dev@openjdk.org integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

3 participants