Created attachment 10781 [details] test program While debugging a program compiled with "gcc -mmpx -fcheck-pointer-bounds", I wish to see the bounds a of variable, as documented in https://sourceware.org/gdb/onlinedocs/gdb/i386.html But the "show mpx bound <variable>" command fails: (gdb) show mpx bound mem Invalid bounds directory entry at 0x7fff773e7030. This happens although the process itself does proper bounds checking. How to reproduce: $ gcc -mmpx -fcheck-pointer-bounds -ggdb foo.c $ gdb a.out (gdb) break main (gdb) run (gdb) next (gdb) next (gdb) next (gdb) show mpx bound mem (gdb) show mpx bound p (gdb) continue Continuing. Program received signal SIGSEGV, Segmentation fault. 0x00000000004005c8 in main () at foo.c:9 9 p[-2] = 'x';
As a workaround, I can use (gdb) print $bnd0 but this is pretty low-level debugging.