[Bug testsuite/33345] [gdb/testsuite] FAIL: gdb.dap/scopes.exp: fetch all registers success

cvs-commit at gcc dot gnu.org sourceware-bugzilla@sourceware.org
Thu Sep 4 21:20:06 GMT 2025


https://sourceware.org/bugzilla/show_bug.cgi?id=33345

--- Comment #17 from Sourceware Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Andrew Burgess <aburgess@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=650400cb534ef894e9b31939594e1e79832d1030

commit 650400cb534ef894e9b31939594e1e79832d1030
Author: Andrew Burgess <aburgess@redhat.com>
Date:   Mon Sep 1 17:00:15 2025 +0100

    gdb/dap: check values are available before converting to int

    In VariableReference.to_object, we try to convert a gdb.Value to an
    int without checking if the value is actually available.  This came to
    light in PR gdb/33345, after the x86 CET shadow stack patches were
    merged.

    If the x86 CET shadow stack register is available on the machine,
    but the shadow stack feature is not enabled at run time, then the
    register will show as "<unavailable>".

    As the register is of type 'void *', then in the DAP code we try to
    add a 'memoryReference' attribute with the value of the register
    formatted as hex.  This will fail if the register is unavailable.

    To test this change you'll need:

      (a) a machine which support the shadow stack feature, and

      (b) to revert the changes from commit 63b862be762e1e6e7 in the file
          gdb.dap/scopes.exp.

    Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=33345
    Reviewed-By: Christina Schimpe <christina.schimpe@intel.com>

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Gdb-prs mailing list