aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2022-10-24x86: emit {evex} prefix when disassembling ambiguous AVX512VL insnsJan Beulich37-596/+632
When no AVX512-specific functionality is in use, the disassembly of AVX512VL insns is indistinguishable from their AVX counterparts (if such exist). Emit the {evex} pseudo-prefix in such cases. Where applicable drop stray uses of PREFIX_OPCODE from table entries.
2022-10-24[gdb/testsuite] Add skip_python_tests in gdb.python/tui-window-names.expTom de Vries1-0/+5
I did a gdb build without python support, and during testing ran into FAILs in test-case gdb.python/tui-window-names.exp. Fix this by adding the missing skip_python_test. Tested on x86_64-linux.
2022-10-24Automatic date update in version.inGDB Administrator1-1/+1
2022-10-24sim: testsuite: update ignored .exp files [PR sim/29596]Mike Frysinger2-0/+4
Now that we run `check/foo.exp` instead of `check/./foo.exp`, update the config/ & lib/ exceptions to cover both paths. Bug: https://sourceware.org/PR29596
2022-10-24sim: testsuite: tweak parallel find invocation [PR sim/29596]Mike Frysinger2-2/+2
Make sure we invoke runtest with the same exp filenames when running in parallel as it will find when run single threaded. When `runtest` finds files itself, it will use paths like "aarch64/allinsn.exp". When we run `find .` with the %p option, it produces "./aarch64/allinsn.exp". Switch to %P to get "aarch64/allinsn.exp". Bug: https://sourceware.org/PR29596
2022-10-23sim: mips/ppc/riscv: re-add AC_CANONICAL_SYSTEM [PR sim/29439]Mike Frysinger6-0/+457
These configure scripts check $target and change behavior. They shouldn't be doing that, but until we can rework the sim to change behavior based on the input ELF, restore AC_CANONICAL_SYSTEM to these so that $target is correctly populated. This was lost in the d3562f83a7b8a1ae6e333cd5561419d3da18fcb4 ("sim: unify toolchain probing logic") refactor as the logic was hoisted up to the common code. But the fact the vars weren't passed down to the sub-configure scripts was missed. Bug: https://sourceware.org/PR29439
2022-10-23Automatic date update in version.inGDB Administrator1-1/+1
2022-10-22gdb/testsuite: add max number of instructions check in ↵Simon Marchi1-0/+7
gdb.base/unwind-on-each-insn.exp This test sends my CI in an infinite loop of failures. We expect to have a handful of iterations (5 on my development machine, where the test passes fine)but the log shows that it went up to 104340 iterations: FAIL: gdb.base/unwind-on-each-insn.exp - instruction 104340: maint print frame-id DUPLICATE: gdb.base/unwind-on-each-insn.exp - instruction 104340: maint print frame-id FAIL: gdb.base/unwind-on-each-insn.exp - instruction 104340: [string equal $fid $main_fid] FAIL: gdb.base/unwind-on-each-insn.exp - instruction 104340: get hexadecimal valueof "$pc" Add a max instruction check, exit the loop if we reach 100 iterations. This should allow the test to fail fast if there's a problem, but 100 iterations should be more than enough for when things are working. Change-Id: I77978d593aca046068f9209272d82e1675ba17c2
2022-10-22Automatic date update in version.inGDB Administrator1-1/+1
2022-10-21Improve Python Unwinders documentationPedro Alves1-9/+9
- avoid "GDB proper" to refer to global locus, as object files and program spaces are also GDB proper. - gdb.register_unwinder does not accept locus=gdb. - "a unwinder" -> "an unwinder" Approved-by: Eli Zaretskii <eliz@gnu.org> Change-Id: I98c1b1000e1063815238e945ca71ec6f37b5702e
2022-10-21gdb: make inherit_abstract_dies use vector iteratorsSimon Marchi1-13/+12
Small cleanup to use std::vector iterators rather than raw pointers. Approved-By: Tom Tromey <tom@tromey.com> Change-Id: I8d50dbb3f2d8dad7ff94066a578d523f1f31b590
2022-10-21gdb: check for empty offsets vector in inherit_abstract_diesSimon Marchi1-9/+14
When building GDB with clang and --enable-ubsan, I get: UNRESOLVED: gdb.dwarf2/frame-inlined-in-outer-frame.exp: starti prompt The cause being: $ ./gdb --data-directory=data-directory -nx -q -readnow testsuite/outputs/gdb.dwarf2/frame-inlined-in-outer-frame/frame-inlined-in-outer-frame Reading symbols from testsuite/outputs/gdb.dwarf2/frame-inlined-in-outer-frame/frame-inlined-in-outer-frame... Expanding full symbols from testsuite/outputs/gdb.dwarf2/frame-inlined-in-outer-frame/frame-inlined-in-outer-frame... /home/simark/src/binutils-gdb/gdb/dwarf2/read.c:11954:47: runtime error: applying non-zero offset 8 to null pointer I found this to happen with ld-linux on at least Arch Linux and Ubuntu 22.04: $ ./gdb --data-directory=data-directory -nx -q -readnow -iex "set debuginfod enabled on" /lib64/ld-linux-x86-64.so.2 Reading symbols from /lib64/ld-linux-x86-64.so.2... Reading symbols from /home/simark/.cache/debuginfod_client/22bd7a2c03d8cfc05ef7092bfae5932223189bc1/debuginfo... Expanding full symbols from /home/simark/.cache/debuginfod_client/22bd7a2c03d8cfc05ef7092bfae5932223189bc1/debuginfo... /home/simark/src/binutils-gdb/gdb/dwarf2/read.c:11954:47: runtime error: applying non-zero offset 8 to null pointer The problem happens when doing this: sect_offset *offsetp = offsets.data () + 1 When `offsets` is an empty vector, `offsets.data ()` returns nullptr. Fix it by wrapping that in a `!offsets.empty ()` check. Change-Id: I6d29ba2fe80ba4308f68effd9c57d4ee8d67c29f Approved-By: Tom Tromey <tom@tromey.com>
2022-10-21readelf: support zstd compressed debug sections [PR 29640]Fangrui Song3-48/+80
2022-10-21Fix incorrect .gdb_index with new DWARF scannerTom Tromey3-8/+34
PR symtab/29694 points out a regression caused by the new DWARF scanner when the cc-with-gdb-index target board is used. What happens here is that an older version of gdb will make an index describing the "A" type as: [737] A: 1 [global, type] whereas the new gdb says: [1008] A: 0 [global, type] Here the old one is correct because the A in CU 0 is just a declaration without a size: <1><45>: Abbrev Number: 10 (DW_TAG_structure_type) <46> DW_AT_name : A <48> DW_AT_declaration : 1 <48> DW_AT_sibling : <0x6d> This patch fixes the problem by introducing the idea of a "type declaration". I think gdb still needs to recurse into these types, searching for methods, but by marking the type itself as a declaration, gdb can skip this type during lookups and when writing the index. Regression tested on x86-64 using the cc-with-gdb-index board. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=29694
2022-10-21Fix crash in value_print_array_elementsTom Tromey4-7/+126
A user noticed that gdb would crash when printing a packed array after doing "set lang c". Packed arrays don't exist in C, but it's occasionally useful to print things in C mode when working in a non-C language -- this lets you see under the hood a little bit. The bug here is that generic value printing does not handle packed arrays at all. This patch fixes the bug by introducing a new function to extract a value from a bit offset and width. The new function includes a hack to avoid problems with some existing test cases when using -fgnat-encodings=all. Cleaning up this code looked difficult, and since "all" is effectively deprecated, I thought it made sense to simply work around the problems.
2022-10-21Fix bug in Ada packed array handlingTom Tromey5-0/+46
A user found a bug where an array of packed arrays was printed incorrectly. The bug here is that the packed array has a bit stride, but the outer array does not -- and should not. However, update_static_array_size does not distinguish between an array of packed arrays and a multi-dimensional packed array, and for the latter, only the innermost array will end up with a stride. This patch fixes the problem by adding a flag to indicate whether a given array type is a constituent of a multi-dimensional array.
2022-10-21gdb: declare variables on first use in inherit_abstract_diesSimon Marchi1-28/+23
Move variable declarations to where they are first use, plus some random style fixes. Change-Id: Idf40d60f9034996fa6a234165cd989a721eb4148
2022-10-21Add a -w option to the linker to suppress warning and error messages.Nick Clifton7-1/+42
PR 29654 * ld.h (struct ld_config_type): Add no_warnings field. * ldlex.h (enum option_values): Add OPTION_NO_WARNINGS. * lexsup.c (ld_options): Add --no-warnings. (parse_args): Add support for -w and --no-warnings. * ldmisc.c (vfinfo): Return early if the message is a warning and -w has been enabled. * ld.texi (options): Document new command line option. * NEWS: Mention the new feature.
2022-10-21Add a note to the binutils/NEWS file about DCO signed contributions.Nick Clifton1-0/+2
2022-10-21gdb/reverse: Fix stepping over recursive functionsBruno Larsen4-8/+74
Currently, when using GDB to do reverse debugging, if we try to use the command "reverse next" to skip a recursive function, instead of skipping all of the recursive calls and stopping in the previous line, we stop at the second to last recursive call, and need to manually step backwards until we leave the first call. This is well documented in PR gdb/16678. This bug happens because when GDB notices that a reverse step has entered into a function, GDB will add a step_resume_breakpoint at the start of the function, then single step out of the prologue once that breakpoint is hit. The problem was happening because GDB wouldn't give that step_resume_breakpoint a frame-id, so the first time the breakpoint was hit, the inferior would be stopped. This is fixed by giving the current frame-id to the breakpoint. This commit also changes gdb.reverse/step-reverse.c to contain a recursive function and attempt to both, skip it altogether, and to skip the second call from inside the first call, as this setup broke a previous version of the patch.
2022-10-21Change calculation of frame_id by amd64 epilogue unwinderBruno Larsen4-5/+206
When GDB is stopped at a ret instruction and no debug information is available for unwinding, GDB defaults to the amd64 epilogue unwinder, to be able to generate a decent backtrace. However, when calculating the frame id, the epilogue unwinder generates information as if the return instruction was the whole frame. This was an issue especially when attempting to reverse debug, as GDB would place a step_resume_breakpoint from the epilogue of a function if we were to attempt to skip that function, and this breakpoint should ideally have the current function's frame_id to avoid other problems such as PR record/16678. This commit changes the frame_id calculation for the amd64 epilogue, so that it is always the same as the dwarf2 unwinder's frame_id. It also adds a test to confirm that the frame_id will be the same, regardless of using the epilogue unwinder or not, thanks to Andrew Burgess. Co-Authored-By: Andrew Burgess <aburgess@redhat.com>
2022-10-21Updated Hungarian translation for the gprof sub-directory.Nick Clifton2-27/+31
* po/hu.po: Updated Hungarian translation.
2022-10-21GDB/Python: Make `None' stand for `unlimited' in setting integer parametersMaciej W. Rozycki3-12/+28
Similarly to booleans and following the fix for PR python/29217 make `gdb.parameter' accept `None' for `unlimited' with parameters of the PARAM_UINTEGER, PARAM_INTEGER, and PARAM_ZUINTEGER_UNLIMITED types, as `None' is already returned by parameters of the two former types, so one might expect to be able to feed it back. It also makes it possible to avoid the need to know what the internal integer representation is for the special setting of `unlimited'. Expand the testsuite accordingly. Approved-By: Simon Marchi <simon.marchi@polymtl.ca>
2022-10-21GDB/testsuite: Expand Python integer parameter coverage across all typesMaciej W. Rozycki1-16/+181
Also verify PARAM_UINTEGER, PARAM_INTEGER, and PARAM_ZINTEGER parameter types, in addition to PARAM_ZUINTEGER and PARAM_ZUINTEGER_UNLIMITED already covered, and verify a choice of existing GDB parameters. Add verification for reading parameters via `<parameter>.value' in addition to `gdb.parameter('<parameter>')' as this covers different code paths. Approved-By: Simon Marchi <simon.marchi@polymtl.ca>
2022-10-21GDB/Guile: Don't assert that an integer value is booleanMaciej W. Rozycki2-1/+177
Do not assert that a value intended for an integer parameter, of either the PARAM_UINTEGER or the PARAM_ZUINTEGER_UNLIMITED type, is boolean, causing error messages such as: ERROR: In procedure make-parameter: ERROR: In procedure gdbscm_make_parameter: Wrong type argument in position 15 (expecting integer or #:unlimited): 3 Error while executing Scheme code. when initialization with a number is attempted. Instead assert that it is integer. Keep matching `#:unlimited' keyword as an alternative. Add suitable test cases. Approved-By: Simon Marchi <simon.marchi@polymtl.ca>
2022-10-21[gdb/testsuite] Silence compilation fail in gdb.base/rtld-step.expTom de Vries1-0/+8
With gcc 7.5.0 and test-case gdb.base/rtld-step.exp, I run into: ... gdb compile failed, gcc: error: unrecognized command line option \ '-static-pie'; did you mean '-static'? ... Silence this by checking in the test-case that -static-pie is supported, and emitting instead: ... UNTESTED: gdb.base/rtld-step.exp: \ failed to compile (-static-pie not supported or static libc missing) ... Tested on x86_64-linux, with: - gcc 7.5.0: UNTESTED - gcc 12.2.1 with static glibc not installed: UNTESTED - gcc 12.2.1 with static glibc installed: PASS
2022-10-21Support Intel AMX-FP16Cui,Lili15-4089/+4236
gas/ * NEWS: Add support for Intel AMX-FP16 instruction. * config/tc-i386.c: Add amx_fp16. * doc/c-i386.texi: Document .amx_fp16. * testsuite/gas/i386/i386.exp: Add AMX-FP16 tests. * testsuite/gas/i386/x86-64-amx-fp16-intel.d: New test. * testsuite/gas/i386/x86-64-amx-fp16.d: Likewise. * testsuite/gas/i386/x86-64-amx-fp16.s: Likewise. * testsuite/gas/i386/x86-64-amx-fp16-bad.d: Likewise. * testsuite/gas/i386/x86-64-amx-fp16-bad.s: Likewise. opcodes/ * i386-dis.c (MOD_VEX_0F385C_X86_64_P_3_W_0): New. (VEX_LEN_0F385C_X86_64_P_3_W_0_M_0): Likewise. (VEX_W_0F385C_X86_64_P_3): Likewise. (prefix_table): Add VEX_W_0F385C_X86_64_P_3. (vex_len_table): Add VEX_LEN_0F385C_X86_64_P_3_W_0_M_0. (vex_w_table): Add VEX_W_0F385C_X86_64_P_3. (mod_table): Add MOD_VEX_0F385C_X86_64_P_3_W_0. * i386-gen.c (cpu_flag_init): Add AMX-FP16_FLAGS. (CPU_ANY_AMX_TILE_FLAGS): Add CpuAMX_FP16. (cpu_flags): Add CpuAMX-FP16. * i386-opc.h (enum): Add CpuAMX-FP16. (i386_cpu_flags): Add cpuamx_fp16. * i386-opc.tbl: Add Intel AMX-FP16 instruction. * i386-init.h: Regenerate. * i386-tbl.h: Likewise.
2022-10-21sim: Remove unused CXXFLAGS substitutionTsukasa OI1-1/+0
Not only that sim/configure.ac does not AC_SUBST CXXFLAGS, unless we need C++ compiler like CXX, substitution @CXXFLAGS@ is useless. Because of this, this commit removes this substitution.
2022-10-21Automatic date update in version.inGDB Administrator1-1/+1
2022-10-20x86: Check VEX/EVEX encoding before checking vector operandsH.J. Lu5-4/+8
Since commit 837e225ba1992f9745e5bbbd5e8443243a7f475f Author: Jan Beulich <jbeulich@suse.com> Date: Thu Oct 20 10:01:12 2022 +0200 x86: re-work AVX-VNNI support moved AVX-VNNI after AVX512-VNNI, vector Disp8 is applied even when VEX encoding is selected. Check VEX/EVEX encoding before checking vector operands to avoid vector Disp8 with VEX encoding. PR gas/29708 * config/tc-i386.c (match_template): Check VEX/EVEX encoding before checking vector operands. * testsuite/gas/i386/avx-vnni.d: Updated. * testsuite/gas/i386/x86-64-avx-vnni.d: Likewise. * testsuite/gas/i386/avx-vnni.s: Add a Disp32 test. * testsuite/gas/i386/x86-64-avx-vnni.s: Likewise.
2022-10-20gdb/python: break more dependencies between gdbpy_initialize_* functionsAndrew Burgess3-2/+36
In a later commit in this series I will propose removing all of the explicit gdbpy_initialize_* calls from python.c and replace these calls with a more generic mechanism. One of the side effects of this generic mechanism is that the order in which the various Python sub-systems within GDB are initialized is no longer guaranteed. On the whole I don't think this matters, most of the sub-systems are independent of each other, though testing did reveal a few places where we did have dependencies, though I don't think those dependencies were explicitly documented in comment anywhere. This commit is similar to the previous one, and fixes the second dependency issue that I found. In this case the finish_breakpoint_object_type uses the breakpoint_object_type as its tp_base, this means that breakpoint_object_type must have been initialized with a call to PyType_Ready before finish_breakpoint_object_type can be initialized. Previously we depended on the ordering of calls to gdbpy_initialize_breakpoints and gdbpy_initialize_finishbreakpoints in python.c. After this commit a new function gdbpy_breakpoint_init_breakpoint_type exists, this function ensures that breakpoint_object_type has been initialized, and can be called from any gdbpy_initialize_* function. I feel that this change makes the dependency explicit, which I think is a good thing. There should be no user visible changes after this commit.
2022-10-20gdb/python: break dependencies between gdbpy_initialize_* functionsAndrew Burgess3-14/+42
In a later commit in this series I will propose removing all of the explicit gdbpy_initialize_* calls from python.c and replace these calls with a more generic mechanism. One of the side effects of this generic mechanism is that the order in which the various Python sub-systems within GDB are initialized is no longer guaranteed. On the whole I don't think this matters, most of the sub-systems are independent of each other, though testing did reveal a few places where we did have dependencies, though I don't think those dependencies were explicitly documented in a comment anywhere. This commit removes the first dependency issue, with this and the next commit, all of the implicit inter-sub-system dependencies will be replaced by explicit dependencies, which will allow me to, I think, clean up how the sub-systems are initialized. The dependency is around the py_insn_type. This type is setup in gdbpy_initialize_instruction and used in gdbpy_initialize_record. Rather than depend on the calls to these two functions being in a particular order, in this commit I propose adding a new function py_insn_get_insn_type. This function will take care of setting up the py_insn_type type and calling PyType_Ready. This helper function can be called from gdbpy_initialize_record and gdbpy_initialize_instruction, and the py_insn_type will be initialized just once. To me this is better, the dependency is now really obvious, but also, we no longer care in which order gdbpy_initialize_record and gdbpy_initialize_instruction are called. There should be no user visible changes after this commit.
2022-10-20gdb: some int to bool conversion in breakpoint.cAndrew Burgess1-141/+135
Some int to bool conversion in breakpoint.c. I've only updated the function signatures of static functions, but I've updated some function local variables throughout the file. There should be no user visible changes after this commit. Approved-By: Simon Marchi <simon.marchi@efficios.com>
2022-10-20gdb: make use of scoped_restore in unduplicated_should_be_insertedAndrew Burgess1-7/+4
I noticed that we could make use of a scoped_restore in the function unduplicated_should_be_inserted. I've also converted the function return type from int to bool. This change shouldn't make any difference, as I don't think anything within should_be_inserted could throw an exception, but the change doesn't hurt, and will help keep us safe if anything ever changes in the future. Approved-By: Simon Marchi <simon.marchi@efficios.com>
2022-10-20gdb: used scoped_restore_frame in update_watchpointAndrew Burgess1-12/+5
I was doing some int to bool cleanup in update_watchpoint, and I noticed a manual version of scoped_restore_selected_frame. As always when these things are done manually, there is the chance that, in an error case, we might leave the wrong frame selected. This commit updates things to use scoped_restore_selected_frame, and also converts a local variable from int to bool. The only user visible change after this commit is in the case where update_watchpoint throws an error - we should now correctly restore the previously selected frame. Otherwise, this commit should be invisible to the user. Approved-By: Simon Marchi <simon.marchi@efficios.com>
2022-10-20gdb: make some bp_location arguments const in breakpoint.cAndrew Burgess1-14/+14
I spotted a few places where I could make some 'bp_location *' arguments constant in breakpoint.c. There should be no user visible changes after this commit. Approved-By: Simon Marchi <simon.marchi@efficios.com>
2022-10-20Reapply "Don't build readline/libreadline.a, when --with-system-readline is ↵Дилян Палаузов2-0/+12
supplied" Commit 228cf97dd3c8 ("Merge configure.ac from gcc project") undid the change originally done in commit 69961a84c9b ("Don't build readline/libreadline.a, when --with-system-readline is supplied"). Re-apply it. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=18632
2022-10-20x86: re-work AVX-VNNI supportJan Beulich11-7037/+7057
By putting the templates after their AVX512 counterparts, the AVX512 flavors will be picked by default. That way the need to always use {vex} ceases to exist once respective CPU features (AVX512-VNNI or AVX512VL as a whole) have been disabled. This way the need for the PseudoVexPrefix attribute also disappears.
2022-10-20[gdb/testsuite] Fix gdb.debuginfod/fetch_src_and_symbols.exp with check-read1Tom de Vries1-3/+6
With test-case gdb.debuginfod/fetch_src_and_symbols.exp and check-read1, I run into: ... (gdb) FAIL: gdb.debuginfod/fetch_src_and_symbols.exp: local_url: \ file fetch_src_and_symbols (got interactive prompt) ... The problem is that this output: ... Enable debuginfod for this session? (y or [n]) y^M ... is matched using regexp "Enable debuginfod?.*" with matches only the first two words of the output, after which an implicit clause in gdb_test_multiple triggers on the second part containing the interactive prompt. Fix this by included the interactive prompt in the regexp. Tested on x86_64-linux.
2022-10-20[gdb/testsuite] Fix gdb.mi/mi-disassemble.exp with check-read1Tom de Vries2-2/+2
With test-case gdb.mi/mi-disassemble.exp and check-read1 I run into: ... FAIL: gdb.mi/mi-disassemble.exp: disassemble /b main FAIL: gdb.mi/mi-disassemble.exp: get valueof "*((unsigned char *) 0x400549)" ... The problem for both FAILs is that the output is parsed using gdb_test_multiple, which has implicit clauses using $gdb_prompt, which can match before the explicit clauses using $mi_gdb_prompt. Fix this by passing -prompt "$mi_gdb_prompt$" to gdb_test_multiple. Tested on x86-64-linux.
2022-10-20Re: aarch64-pe support for LD, GAS and BFDAlan Modra2-1/+4
Fix dependencies for eaarch64pe.c. Generated files aren't handled fully automatically.
2022-10-20ld: Add minimal pdb generationMark Harmstone8-9/+930
2022-10-20ld: Add --pdb optionMark Harmstone7-19/+175
Second patch incorporates fixes for endian and UB issues in calc_hash, as per https://sourceware.org/pipermail/binutils/2022-October/123514.html.
2022-10-19Test stepping within a runtime loader / dynamic linkerKevin Buettner3-0/+227
See the remarks in rtld-step.exp for a description of what this test is about. This test case has been tested using gcc on the following x86-64 Linux distributions/releases: Fedora 28 Fedora 32 Fedora 33 Fedora 34 Fedora 35 Fedora 36 Fedora 37 rawhide (f38) RHEL 9.1 Ubuntu 22.04.1 LTS It's also been tested (and found to be working) with RUNTESTFLAGS="CC_FOR_TARGET=clang" on all of the above expect for Fedora 28. The (old) version of clang available on F28 did not accept the -static-pie option. I also tried to make this test work on FreeBSD 13.1. While I think I made significant progress, I was ultimately stymied by this message which occurs when attempting to run the main program which has been set to use the fake/pretend RTLD as the ELF interpreter: ELF interpreter /path/to/rtld-step-rtld not found, error 22 I have left one of the flags (-static) in place which I believe to be needed for FreeBSD (though since I never got it to work, I don't know for sure.) I've also left some declarations needed for FreeBSD in rtld-step-rtld.c. They're currently disabled via a #if 0; you'll need to enable them if you want to try to make it work on FreeBSD.
2022-10-19Allow debugging of runtime loader / dynamic linkerKevin Buettner1-1/+4
At present, GDB does not allow for the debugging of the runtime loader and/or dynamic linker. Much of the time, this makes sense. An application programmer doesn't normally want to see symbol resolution code when stepping into a function that hasn't been resolved yet. But someone who wishes to debug the runtime loader / dynamic linker might place a breakpoint in that code and then wish to debug it as normal. At the moment, this is not possible. Attempting to step will cause GDB to internally step (and not stop) until code unrelated to the dynamic linker is reached. This commit makes a minor change to infrun.c which allows the dynamic loader / linker to be debugged in the case where a step, next, etc. is initiated from within that code. While developing this fix, I tried some approaches which weren't quite right. The GDB testusite definitely contains tests which FAIL when it's done incorrectly. (At one point, I saw 17 regressions!) This commit has been tested on x86-64 linux with no regressions.
2022-10-20binutils: Remove unused substitution PROGRAMTsukasa OI2-4/+2
Unlike other substitution, this substitution of @PROGRAM@ was done in binutils/Makefile and it was intended for binutils/cxxfilt.man. @PROGRAM@ in binutils/cxxfilt.man is removed in the commit 0285c67df190 ("Automate generate on man pages") in 2001 and @PROGRAM@ is ineffective since then. Because PROGRAM substitution does nothing, removing this manual substitution should be completely safe. binutils/ChangeLog: * doc/local.mk: Remove unused substitution PROGRAM. * Makefile.in: Regenerate.
2022-10-20Automatic date update in version.inGDB Administrator1-1/+1
2022-10-20Obsolete beosAlan Modra1-1/+2
* config.bfd: Obsolete *-*-beos*. Simplify x86 beos match.
2022-10-20Regen ld/po/BLD-POTFILES.inAlan Modra1-0/+1
2022-10-19[gdb] Fix assert in handle_jit_eventTom de Vries1-1/+4
With the cc-with-tweaks.sh patch submitted here ( https://sourceware.org/pipermail/gdb-patches/2022-October/192586.html ) we run with: ... $ export STRIP_ARGS_STRIP_DEBUG=--strip-all $ make check RUNTESTFLAGS="gdb.base/jit-reader.exp \ --target_board cc-with-gnu-debuglink" ... into the following assert: ... (gdb) run ^M Starting program: jit-reader ^M gdb/jit.c:1247: internal-error: jit_event_handler: \ Assertion `jiter->jiter_data != nullptr' failed.^M ... Fix this by handling the jit_bp_sym.objfile->separate_debug_objfile_backlink != nullptr case in handle_jit_event. Tested on x86_64-linux. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=29277