8377395: serviceability/sa/TestJhsdbJstackMixedCore.java fails due to NPE because "because "this.cfa" is null"

Reviewed-by: cjplummer, kevinw
This commit is contained in:
Yasumasa Suenaga 2026-02-11 12:04:19 +00:00
parent 0097db5643
commit a532e509ed
3 changed files with 5 additions and 7 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2003, 2026, 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
@ -187,9 +187,8 @@ static bool fill_addr_info(lib_info* lib) {
lib->exec_end = (uintptr_t)-1L;
for (ph = phbuf, cnt = 0; cnt < ehdr.e_phnum; cnt++, ph++) {
if (ph->p_type == PT_LOAD) {
uintptr_t unaligned_start = lib->base + ph->p_vaddr;
uintptr_t aligned_start = align_down(unaligned_start, ph->p_align);
uintptr_t aligned_end = align_up(unaligned_start + ph->p_memsz, ph->p_align);
uintptr_t aligned_start = lib->base + align_down(ph->p_vaddr, ph->p_align);
uintptr_t aligned_end = aligned_start + align_up(ph->p_memsz, ph->p_align);
if ((lib->end == (uintptr_t)-1L) || (lib->end < aligned_end)) {
lib->end = aligned_end;
}

View File

@ -140,7 +140,6 @@ serviceability/sa/TestJmapCore.java 8318754 macosx-aarch64
serviceability/sa/TestJmapCoreMetaspace.java 8318754 macosx-aarch64
serviceability/sa/ClhsdbThreadContext.java 8356704 windows-x64
serviceability/sa/TestJhsdbJstackMixedCore.java 8377395 linux-x64
serviceability/jvmti/stress/StackTrace/NotSuspended/GetStackTraceNotSuspendedStressTest.java 8315980 linux-all,windows-x64

View File

@ -37,7 +37,7 @@ import jtreg.SkippedException;
/**
* @test
* @bug 8374482 8376264 8376284
* @bug 8374482 8376264 8376284 8377395
* @requires (os.family == "linux") & (vm.hasSA)
* @requires os.arch == "amd64"
* @library /test/lib
@ -66,7 +66,7 @@ public class TestJhsdbJstackMixedCore {
out.shouldContain("__restore_rt <signal trampoline>");
out.shouldContain("Java_jdk_test_lib_apps_LingeredApp_crash");
out.shouldContain("* jdk.test.lib.apps.LingeredApp.crash()");
out.shouldContain("jdk.test.lib.apps.LingeredApp.crash()");
}
public static void main(String... args) throws Throwable {