test/hotspot/jtreg/runtime/NMT/NMTPrintMallocSiteOfCorruptedMemory.java failing on Windows

XMLWordPrintable

    • x86_64
    • windows

      I'm seeing the `test/hotspot/jtreg/runtime/NMT/NMTPrintMallocSiteOfCorruptedMemory.java` test failing when run on windows (testing with windows server 2022). I'm attaching the .jtr file and have included a snippet of the output for reference.

      ```
      STDOUT:
      Command line: [c:\Users\Administrator\temp\jdk\build\windows-x86_64-server-release\images\jdk\bin\java.exe -cp C:\Users\Administrator\temp\jdk\build\windows-x86_64-server-release\test-support\jtreg_test_hotspot_jtreg_runtime_NMT_NMTPrintMallocSiteOfCorruptedMemory_java\classes\0\runtime\NMT\NMTPrintMallocSiteOfCorruptedMemory.d;C:\Users\Administrator\temp\jdk\test\hotspot\jtreg\runtime\NMT;C:\Users\Administrator\temp\jdk\build\windows-x86_64-server-release\test-support\jtreg_test_hotspot_jtreg_runtime_NMT_NMTPrintMallocSiteOfCorruptedMemory_java\classes\0\runtime\NMT\NMTPrintMallocSiteOfCorruptedMemory.d\test\lib;C:\Users\Administrator\temp\jdk\test\lib;C:\Users\Administrator\temp\jtreg\lib\javatest.jar;C:\Users\Administrator\temp\jtreg\lib\jtreg.jar -XX:MaxRAMPercentage=3.125 -Dtest.boot.jdk=c:\Users\Administrator\temp\boot-jdk\jdk26.0.0_34 -Djava.io.tmpdir=c:\Users\Administrator\temp\jdk\build\windows-x86_64-server-release\test-support\jtreg_test_hotspot_jtreg_runtime_NMT_NMTPrintMallocSiteOfCorruptedMemory_java\tmp -XX:+CreateCoredumpOnCrash -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -XX:-CreateCoredumpOnCrash -XX:NativeMemoryTracking=detail -Djava.library.path=c:\Users\Administrator\temp\jdk\build\windows-x86_64-server-release\images\test\hotspot\jtreg\native NMTPrintMallocSiteOfCorruptedMemory header ]
      [2026-02-16T19:54:53.617006500Z] Gathering output for process 2300
      [2026-02-16T19:54:53.749007300Z] Waiting for completion for process 2300
      [2026-02-16T19:54:53.751995700Z] Waiting for completion finished for process 2300
      STDERR:
      WARNING: A restricted method in java.lang.System has been called
      WARNING: java.lang.System::loadLibrary has been called by NMTPrintMallocSiteOfCorruptedMemory in an unnamed module (file:/C:/Users/Administrator/temp/jdk/build/windows-x86_64-server-release/test-support/jtreg_test_hotspot_jtreg_runtime_NMT_NMTPrintMallocSiteOfCorruptedMemory_java/classes/0/runtime/NMT/NMTPrintMallocSiteOfCorruptedMemory.d/)
      WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
      WARNING: Restricted methods will be blocked in a future release unless native access is enabled

       stdout: [NMT Block at 0x0000021ec092fea0, corruption at: 0x0000021ec092fea0:
      allocated from:
      [0x00007ffa2e14a15c] in jvm.dll+0xa7a15c
      [0x0000021eb290d5f3]

      0x0000021ec092fe20: 00 00 00 00 00 00 00 00 c0 1b 27 2c 00 00 00 00 ..........',....
      0x0000021ec092fe30: e8 8e 00 00 00 00 00 00 45 3f 80 27 00 32 00 8e ........E?.'.2..
      0x0000021ec092fe40: 10 00 00 00 00 00 00 00 00 00 a4 04 01 00 9e e9 ................
      0x0000021ec092fe50: 00 00 00 00 00 00 00 00 10 bc 1d 2c 00 00 00 00 ...........,....
      0x0000021ec092fe60: e8 8e 00 00 00 00 00 00 40 3f 87 27 00 33 00 8e ........@?.'.3..
      0x0000021ec092fe70: 10 00 00 00 00 00 00 00 00 00 a4 04 01 00 9e e9 ................
      0x0000021ec092fe80: 70 c5 1f c0 1e 02 00 00 f8 46 2b 2c 00 00 00 00 p........F+,....
      0x0000021ec092fe90: e8 8e 00 00 00 00 00 00 4f 3f ba 27 00 34 00 94 ........O?.'.4..
      0x0000021ec092fea0: 0a 00 00 00 00 00 00 00 00 00 2d 00 00 00 00 00 ..........-.....
      0x0000021ec092feb0: 00 00 00 00 00 00 00 00 00 00 e8 8e 00 00 00 00 ................
      0x0000021ec092fec0: 00 00 00 00 00 00 00 00 4a 3f b9 27 00 35 00 80 ........J?.'.5..
      0x0000021ec092fed0: 60 54 5c 55 fa 7f 00 00 10 53 5c 55 fa 7f 00 00 `T\U.....S\U....
      0x0000021ec092fee0: 00 00 00 00 ab aa bb 00 31 48 90 91 ca 49 66 47 ........1H...IfG
      0x0000021ec092fef0: b9 5c 25 39 7e 2d d6 dc 49 3f bc 27 00 36 00 80 .\%9~-..I?.'.6..
      0x0000021ec092ff00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
      0x0000021ec092ff10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
      #
      # A fatal error has been detected by the Java Runtime Environment:
      #
      # Internal Error (nmt/mallocHeader.inline.hpp:107), pid=2300, tid=10396
      # fatal error: NMT has detected a memory corruption bug. Block at 0x0000021ec092feb0: header canary broken
      #
      # JRE version: OpenJDK Runtime Environment (26.0) (build 26-internal-adhoc.Administrator.jdk)
      # Java VM: OpenJDK 64-Bit Server VM (26-internal-adhoc.Administrator.jdk, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, windows-amd64)
      # Problematic frame:
      # V [jvm.dll+0x752a45]
      #
      # CreateCoredumpOnCrash turned off, no core file dumped
      #
      Unsupported internal testing APIs have been used.

      # An error report file with more information is saved as:
      # C:\Users\Administrator\temp\jdk\build\windows-x86_64-server-release\test-support\jtreg_test_hotspot_jtreg_runtime_NMT_NMTPrintMallocSiteOfCorruptedMemory_java\scratch\0\hs_err_pid2300.log
      [0.103s][warning][os] Loading hsdis library failed
      #
      # If you would like to submit a bug report, please visit:
      # https://bugreport.java.com/bugreport/crash.jsp
      #
      ];
       stderr: [WARNING: A restricted method in java.lang.System has been called
      WARNING: java.lang.System::loadLibrary has been called by NMTPrintMallocSiteOfCorruptedMemory in an unnamed module (file:/C:/Users/Administrator/temp/jdk/build/windows-x86_64-server-release/test-support/jtreg_test_hotspot_jtreg_runtime_NMT_NMTPrintMallocSiteOfCorruptedMemory_java/classes/0/runtime/NMT/NMTPrintMallocSiteOfCorruptedMemory.d/)
      WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
      WARNING: Restricted methods will be blocked in a future release unless native access is enabled

      ]
       exitValue = 1

      java.lang.RuntimeException: '\[.*\]WB_NMTMalloc\+0x.*' missing from stdout/stderr
              at jdk.test.lib.process.OutputAnalyzer.shouldMatch(OutputAnalyzer.java:407)
              at NMTPrintMallocSiteOfCorruptedMemory.runThisTestWith(NMTPrintMallocSiteOfCorruptedMemory.java:71)
              at NMTPrintMallocSiteOfCorruptedMemory.main(NMTPrintMallocSiteOfCorruptedMemory.java:110)
              at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
              at java.base/java.lang.reflect.Method.invoke(Method.java:565)
              at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
              at java.base/java.lang.Thread.run(Thread.java:1516)

      JavaTest Message: Test threw exception: java.lang.RuntimeException: '\[.*\]WB_NMTMalloc\+0x.*' missing from stdout/stderr
      JavaTest Message: shutting down test

      STATUS:Failed.`main' threw exception: java.lang.RuntimeException: '\[.*\]WB_NMTMalloc\+0x.*' missing from stdout/stderr
      ```

            Assignee:
            Afshin Zafari
            Reporter:
            Satyen Subramaniam
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: