binutils-gdb/gdb/dwarf2
Simon Marchi 7bc5c369fa gdb: introduce "set index-cache enabled", deprecate "set index-cache on/off"
The "set index-cache" command is used at the same time as a prefix
command (prefix for "set index-cache directory", for example), and a
boolean setting for turning the index-cache on and off.  Even though I
did introduce that, I now don't think it's a good idea to do something
non-standard like this.

First, there's no dedicated CLI command to show whether the index-cache
is enabled, so it has to be custom output in the "show index-cache
handler".  Also, it means there's no good way a MI frontend can find out
if the index-cache is enabled.  "-gdb-show index-cache" doesn't show it
in the MI output record:

    (gdb) interpreter-exec mi "-gdb-show index-cache"
    ~"\n"
    ~"The index cache is currently disabled.\n"
    ^done,showlist={option={name="directory",value="/home/simark/.cache/gdb"}}

Fix this by introducing "set/show index-cache enabled on/off", regular
boolean setting commands.  Keep commands "set index-cache on" and "set
index-cache off" as deprecated aliases of "set index-cache enabled",
with respectively the default arguments "on" and "off".

Update tests using "set index-cache on/off" to use the new command.
Update the regexps in gdb.base/maint.exp to figure out whether the
index-cache is enabled or not.  Update the doc to mention the new
commands.

Change-Id: I7d5aaaf7fd22bf47bd03e0023ef4fbb4023b37b3
2021-11-04 15:48:59 -04:00
..
abbrev.c
abbrev.h
attribute.c
attribute.h
comp-unit-head.c
comp-unit-head.h
cu.c CTF: incorrect underlying type setting for enumeration types 2021-10-18 14:15:21 -04:00
cu.h
die.h
dwz.c gdb: make string-like set show commands use std::string variable 2021-10-03 17:53:16 +01:00
dwz.h
expr.c gdb: change functions returning value contents to use gdb::array_view 2021-10-25 14:51:44 -04:00
expr.h
frame-tailcall.c [gdb/symtab] C++-ify call_site 2021-10-04 18:16:40 +02:00
frame-tailcall.h
frame.c
frame.h
index-cache.c gdb: introduce "set index-cache enabled", deprecate "set index-cache on/off" 2021-11-04 15:48:59 -04:00
index-cache.h
index-common.c
index-common.h
index-write.c
index-write.h
leb.c
leb.h
line-header.c
line-header.h
loc.c gdb: remove FIELD_DWARF_BLOCK macro 2021-10-29 16:44:21 -04:00
loc.h
macro.c
macro.h
public.h
read.c gdb: remove TYPE_FIELD_ENUMVAL 2021-10-29 16:44:45 -04:00
read.h CTF: incorrect underlying type setting for enumeration types 2021-10-18 14:15:21 -04:00
sect-names.h
section.c
section.h
stringify.c
stringify.h