diff options
author | Alan Modra <amodra@gmail.com> | 2023-08-22 07:31:03 +0930 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2023-08-22 09:35:55 +0930 |
commit | 5bf26ab7cb82c2e6308b269af44b989a51ee7903 (patch) | |
tree | 04c8ace52d334b14faebc2a822971d2644215f75 /gdb/ui-out.c | |
parent | fddbba54a4b8224c848010048102ddcdbae1ec78 (diff) | |
download | binutils-5bf26ab7cb82c2e6308b269af44b989a51ee7903.zip binutils-5bf26ab7cb82c2e6308b269af44b989a51ee7903.tar.gz binutils-5bf26ab7cb82c2e6308b269af44b989a51ee7903.tar.bz2 |
kvx_dis_init
kvx_dis_init currently always returns true, but error conditions do so
by "return -1" which converts to true. The return status is ignored
anyway, and it doesn't make much sense to error on unexpected arch or
mach: If print_insn_kvx is called then the atch is known to be kvx,
and it's better to choose some default for a user passing an unknown
mach value rather than segfaulting in decode_insn when env.opc_table
is NULL.
I've chosen the default mach to be bfd_mach_kv3_1, the default in
bfd/cpu-kvx.c, not that it matters very much. In normal objdump/gdb
usage, info->mach won't be an unexpected value.
* kvx-dis.c (kvx_dis_init): Return void. Don't error on
unexpected arch or mach. Default to bfd_mach_kv3_1 for
unknown mach. Don't clear info->disassembler_options.
Diffstat (limited to 'gdb/ui-out.c')
0 files changed, 0 insertions, 0 deletions