• R/O
  • HTTP
  • SSH
  • HTTPS

List of commits

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

GNU Binutils with patches for OS216


All branches
RSS
Rev. Time Author
8c190ce 2020-06-29 22:28:46 H.J. Lu

x86: Support VEX base opcode length > 1

Intel AMX instructions with 8-bit immediate opcode extension without
operands:

tilerelease, 0, 0x49c0, None, 2, CpuAMX_TILE|Cpu64, Vex|VexOpcode=1|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { 0 }

Update build_vex_prefix to support VEX base opcode length > 1.

* tc-i386.c (build_vex_prefix): Support VEX base opcode length > 1.
(md_assemble): Don't process ImmExt without operands.

a57f74b 2020-06-29 21:53:01 H.J. Lu

tic6x: Call _bfd_elf_add_dynamic_tags

Update tic6x linker tests to expect C6000_DSBT_BASE, C6000_DSBT_SIZE and
C6000_DSBT_INDEX dynamic tags immediately before NULL dynamic tag.

bfd/

* elf32-tic6x.c (elf32_tic6x_size_dynamic_sections): Call
_bfd_elf_add_dynamic_tags.

ld/

* testsuite/ld-tic6x/shlib-1.rd: Move C6000_DSBT_BASE,
C6000_DSBT_SIZE and C6000_DSBT_INDEX dynamic tags to the last.
* testsuite/ld-tic6x/shlib-1b.rd: Likewise.
* testsuite/ld-tic6x/shlib-1r.rd: Likewise.
* testsuite/ld-tic6x/shlib-1rb.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1b.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1r.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1rb.rd: Likewise.
* testsuite/ld-tic6x/shlib-noindex.rd: Likewise.
* testsuite/ld-tic6x/static-app-1.rd: Likewise.
* testsuite/ld-tic6x/static-app-1b.rd: Likewise.
* testsuite/ld-tic6x/static-app-1r.rd: Likewise.
* testsuite/ld-tic6x/static-app-1rb.rd: Likewise.

a3ca48c 2020-06-29 20:59:19 Tom de Vries

[gdb/testsuite] Emit unresolved for unknown proc

Since commit 26783bce15 "[gdb/testsuite] Don't abort testrun for invalid
command in test-case" we don't abort the testrun when encountering an invalid
command. However, since we don't report errors in the summary, there's a
chance that the error goes unnoticed.

Make the invalid command error more visible by marking the test-case
unresolved, such that we have f.i.:
...
PASS: gdb.python/py-breakpoint.exp: test_bkpt_internal: Test watchpoint write
UNRESOLVED: gdb.python/py-breakpoint.exp: test_bkpt_eval_funcs: \
testcase aborted due to invalid command name: gdb_py_test_multiple
ERROR: tcl error sourcing py-breakpoint.exp.
ERROR: invalid command name "gdb_py_test_multiple"
while executing
...
=== gdb Summary ===

nr of expected passes 56
nr of unresolved testcases 1
...

Tested on x86_64-linux.

gdb/testsuite/ChangeLog:

2020-06-29 Tom de Vries <tdevries@suse.de>

* lib/gdb.exp (unknown): Make test-case unresolved.

f638ed7 2020-06-29 19:14:10 Tom de Vries

[gdbserver] Add missing include of gdbsupport/agent.h

The file gdbserver/ax.h contains:
...
#ifdef IN_PROCESS_AGENT
#define debug_threads debug_agent
#endif
...
but does not declare debug_agent.

Fix this by adding an include of gdbsupport/agent.h.

[ If this fix would have been in place before commit 8118159c69 "[gdbserver] Fix
Wlto-type-mismatch for debug_agent", we would have simply run into this build
breaker with a regular, non-lto build:
...
src/gdbserver/ax.cc:28:5: error: conflicting declaration 'int debug_agent'
int debug_agent = 0;
^~~~~~~~~~~
In file included from src/gdbserver/ax.h:25:0,
from src/gdbserver/ax.cc:20:
src/gdbsupport/agent.h:47:13: note: previous declaration as 'bool debug_agent'
extern bool debug_agent;
^~~~~~~~~~~
... ]

Tested on x86_64-linux.

gdbserver/ChangeLog:

2020-06-29 Tom de Vries <tdevries@suse.de>

* ax.h: Include gdbsupport/debug_agent.h.

b0237c0 2020-06-29 18:02:06 Tom de Vries

[gdb/testsuite] Expect conformation question in gdb.server/solib-list.exp

Before commit a8654e7d78 'Fixes PR 25475: ensure exec-file-mismatch "ask"
always asks in case of mismatch', there was a difference in behaviour in
test-case gdb.server/solib-list.exp.

