public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "pedro at palves dot net" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug tui/28600] New: "layout reg" nor "kill" refresh the TUI registers window Date: Wed, 17 Nov 2021 19:17:29 +0000 [thread overview] Message-ID: <bug-28600-4717@http.sourceware.org/bugzilla/> (raw) https://sourceware.org/bugzilla/show_bug.cgi?id=28600 Bug ID: 28600 Summary: "layout reg" nor "kill" refresh the TUI registers window Product: gdb Version: HEAD Status: NEW Severity: normal Priority: P2 Component: tui Assignee: unassigned at sourceware dot org Reporter: pedro at palves dot net Target Milestone: --- If you run to main in CLI mode, and then issue 'layout reg', the register window shows: "[ Register Values Unavailable ]"  ... even though the process is live and we have a frame selected. If you step/stepi/next, etc. at this point, then the registers window refreshes itself and shows registers. In the "step" case, we show registers because we get here: (top-gdb) bt #0 tui_data_window::show_registers (this=0x5555590decf0, group=0x0) at ../../src/gdb/tui/tui-regs.c:183 #1 0x0000555555d22bfd in tui_data_window::check_register_values (this=0x5555590decf0, frame=0x555558d59450) at ../../src/gdb/tui/tui-regs.c:468 #2 0x0000555555d07aa0 in tui_refresh_frame_and_register_information () at ../../src/gdb/tui/tui-hooks.c:143 #3 0x0000555555d07b9b in tui_before_prompt (current_gdb_prompt=0x5555564e3af0 <top_prompt+16> "(top-gdb) ") at ../../src/gdb/tui/tui-hooks.c:185 In the "layout reg" case, we get to tui_refresh_frame_and_register_information as well, but hit the early return: /* Refresh TUI's frame and register information. This is a hook intended to be used to update the screen after potential frame and register changes. */ static void tui_refresh_frame_and_register_information () { if (!from_stack && !from_source_symtab) return; These two "from_stack" and "from_source_symtab" globals are set by the tui_normal_stop, tui_context_changed, tui_symtab_changed observers, AFAICT. So any state change refreshes the TUI registers, but doing "layout reg" does not as it doesn't cause these observers to be called. I also noticed that if you're in "layout reg", and the register window is showing something, and then do "kill", the process is now gone but the register window continues showing the values of the registers from before the kill. Off-hand, I'd think "kill" should have resulted in the tui_context_changed observer being called. I didn't try it, but I'd get "detach", "disconnect" and perhaps other commands have the same issue. -- You are receiving this mail because: You are on the CC list for the bug.
next reply other threads:[~2021-11-17 19:17 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-11-17 19:17 pedro at palves dot net [this message] 2023-11-24 10:28 ` [Bug tui/28600] " vries at gcc dot gnu.org 2023-12-16 8:31 ` cvs-commit at gcc dot gnu.org 2023-12-16 8:37 ` vries at gcc dot gnu.org 2023-12-17 19:37 ` tromey at sourceware dot org 2024-02-08 19:34 ` cvs-commit at gcc dot gnu.org 2024-02-08 19:36 ` tromey at sourceware dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-28600-4717@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).