binutils-gdb/include
Tamar Christina 53b2f36bf6 AArch64: Fix disassembler bug with out-of-order sections
The AArch64 disassembler has an optimization that it uses to reduce the amount
it has to search for mapping symbols during disassembly.  This optimization
assumes that sections are listed in the section header in monotonic increasing
VMAs.  However this is not a requirement for the ELF specification.

Because of this when such "out of order" sections occur the disassembler would
pick the wrong mapping symbol to disassemble the section with.

This fixes it by explicitly passing along the stop offset for the current
disassembly glob and when this changes compared to the previous one we've seen
the optimization won't be performed.  In effect this restarts the search from
a well defined starting point.  Usually the symbol's address.

The existing stop_vma can't be used for this as it is allowed to be unset and
setting this unconditionally would change the semantics of this field.

binutils/ChangeLog:

	* objdump.c (disassemble_bytes): Pass stop_offset.
	* testsuite/binutils-all/aarch64/out-of-order.T: New test.
	* testsuite/binutils-all/aarch64/out-of-order.d: New test.
	* testsuite/binutils-all/aarch64/out-of-order.s: New test.

include/ChangeLog:

	* dis-asm.h (struct disassemble_info): Add stop_offset.

opcodes/ChangeLog:

	* aarch64-dis.c (last_stop_offset): New.
	(print_insn_aarch64): Use stop_offset.
2019-03-25 15:05:53 +00:00
..
aout Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
cgen Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
coff PR24272, out-of-bounds read in pex64_xdata_print_uwd_codes 2019-03-01 13:30:38 +10:30
elf [BFD, LD, AArch64, 3/3] Add --pac-plt to enable PLTs protected with PAC. 2019-03-13 11:47:33 +00:00
gdb Update copyright year range in all GDB files. 2019-01-01 10:01:51 +04:00
mach-o Use the correct name for various MACH-O based operating systems in comments. 2019-02-15 12:50:52 +00:00
opcode S/390: Implement instruction set extensions 2019-01-31 17:32:18 +01:00
som Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
vms Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
COPYING Update the address and phone number of the FSF organization 2005-05-10 10:21:13 +00:00
COPYING3 * COPYING3: New file. Contains version 3 of the GNU General Public License. 2007-07-17 13:50:23 +00:00
ChangeLog AArch64: Fix disassembler bug with out-of-order sections 2019-03-25 15:05:53 +00:00
ChangeLog-0415 binutils ChangeLog rotation 2016-01-01 22:59:17 +10:30
ChangeLog-2016 ChangeLog rotation 2017-01-02 13:55:05 +10:30
ChangeLog-2017 ChangeLog rotation 2018-01-03 17:49:42 +10:30
ChangeLog-2018 ChangeLog rotation 2019-01-01 21:25:40 +10:30
ChangeLog-9103 Add copyright notices 2012-12-10 12:48:03 +00:00
MAINTAINERS Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
alloca-conf.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
ansidecl.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
bfdlink.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
binary-io.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
bout.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
demangle.h Sync libiberty sources with gcc master versions. 2019-01-10 09:44:13 +00:00
diagnostics.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
dis-asm.h AArch64: Fix disassembler bug with out-of-order sections 2019-03-25 15:05:53 +00:00
dwarf2.def Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
dwarf2.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
dyn-string.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
environ.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
fibheap.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
filenames.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
floatformat.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
fnmatch.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
fopen-bin.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
fopen-same.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
fopen-vms.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
gcc-c-fe.def Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
gcc-c-interface.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
gcc-cp-fe.def Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
gcc-cp-interface.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
gcc-interface.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
getopt.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
hashtab.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
hp-symtab.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
leb128.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
libiberty.h Merge from gcc: use "cannot" instead of "can not" in libiberty and include. 2019-01-09 13:59:16 -08:00
longlong.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
lto-symtab.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
md5.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
oasys.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
objalloc.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
obstack.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
os9k.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
partition.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
plugin-api.h Merge from gcc: use "cannot" instead of "can not" in libiberty and include. 2019-01-09 13:59:16 -08:00
progress.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
safe-ctype.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
sha1.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
simple-object.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
sort.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
splay-tree.h Fix splay tree KEY leak detected in GDB test gdb.base/macscp.exp 2019-02-12 06:06:19 -07:00
symcat.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
timeval-utils.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
vtv-change-permission.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
xregex.h merge from gcc 2011-07-25 17:11:48 +00:00
xregex2.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
xtensa-config.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
xtensa-isa-internal.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30
xtensa-isa.h Update year range in copyright notice of binutils files 2019-01-01 22:06:53 +10:30