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

8254999: Move G1RemSetSamplingTask to more appropriate location #1395

Closed
wants to merge 5 commits into from

Conversation

kstefanj
Copy link
Contributor

@kstefanj kstefanj commented Nov 23, 2020

Please review this change that moves the Remembered Set Sampling Task from g1ServiceThread.cpp into g1RemSet.cpp. This is basically just a move but with a small edition that the task will reschedule itself instead of running if at start of execution the last GC happend more recently than the value of G1ConcRefinementServiceIntervalMillis.

This change does not cover moving the timing measurements from the service thread into the task, that will be covered by:
JDK-8252645

Testing
Tier1-3 + local verification that the tast is scheduled as expected.


Progress

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

Testing

Linux aarch64 Linux arm Linux ppc64le Linux s390x Linux x64 Linux x86 Windows x64 macOS x64
Build ✔️ (1/1 passed) ✔️ (1/1 passed) ✔️ (1/1 passed) ✔️ (1/1 passed) ✔️ (6/6 passed) (2/2 failed) ✔️ (2/2 passed) ✔️ (2/2 passed)
Test (tier1) ✔️ (9/9 passed) ✔️ (9/9 passed) (1/9 failed)

Failed test tasks

Issue

  • JDK-8254999: Move G1RemSetSamplingTask to more appropriate location

Reviewers

Download

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

@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented Nov 23, 2020

👋 Welcome back sjohanss! 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 Nov 23, 2020
@openjdk
Copy link

@openjdk openjdk bot commented Nov 23, 2020

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

  • hotspot-gc

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-gc label Nov 23, 2020
@mlbridge
Copy link

@mlbridge mlbridge bot commented Nov 23, 2020

Webrevs

@kstefanj kstefanj changed the title 8254999: Move G1RemSetSampligTask to more appropriate location 8254999: Move G1RemSetSamplingTask to more appropriate location Nov 23, 2020
if (should_reschedule()) {
// Calculate the delay given the last GC and the interval.
schedule(reschedule_delay_ms());
return;
}

// Do the actual sampling.
sample_young_list_rs_length(&sts);
schedule(G1ConcRefinementServiceIntervalMillis);
Copy link
Contributor

@tschatzl tschatzl Nov 24, 2020

Choose a reason for hiding this comment

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

I am good with the new location of the code but I would prefer if this change would be limited to the move and not change the rescheduling logic.
If it's not too much of a bother please split this out into a second CR.

Copy link
Contributor Author

@kstefanj kstefanj Nov 24, 2020

Choose a reason for hiding this comment

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

Thanks for looking at this Thomas. I removed the scheduling logic and filed: JDK-8252645

@openjdk
Copy link

@openjdk openjdk bot commented Nov 24, 2020

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

8254999: Move G1RemSetSamplingTask to more appropriate location

Reviewed-by: tschatzl, ayang

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

  • ff6df15: 8256801: tools/jpackage/share/FileAssociationsTest.java#id0 failed unpack.bat with "Exit code: 1603"
  • 303631e: 8256475: Fix Behavior when Installer name differs from application name.
  • fa3cfcd: 8256883: C2: Add a RegMask iterator
  • f55ae95: 8256858: C2: Devirtualize PhaseIterGVN-specific methods

Please see this link for an up-to-date comparison between the source branch of this pull request and the master branch.
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 Nov 24, 2020
}

G1RemSet::~G1RemSet() {
delete _scan_state;
if (_sampling_task != NULL) {
Copy link
Member

@albertnetymk albertnetymk Nov 24, 2020

Choose a reason for hiding this comment

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

Could you add a comment to explain when _sampling_task would be null?

Copy link
Contributor

@tschatzl tschatzl Nov 24, 2020

Choose a reason for hiding this comment

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

Actually the check can be removed because the operator implementation handles NULL (by ignoring it).

Copy link
Member

@albertnetymk albertnetymk Nov 24, 2020

Choose a reason for hiding this comment

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

Even better. Thanks for the suggestion.

Copy link
Contributor Author

@kstefanj kstefanj Nov 24, 2020

Choose a reason for hiding this comment

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

Cool, then I will just remove the NULL-check.

Copy link
Contributor

@tschatzl tschatzl left a comment

Still lgtm

@kstefanj
Copy link
Contributor Author

@kstefanj kstefanj commented Nov 24, 2020

Thanks @albertnetymk and @tschatzl for the reviews.
/integrate

@openjdk openjdk bot closed this Nov 24, 2020
@openjdk openjdk bot added integrated and removed ready rfr labels Nov 24, 2020
@openjdk
Copy link

@openjdk openjdk bot commented Nov 24, 2020

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

  • 695117f: 8255479: [aarch64] assert(src->section_index_of(target) == CodeBuffer::SECT_NONE) failed: sanity
  • dbfeb90: 8243559: Remove root certificates with 1024-bit keys
  • 2a1e9be: 8256364: vmTestbase/nsk/jvmti/scenarios/capability/CM01/cm01t002 failed with "assert(handle != __null) failed: JNI handle should not be null"
  • f1d6e8d: 8256387: Unexpected result if patching an entire instruction on AArch64
  • bd14274: 8256480: Refactor ObjectInputStream field reader implementation
  • 1c4c99e: 8256823: C2 compilation fails with "assert(isShiftCount(imm8 >> 1)) failed: illegal shift count"
  • 3b3e90e: 8256924: ppc, ppcle, s390: JVM crashes at VM init after JDK-8254231
  • ff6df15: 8256801: tools/jpackage/share/FileAssociationsTest.java#id0 failed unpack.bat with "Exit code: 1603"
  • 303631e: 8256475: Fix Behavior when Installer name differs from application name.
  • fa3cfcd: 8256883: C2: Add a RegMask iterator
  • ... and 1 more: https://git.openjdk.java.net/jdk/compare/7b3d0958c068c8f45c98ea0615ef8cd908fd408d...master

Your commit was automatically rebased without conflicts.

Pushed as commit 1b7a61f.

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

@kstefanj kstefanj deleted the 8254999-move-sampling-task branch Nov 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hotspot-gc integrated
3 participants