Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
8261661: gc/stress/TestReclaimStringsLeaksMemory.java fails because R…
…eserved memory size is too big

Reviewed-by: shade
Backport-of: 735757f
  • Loading branch information
tstuefe committed Nov 29, 2021
1 parent 242bbef commit 48dbaf1
Showing 1 changed file with 4 additions and 4 deletions.
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2018, 2021, 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 Down Expand Up @@ -48,9 +48,9 @@

public class TestReclaimStringsLeaksMemory {

// The amount of memory in kB reserved in the "Symbol" category that indicates a memory leak for
// The amount of memory in B reserved in the "Symbol" category that indicates a memory leak for
// this test.
public static final int ReservedThreshold = 70000;
public static final int ReservedThreshold = 70000000;

public static void main(String[] args) throws Exception {
ArrayList<String> baseargs = new ArrayList(Arrays.asList( "-Xms256M",
Expand Down Expand Up @@ -78,7 +78,7 @@ private static void verifySymbolMemoryUsageNotTooHigh(OutputAnalyzer output) thr
}

int reserved = Integer.parseInt(m.group(1));
Asserts.assertLT(reserved, ReservedThreshold, "Reserved memory size is " + reserved + "KB which is greater than or equal to " + ReservedThreshold + "KB indicating a memory leak");
Asserts.assertLT(reserved, ReservedThreshold, "Reserved memory size is " + reserved + "B which is greater than or equal to " + ReservedThreshold + "B indicating a memory leak");

output.shouldHaveExitValue(0);
}
Expand Down

1 comment on commit 48dbaf1

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