Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
This fixes a couple of small problems in dwarf-mode.el.
First, I noticed that for an attribute like:
<2><136c>: Abbrev Number: 11 (DW_TAG_member)
<136d> DW_AT_name : t
... the "t" would not be font-locked using the function name face.
The problem here is that the regexp assumed the indirect string
format, like:
<12ac> DW_AT_name : (indirect string, offset: 0x1b40): whatever
Here the fix is to adjust the regexp to match both formats.
Second, when following a DIE reference, point could end up on an
attribute instead. This happens when there is a zero-length attribute
with the same "offset" as the following DIE, like:
<12c5> DW_AT_GNU_all_call_sites: 1
<2><12c5>: Abbrev Number: 5 (DW_TAG_formal_parameter)
Here the fix is to search for the DIE by looking for the depth ("<2>"
in the example) as well.
I've bumped the internal version number to make it simpler to install
this using the Emacs package facility.
binutils/ChangeLog
2020-08-12 Tom Tromey <tromey@adacore.com>
* dwarf-mode.el (Version): Now 1.6.
(dwarf-die-button-action): Tighten DIE reference regexp.
(dwarf-font-lock-keywords): Update name regexp.
|
|
|
|
|
|
This adds a syntax table for dwarf-mode to dwarf-mode.el. I noticed
the need for this when trying to use mark-sexp (C-M-SPC) on a hex
number -- it copied the trailing ">" as well, which isn't desirable.
I've also bumped the version number to make this simpler to install
via the Emacs package system.
Tested locally. I'm checking this in.
binutils/ChangeLog
2018-06-25 Tom Tromey <tom@tromey.com>
* dwarf-mode.el (dwarf-mode-syntax-table): New variable.
Bump version number.
|
|
|
|
Bump the dwarf-mode version number, so it can be installed by package.el
users who installed an earlier verision.
2017-10-10 Tom Tromey <tom@tromey.com>
* dwarf-mode.el: Bump to version 1.4.
|
|
I was recently examining a very large .debug file. I tried to use
dwarf-mode, but it blocked Emacs for a very long time while reading
output.
This patch changes dwarf-mode to run the objdump process asynchronously.
This way, I can still do other things in Emacs while waiting for the
dumping to finish.
2017-10-10 Tom Tromey <tom@tromey.com>
* dwarf-mode.el (dwarf--process, dwarf--deletion-region): New
defvar.
(dwarf--check-running, dwarf--sentinel, dwarf--invoke)
(dwarf--filter): New functions.
(dwarf-do-insert-substructure, dwarf-do-refresh): Call
dwarf--check-running, dwarf--invoke.
(dwarf-browse): Initialize new variables.
|
|
Emacs has had lexical binding for a while, and it's a good practice to
use it; so enable it in dwarf-mode.el.
2017-10-10 Tom Tromey <tom@tromey.com>
* dwarf-mode.el: Set lexical-binding.
|
|
It's bad Emacs style to define keys from a top-level form. Instead, one
should define a mode map separately and binding keys in the definition.
This lets users completely override the map by defining it before
loading the mode.
2017-10-10 Tom Tromey <tom@tromey.com>
* dwarf-mode.el (dwarf-mode-map): New defvar.
|
|
|
|
I've been using dwarf-mode.el again recently and I found it mildly
annoying that the mode doesn't set default-directory. Setting it
means that operations in the dwarf-browsing buffer default to the
directory holding the object file being investigated.
This bumps the version number as well so that updating it via the
package manager works properly.
2016-11-04 Tom Tromey <tom@tromey.com>
* dwarf-mode.el (dwarf-browse): Set default-directory. Bump
version number.
|
|
|
|
|
|
|
|
(dwarf-mode): Remove autoload.
(dwarf-die-reference): Relax regexp.
|
|
|
|
(dwarf-insert-substructure-button): Use string-to-number.
(dwarf-browse): Fix autoload cookie.
|
|
expand-file-name.
(dwarf-do-refresh): Likewise.
|
|
dwarf-mode.el.
* objdump.c (suppress_bfd_header): New global.
(usage): Update.
(OPTION_DWARF_DEPTH, OPTION_DWARF_START): New constants.
(options): Add dwarf-depth and dwarf-start entries.
(dump_bfd): Use suppress_bfd_header.
(main): Handle OPTION_DWARF_START, OPTION_DWARF_DEPTH.
* doc/binutils.texi (objcopy): Document --dwarf-depth and
--dwarf-start.
(readelf): Likewise.
* dwarf-mode.el: New file.
* dwarf.c (dwarf_cutoff_level, dwarf_start_die): New globals.
(read_and_display_attr_value): Also check debug_info_p.
(process_debug_info): Handle dwarf_start_die and
dwarf_cutoff_level.
* dwarf.h (dwarf_cutoff_level, dwarf_start_die): Declare.
* readelf.c (usage): Update.
(OPTION_DWARF_DEPTH): New macro.
(OPTION_DWARF_START): Likewise.
(options): Add dwarf-depth and dwarf-start entries.
(parse_args): Handle OPTION_DWARF_START and OPTION_DWARF_DEPTH.
testsuite
* binutils-all/objdump.W: Correct output.
|