summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-08-06Automatic date update in version.inlinaro-local/ci/tcwg_gnu_native_check_binutils/release-armGDB Administrator
2022-08-05Automatic date update in version.inGDB Administrator
2022-08-04Automatic date update in version.inGDB Administrator
2022-08-03Automatic date update in version.inGDB Administrator
2022-08-02Automatic date update in version.inGDB Administrator
2022-08-01Automatic date update in version.inGDB Administrator
2022-07-31Automatic date update in version.inGDB Administrator
2022-07-30Automatic date update in version.inGDB Administrator
2022-07-29Automatic date update in version.inGDB Administrator
2022-07-28Automatic date update in version.inGDB Administrator
2022-07-27Automatic date update in version.inGDB Administrator
2022-07-26Automatic date update in version.inGDB Administrator
2022-07-25Automatic date update in version.inGDB Administrator
2022-07-24Automatic date update in version.inGDB Administrator
2022-07-23Automatic date update in version.inGDB Administrator
2022-07-22Automatic date update in version.inGDB Administrator
2022-07-21Automatic date update in version.inGDB Administrator
2022-07-20Automatic date update in version.inGDB Administrator
2022-07-19Automatic date update in version.inGDB Administrator
2022-07-18Automatic date update in version.inGDB Administrator
2022-07-17Automatic date update in version.inGDB Administrator
2022-07-16Automatic date update in version.inGDB Administrator
2022-07-15Automatic date update in version.inGDB Administrator
2022-07-14Automatic date update in version.inGDB Administrator
2022-07-13Automatic date update in version.inGDB Administrator
2022-07-12Automatic date update in version.inGDB Administrator
2022-07-11Fix core-file -> detach -> crash (corefiles/29275)Pedro Alves
After loading a core file, you're supposed to be able to use "detach" to unload the core file. That unfortunately regressed starting with GDB 11, with these commits: 1192f124a308 - gdb: generalize commit_resume, avoid commit-resuming when threads have pending statuses 408f66864a1a - detach in all-stop with threads running resulting in a GDB crash: ... Thread 1 "gdb" received signal SIGSEGV, Segmentation fault. 0x0000555555e842bf in maybe_set_commit_resumed_all_targets () at ../../src/gdb/infrun.c:2899 2899 if (proc_target->commit_resumed_state) (top-gdb) bt #0 0x0000555555e842bf in maybe_set_commit_resumed_all_targets () at ../../src/gdb/infrun.c:2899 #1 0x0000555555e848bf in scoped_disable_commit_resumed::reset (this=0x7fffffffd440) at ../../src/gdb/infrun.c:3023 #2 0x0000555555e84a0c in scoped_disable_commit_resumed::reset_and_commit (this=0x7fffffffd440) at ../../src/gdb/infrun.c:3049 #3 0x0000555555e739cd in detach_command (args=0x0, from_tty=1) at ../../src/gdb/infcmd.c:2791 #4 0x0000555555c0ba46 in do_simple_func (args=0x0, from_tty=1, c=0x55555662a600) at ../../src/gdb/cli/cli-decode.c:95 #5 0x0000555555c112b0 in cmd_func (cmd=0x55555662a600, args=0x0, from_tty=1) at ../../src/gdb/cli/cli-decode.c:2514 #6 0x0000555556173b1f in execute_command (p=0x5555565c5916 "", from_tty=1) at ../../src/gdb/top.c:699 The code that crashes looks like: static void maybe_set_commit_resumed_all_targets () { scoped_restore_current_thread restore_thread; for (inferior *inf : all_non_exited_inferiors ()) { process_stratum_target *proc_target = inf->process_target (); if (proc_target->commit_resumed_state) ^^^^^^^^^^^ With 'proc_target' above being null. all_non_exited_inferiors filters out inferiors that have pid==0. We get here at the end of detach_command, after core_target::detach has already run, at which point the inferior _should_ have pid==0 and no process target. It is clear it no longer has a process target, but, it still has a pid!=0 somehow. The reason the inferior still has pid!=0, is that core_target::detach just unpushes, and relies on core_target::close to actually do the getting rid of the core and exiting the inferior. The problem with that is that detach_command grabs an extra strong reference to the process stratum target, so the unpush_target inside core_target::detach doesn't actually result in a call to core_target::close. Fix this my moving the cleaning up the core inferior to a shared routine called by both core_target::close and core_target::detach. We still need to cleanup the inferior from within core_file::close because there are paths to it that want to get rid of the core without going through detach. E.g., "core-file" -> "run". This commit includes a new test added to gdb.base/corefile.exp to cover the "core-file core" -> "detach" scenario. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=29275 Change-Id: Ic42bdd03182166b19f598428b0dbc2ce6f67c893
2022-07-11Automatic date update in version.inGDB Administrator
2022-07-10Automatic date update in version.inGDB Administrator
2022-07-09Automatic date update in version.inGDB Administrator
2022-07-08Automatic date update in version.inGDB Administrator
2022-07-07Automatic date update in version.inGDB Administrator
2022-07-06Automatic date update in version.inGDB Administrator
2022-07-05Automatic date update in version.inGDB Administrator
2022-07-04Automatic date update in version.inGDB Administrator
2022-07-03Automatic date update in version.inGDB Administrator
2022-07-02Automatic date update in version.inGDB Administrator
2022-07-01Automatic date update in version.inGDB Administrator
2022-06-30Automatic date update in version.inGDB Administrator
2022-06-29Automatic date update in version.inGDB Administrator
2022-06-28Automatic date update in version.inGDB Administrator
2022-06-27Automatic date update in version.inGDB Administrator
2022-06-26Automatic date update in version.inGDB Administrator
2022-06-25Automatic date update in version.inGDB Administrator
2022-06-24Automatic date update in version.inGDB Administrator
2022-06-23Automatic date update in version.inGDB Administrator
2022-06-22Automatic date update in version.inGDB Administrator
2022-06-21Automatic date update in version.inGDB Administrator
2022-06-20Automatic date update in version.inGDB Administrator
2022-06-19Automatic date update in version.inGDB Administrator