On Thu, 24 Sep 2026 04:50:13 GMT, Yasumasa Suenaga <[email protected]> wrote:

> serviceability/sa/TestJhsdbJstackMixedWithXComp.java#xcomp failed due because 
> stderr has message to report DebuggerException caused by unknown DWARF opcode.
> 
> During the discussion, we've reached the conclusion that it is better to add 
> `print_waring()` to notice this case (it is handled in 
> [JDK-8392120](https://bugs.openjdk.org/browse/JDK-8392120): PR #33047), and 
> the exception should not be shown in normal.
> 
> Thus this PR proposes to show DebuggerException when `LIBSAPROC_DEBUG` 
> environment variable is set in mixed jstack.
> 
> ---------
> - [x] I confirm that I make this contribution in accordance with the [OpenJDK 
> Interim AI Policy](https://openjdk.org/legal/ai).

I don't like hiding useful failure information behind LIBSAPROC_DEBUG. That is 
why a while back we switched a bunch of print_debug messages to print_error, 
and now the other PR is switching a bunch more to print_warning(). They are 
very useful for debugging intermittent failures. The issue you are fixing is 
that the Dwarf error is resulting in an exception whereas at one point is used 
to just produce a debug message, but not a failure. The exception prints on 
stderr, and that causes the test to fail because it wants stderr to be empty. 
You could instead print the exception on stdout. We could also revisit having 
the Dwarf failure not generate an exception as it  used to do. It use to just 
print a message and then continue on. It's not clear to me if the Dwarf failure 
is guaranteed to be fatal, or if it just might be fatal.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/33048#issuecomment-5824669059

Reply via email to