JDK-8337196 : Failure of serviceability/sa/TestJmapCore.java using clang toolchain
  • Type: Enhancement
  • Component: core-svc
  • Sub-Component: tools
  • Priority: P4
  • Status: Closed
  • Resolution: Won't Fix
  • Submitted: 2024-07-25
  • Updated: 2025-09-14
  • Resolved: 2024-08-21
Related Reports
Relates :  
Description
`make CONF=debug test TEST=serviceability/sa/TestJmapCore.java` fails consistently using clang toolchain on linux x64.

gcc toolchain works fine.

It's possible that this is a clang bug.

ENV: clang-14

The following error message is seen in the .jtr file:

Error attaching to core file: Can't attach to the core file 

After exporting LIBSAPROC_DEBUG=1, the following additional information is present:

libsaproc DEBUG: address conflict @ 0x7fd5237f9fa0 (existing map size = 21311488, size = 21305808, flags = 5)                                                                 
libsaproc DEBUG: can't read shared object's segments

I think this means we have two different segments mapping to the same address, and they have different sizes, which they shouldn't. The address in question is in libjvm.so:

libsaproc DEBUG: reading library /<snip>/build/linux-x64-debug/images/jdk/lib/server/libjvm.so @ 0x7fd523000000 [ 0x7fd523000000 ] 
libsaproc DEBUG: overwrote with new address mapping (memsz 8359936 -> 8359936)
Comments
Thanks.
12-11-2024

Oracle doesn't support clang and doesn't test with it. Any discussion of a Problemlist-clang.txt problem list should be made in on the hotspot-dev mailing list.
12-11-2024

Do we need Problemlist-clang.txt to record the releated known failure tests
09-11-2024

<Serviceability triage team>: SA does not support JVMs built with clang
21-08-2024