public inbox for gdb-testers@sourceware.org help / color / mirror / Atom feed
From: gdb-buildbot@sergiodj.net To: gdb-testers@sourceware.org Subject: [binutils-gdb] Fix regression from TUI disassembly style patch Date: Wed, 06 Nov 2019 02:10:00 -0000 [thread overview] Message-ID: <825165c57e43b25ef57c3cf2cc345ec6aa40a0d3@gdb-build> (raw) *** TEST RESULTS FOR COMMIT 825165c57e43b25ef57c3cf2cc345ec6aa40a0d3 *** commit 825165c57e43b25ef57c3cf2cc345ec6aa40a0d3 Author: Tom Tromey <tom@tromey.com> AuthorDate: Tue Nov 5 18:12:49 2019 -0700 Commit: Tom Tromey <tom@tromey.com> CommitDate: Tue Nov 5 18:39:23 2019 -0700 Fix regression from TUI disassembly style patch My previous patch to add styling to the TUI disassembly failed to correctly fix a bug that Simon had pointed out in review. This patch fixes the bug. gdb/ChangeLog 2019-11-05 Tom Tromey <tom@tromey.com> * tui/tui-disasm.c (struct tui_asm_line) <addr_size>: New member. (tui_disassemble): Set addr_size. (tui_disasm_window::set_contents): Use addr_size. Change-Id: Ic0152f3b82a2f79be28ae46d590096661f271580 diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 5720c8e7fe..e886480d62 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2019-11-05 Tom Tromey <tom@tromey.com> + + * tui/tui-disasm.c (struct tui_asm_line) <addr_size>: New member. + (tui_disassemble): Set addr_size. + (tui_disasm_window::set_contents): Use addr_size. + 2019-11-05 Tom Tromey <tom@tromey.com> * rust-lang.c (rust_language_defn): Update. diff --git a/gdb/tui/tui-disasm.c b/gdb/tui/tui-disasm.c index 7178326639..8d5512efb2 100644 --- a/gdb/tui/tui-disasm.c +++ b/gdb/tui/tui-disasm.c @@ -47,6 +47,7 @@ struct tui_asm_line { CORE_ADDR addr; std::string addr_string; + size_t addr_size; std::string insn; }; @@ -110,6 +111,7 @@ tui_disassemble (struct gdbarch *gdbarch, else new_size = asm_lines[pos + i].addr_string.size (); *addr_size = std::max (*addr_size, new_size); + asm_lines[pos + i].addr_size = new_size; } pc = pc + gdb_print_insn (gdbarch, pc, &gdb_dis_out, NULL); @@ -239,8 +241,7 @@ tui_disasm_window::set_contents (struct gdbarch *arch, std::string line = (asm_lines[i].addr_string - + n_spaces (insn_pos - - asm_lines[i].addr_string.size ()) + + n_spaces (insn_pos - asm_lines[i].addr_size) + asm_lines[i].insn); const char *ptr = line.c_str ();
next reply other threads:[~2019-11-06 2:10 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-11-06 2:10 gdb-buildbot [this message] 2019-11-06 2:11 ` Failures on Ubuntu-Aarch64-m64, branch master gdb-buildbot 2019-11-06 2:25 ` Failures on Ubuntu-Aarch64-native-gdbserver-m64, " gdb-buildbot 2019-11-22 18:14 ` Failures on Fedora-x86_64-cc-with-index, " gdb-buildbot 2019-11-22 18:44 ` Failures on Fedora-x86_64-m32, " gdb-buildbot 2019-11-22 19:01 ` Failures on Fedora-x86_64-m64, " gdb-buildbot 2019-11-22 19:38 ` Failures on Fedora-x86_64-native-extended-gdbserver-m32, " gdb-buildbot 2019-11-22 19:56 ` Failures on Fedora-x86_64-native-extended-gdbserver-m64, " gdb-buildbot
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=825165c57e43b25ef57c3cf2cc345ec6aa40a0d3@gdb-build \ --to=gdb-buildbot@sergiodj.net \ --cc=gdb-testers@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).