If the executable did not contain debug info (as is usually the case), gdb
would detect a mismatch but not ask for confirmation:
...
(gdb) target remote localhost:2346^M
Remote debugging using localhost:2346^M
warning: Mismatch between current exec-file solib-list^M
and automatically determined exec-file /lib64/ld-2.26.so^M
exec-file-mismatch handling is currently "ask"^M
Reading symbols from /lib64/ld-2.26.so...^M
Reading symbols from /usr/lib/debug/lib64/ld-2.26.so.debug...^M
0x00007ffff7dd7ea0 in _start () at rtld.c:745^M
745 }^M
(gdb) PASS: gdb.server/solib-list.exp: non-stop 0: target remote
...

If the executable did contain debug info (as happens to be the case for
openSUSE), gdb would detect a mismatch and ask for confirmation:
...
(gdb) PASS: gdb.server/solib-list.exp: non-stop 0: file binfile
target remote localhost:2346^M
Remote debugging using localhost:2346^M
warning: Mismatch between current exec-file solib-list^M
and automatically determined exec-file /lib64/ld-2.26.so^M
exec-file-mismatch handling is currently "ask"^M
Load new symbol table from "/lib64/ld-2.26.so"? (y or n) y^M
Reading symbols from /lib64/ld-2.26.so...^M
Reading symbols from /usr/lib/debug/lib64/ld-2.26.so.debug...^M
0x00007ffff7dd7ea0 in _start () at rtld.c:745^M
745 }^M
(gdb) PASS: gdb.server/solib-list.exp: non-stop 0: target remote
...

After commit a8654e7d78, the confirmation is now also asked in case there's
no debug info.

Tighten the test-case by verifying that the confirmation question is asked, as
suggested in the log message of commit a8654e7d78:
...
we can remove the bypass introduced by Tom in 6b9374f1, in order to always
answer to the 'load' question.
...

gdb/testsuite/ChangeLog:

2020-06-29 Tom de Vries <tdevries@suse.de>

PR gdb/25475
* gdb.server/solib-list.exp: Verify that the symbol reload
confirmation question is asked.

4e394b2 2020-06-29 12:38:26 Hans-Peter Nilsson

gas/testsuite: test-case for PR25331 (mmix reloc fixup bug)

The bug manifested "only" for a 64-bit host:

pr25331.c: Assembler messages:
pr25331.c:430: Error: internal error: fixup not contained within frag
failed with: <pr25331.c: Assembler messages:
pr25331.c:430: Error: internal error: fixup not contained within frag>, no expected output
FAIL: gas/mmix/pr25331

gas:
PR gas/25331
* testsuite/gas/mmix/pr25331.d, testsuite/gas/mmix/pr25331.s: New test.

b20e761 2020-06-29 12:32:02 Hans-Peter Nilsson

gas: Fix mmix fixups and TC_FX_SIZE_SLACK, PR25331

Finally; sorry for the delay. There were a few false starts, where I
misinterpreted the error-messages and the comment that Alan added:
it's not the fix size that's too large (and the frag too small), it's
stating the wrong size of what will be "fixed up" - that of the actual
target value, not the size of the field that needs to be adjusted.
Comments added for clarity.

Test-suite committed separately.

gas:
PR gas/25331
* config/tc-mmix.c (md_assemble) <fixup for
BFD_RELOC_MMIX_BASE_PLUS_OFFSET>: This fixup affects 1 byte, not 8.
Also, set its fx_no_overflow.
(md_convert_frag) <case ENCODE_RELAX (STATE_PUSHJSTUB, STATE_ZERO)>:
Similarly this fixup affects 4 bytes, not 8 and needs its
fx_no_overflow set.
* config/tc-mmix.h (TC_FX_SIZE_SLACK): Don't define.

9f27c36 2020-06-29 10:50:45 Hans-Peter Nilsson

