< prev index next >

test/hotspot/jtreg/runtime/cds/appcds/FreeUnusedMetadata.java

Print this page
*** 1,7 ***
  /*
!  * Copyright (c) 2017, 2019, 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
   * under the terms of the GNU General Public License version 2 only, as
   * published by the Free Software Foundation.
--- 1,7 ---
  /*
!  * Copyright (c) 2017, 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
   * under the terms of the GNU General Public License version 2 only, as
   * published by the Free Software Foundation.

*** 80,11 ***
      public static void main(String[] args) throws Exception {
          String[] ARCHIVE_CLASSES = {"Hello", "MethodNoReturn"};
          String appJar = JarBuilder.build("FreeUnusedMetadata", ARCHIVE_CLASSES);
  
          OutputAnalyzer dumpOutput = TestCommon.dump(
!                 appJar, ARCHIVE_CLASSES);
          TestCommon.checkDump(dumpOutput, "Loading classes to share");
  
          OutputAnalyzer execOutput = TestCommon.exec(appJar, "Hello");
          TestCommon.checkExec(execOutput, "Hello World");
  
--- 80,11 ---
      public static void main(String[] args) throws Exception {
          String[] ARCHIVE_CLASSES = {"Hello", "MethodNoReturn"};
          String appJar = JarBuilder.build("FreeUnusedMetadata", ARCHIVE_CLASSES);
  
          OutputAnalyzer dumpOutput = TestCommon.dump(
!                 appJar, ARCHIVE_CLASSES, "-XX:-PreloadSharedClasses");
          TestCommon.checkDump(dumpOutput, "Loading classes to share");
  
          OutputAnalyzer execOutput = TestCommon.exec(appJar, "Hello");
          TestCommon.checkExec(execOutput, "Hello World");
  
< prev index next >