Skip to content

Commit

Permalink
8317347: Parallel: Make TestInitialTenuringThreshold use createTestJvm
Browse files Browse the repository at this point in the history
Backport-of: 6ee6171e8124ae8ce4f60c2582c2fe2cae6fc3db
  • Loading branch information
GoeLin committed Dec 21, 2023
1 parent 4846aa2 commit 5f7b7c5
Showing 1 changed file with 5 additions and 4 deletions.
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2022, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2023, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand All @@ -26,7 +26,7 @@
/*
* @test TestInitialTenuringThreshold
* @bug 8014765
* @requires vm.gc.Parallel
* @requires vm.gc.Parallel & vm.opt.InitialTenuringThreshold == null & vm.opt.MaxTenuringThreshold == null
* @summary Tests argument processing for initial tenuring threshold
* @library /test/lib
* @library /
Expand All @@ -41,7 +41,7 @@
public class TestInitialTenuringThreshold {

public static void runWithThresholds(int initial, int max, boolean shouldfail) throws Exception {
ProcessBuilder pb = GCArguments.createJavaProcessBuilder(
ProcessBuilder pb = GCArguments.createTestJvm(
"-XX:+UseParallelGC",
"-XX:InitialTenuringThreshold=" + String.valueOf(initial),
"-XX:MaxTenuringThreshold=" + String.valueOf(max),
Expand All @@ -58,8 +58,9 @@ public static void runWithThresholds(int initial, int max, boolean shouldfail) t


public static void main(String args[]) throws Exception {
ProcessBuilder pb = GCArguments.createJavaProcessBuilder(
ProcessBuilder pb = GCArguments.createTestJvm(
// some value below the default value of InitialTenuringThreshold of 7
"-XX:+UseParallelGC",
"-XX:MaxTenuringThreshold=1",
"-version"
);
Expand Down

1 comment on commit 5f7b7c5

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

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

Please sign in to comment.