binutils/dwarf.c: Correct an `index' global shadowing error for pre-4.8 GCC

In older gcc, shadowing a function name with a local variable name is
flagged as an error, certainly a bug but which is usually worked
around in binutils:

gcc -DHAVE_CONFIG_H -I. -I$SRC/binutils -I. -I$SRC/binutils -I../bfd -I$SRC/binutils/../bfd -I$SRC/binutils/../include -DLOCALEDIR="\"/usr/local/share/locale\"" -Dbin_dummy_emulation=bin_vanilla_emulation -W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Werror -I$SRC/binutils/../zlib -g -O2 -MT dwarf.o -MD -MP -MF $depbase.Tpo -c -o dwarf.o $SRC/binutils/dwarf.c &&\
mv -f $depbase.Tpo $depbase.Po
cc1: warnings being treated as errors
$SRC/binutils/dwarf.c: In function 'display_debug_str_offsets':
$SRC/binutils/dwarf.c:6913: error: declaration of 'index' shadows a global declaration
/usr/include/string.h:309: error: shadowed declaration is here
make[4]: *** [dwarf.o] Error 1

See also GCC PR c/53066. This is just another one that crept in since
I and others last had to use an old version. The name "idx" was used
in the preceding function, display_debug_addr. Also, it was declared
c99 style (after a statement in the block). Committed as obvious.

binutils:
* dwarf.c (display_debug_str_offsets): Rename local variable
index to idx. Move to top of function.

07d22f6 2020-06-29 09:39:14 Alan Modra

asan: _bfd_pei_slurp_codeview_record use of uninit value

Fixes some seriously careless code. bfd_bread return value is
(bfd_size_type)-1 on error. "if (bfd_bread (...) < 4)" does not check
for an error since bfd_size_type is unsigned. In any case, I think we
should be reading and checking the requested length.

* peXXigen.c (_bfd_XXi_slurp_codeview_record): Properly check
return value of bfd_bread. Don't read more than requested length.
Sanity check length. Properly terminate file name.

279edac 2020-06-29 09:37:56 Alan Modra

C++ comments

binutils isn't c99 (yet). This replaces or removes some C++ style
comments.

bfd/
* arc-got.h: Use C style comments.
* coff-z80.c: Likewise.
* elf32-csky.c: Likewise.
* peXXigen.c: Likewise.
* elf32-m32c.c (m32c_elf_relax_delete_bytes): Remove commented out
code.
binutils/
* dwarf.c: Use C style comments.
* resrc.c: Likewise.
gas/
* config/tc-s12z.c: Use C style comments.
* config/tc-z80.c: Likewise.
* config/tc-xtensa.c (emit_ld_r_n): Remove commented out code.
include/
* coff/internal.h: Use C style comments.
* coff/pe.h: Likewise.
* elf/ppc64.h: Likewise.
opcodes/
* arm-dis.c: Use C style comments.
* cr16-opc.c: Likewise.
* ft32-dis.c: Likewise.
* moxie-opc.c: Likewise.
* tic54x-dis.c: Likewise.
* s12z-opc.c: Remove useless comment.
* xgate-dis.c: Likewise.

290a25d 2020-06-29 09:34:11 Alan Modra

x86_64 k1om tests

On x86_64-nacl we currently see
FAIL: Absolute non-overflowing relocs
FAIL: ld-x86-64/protected2-k1om
FAIL: ld-x86-64/protected3-k1om

This limits the tests as per the l1om variants.

* testsuite/ld-x86-64/abs-k1om.d: Run only on x86_64-*-linux*.
* testsuite/ld-x86-64/protected2-k1om.d: Likewise.
* testsuite/ld-x86-64/protected3-k1om.d: Likewise.

a874159 2020-06-29 09:00:32 GDB Administrator

Automatic date update in version.in

3398d49 2020-06-29 09:00:20 GDB Administrator

Automatic date update in version.in

ffdbed0 2020-06-29 09:00:07 GDB Administrator

Automatic date update in version.in

cd4c4c0 2020-06-29 01:33:07 Tom Tromey

Remove "cmd_type" function

The cmd_type function only has a single caller, which is in the CLI
implementation code. This patch removes the function, and moves the
cmd_types enum definition from command.h to cli-decode.h, fixing an 18
year old FIXME.

gdb/ChangeLog
2020-06-28 Tom Tromey <tom@tromey.com>

* command.h (cmd_types): Remove.
(cmd_type): Don't declare.
* cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
typedef.
* cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
* cli/cli-decode.c (cmd_type): Remove.

02f96bb 2020-06-28 09:00:44 GDB Administrator

Automatic date update in version.in

c8e03e2 2020-06-28 09:00:29 GDB Administrator

Automatic date update in version.in

a5122bf 2020-06-28 09:00:07 GDB Administrator

Automatic date update in version.in

6db3031 2020-06-28 03:39:00 Simon Marchi

gdbsupport: add format attribute to print_xml_feature::add_line

Fixes this clang error:

CXX tdesc.o
/home/smarchi/src/binutils-gdb/gdbsupport/tdesc.cc:444:25: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
string_vappendf (tmp, fmt, ap);
^~~

There is already a but about GCC not emitting this warning:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82206

gdbsupport/ChangeLog:

* tdesc.h (class print_xml_feature) <add_line>: Add
ATTRIBUTE_PRINTF.

Change-Id: I7014075e83717f6d7e19d044a3675ff9981ebe17

05779d5 2020-06-27 22:56:05 Pedro Alves

Make {get,set}_inferior_io_terminal inferior methods

This converts the get_inferior_io_terminal and
set_inferior_io_terminal free functions to inferior methods.

Since the related commands are called "tty", "{set,show}
inferior-tty", and MI's "-inferior-tty-{set,show}", to make the
connection between the commands and the code more obvious, the methods
are named set_tty/tty instead of set_io_terminal/io_terminal.

gdb/ChangeLog:

* fork-child.c (prefork_hook): Adjust.
* infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
Delete.
(set_inferior_tty_command, show_inferior_tty_command): Adjust.
* inferior.c (inferior::set_tty, inferior::tty): New methods.
* inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
Remove declarations.
(struct inferior) <set_tty, tty>: New methods.
(struct inferior) <terminal>: Rename to ...
(struct inferior) <m_terminal>: ... this and make private.
* main.c (captured_main_1): Adjust.
* mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
(mi_cmd_inferior_tty_show): Adjust.
* nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
* windows-nat.c (windows_nat_target::create_inferior): Adjust.

cfc1677 2020-06-27 12:25:35 Alan Modra

asan: readelf: use after free in process_archive

This tidies up in cases where fuzzed thin archives hit the error return
path in setup_nested_archive.

* elfcomm.c (setup_nested_archive): Set nested_arch->file to NULL
after freeing.
(release_archive): Set fields of arch to NULL after freeing.

1ceaaa7 2020-06-27 09:00:45 GDB Administrator

Automatic date update in version.in

96470ba 2020-06-27 09:00:28 GDB Administrator

Automatic date update in version.in

aa57a9d 2020-06-27 09:00:06 GDB Administrator

Automatic date update in version.in

c0b3b3b 2020-06-27 05:04:46 Philippe Waroquiers

Make test names unique in python.exp and guile.exp

Version 2, handles the comments of Simon and Pedro.

Note that gdb_test_multiline and gdb_py_test_multiple are using
the "input line" as the test name, and so when there is a duplicated
input line (such as a line containing "end"), we have duplicated test
names => as gdb_test_multiline and gdb_py_test_multiple are identical,
as indicated in FIXME, move this to gdb.exp, and make the test name unique
by adding the inputnr to the pass message for each input.

2020-06-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>

* lib/gdb.exp (gdb_test_multiline): New, moved from gdb-guile.exp,
have a input seq nr in each pass message.
* lib/gdb-guile.exp (gdb_test_multiline): Move to gdb.exp.
* lib/gdb-python.exp (gdb_py_test_multiple): Remove.
* gdb.python/python.exp: Make test names unique,
use gdb_test_multiline instead of gdb_py_test_multiple,
use $gdb_test_name.
* gdb.guile/guile.exp: Make test names unique, use $gdb_test_name

b6cd5d1 2020-06-27 02:25:12 H.J. Lu

x86: Process ImmExt without operands

To support Intel AMX instructions with 8-bit immediate opcode extension,
but without operands:

tilerelease, 0, 0x49, 0xc0, 1, CpuAMX_TILE|Cpu64, Vex|VexOpcode=1|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf|ImmExt, { 0 }

process ImmExt without operands.

* config/tc-i386.c (md_assemble): Process ImmExt without
operands.

e978ad6 2020-06-27 01:24:19 H.J. Lu

i386-opc.tbl: Add a blank line

* i386-opc.tbl: Add a blank line.

79b32e7 2020-06-27 01:20:28 H.J. Lu

x86: Correct VexSIB128 to VecSIB128

63112cd 2020-06-27 00:24:44 H.J. Lu

x86: Rename VecSIB to SIB for Intel AMX

Rename VecSIB to SIB to support Intel Advanced Matrix Extensions which
introduces instructions with a mandatory SIB byte which isn't a vector
SIB (VSIB).

gas/

* config/tc-i386.c (check_VecOperands): Replace vecsib with sib.
Replace VecSIB128, VecSIB256 and VecSIB512 with VECSIB128,
VECSIB256 and VECSIB512, respectively.
(build_modrm_byte): Replace vecsib with sib.

opcodes/

* i386-gen.c (opcode_modifiers): Replace VecSIB with SIB.
(VecSIB128): Renamed to ...
(VECSIB128): This.
(VecSIB256): Renamed to ...
(VECSIB256): This.
(VecSIB512): Renamed to ...
(VECSIB512): This.
(VecSIB): Renamed to ...
(SIB): This.
(i386_opcode_modifier): Replace vecsib with sib.
* i386-opc.tbl (VexSIB128): New.
(VecSIB256): Likewise.
(VecSIB512): Likewise.
Replace VecSIB=1, VecSIB=2 and VecSIB=3 with VexSIB128, VecSIB256
and VecSIB512, respectively.

8e6635b 2020-06-26 23:56:39 Nick Alcock

libctf: support platforms with separate libintl

We were not using the right configure machinery to spot libintl on
platforms where it was required, leading to the spurious failure of
various configure tests (e.g. for things like ELF support in BFD).

libctf/
* aclocal.m4: Add config/gettext-sister.m4: Shuffle into
alphabetical order.
* configure.ac: Add ZW_GNU_GETTEXT_SISTER_DIR.
* config.h.in: Regenerated.
* Makefile.in: Likewise.
* configure: Likewise.