This is the mail archive of the mailing list for the binutils project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Regressions in gas test-suite results with your recent dwarf fixes

Hi Hans-Peter,

With one of your recent dwarf-related commits (either 03a91817f16 or
77ef86547510c), I see regressions for cris-elf and cris-linux;
these FAILs where there should be none:

Running /tmp/hpautotest-binutils/bsrc/src/gas/testsuite/gas/cris/cris.exp ...
FAIL: gas/cris/rd-dw2-11
FAIL: gas/cris/rd-dw2-2
FAIL: gas/cris/rd-dw2-4
FAIL: gas/cris/rd-dw2-5
FAIL: gas/cris/rd-dw2-7
FAIL: gas/cris/rd-dw2-8
FAIL: gas/cris/rd-dw2-9

I had a quick look to handle any quick adjustment to tweaked
output format, but the displayed location information is-like
displayed or generated modulo 32768 or something.  Looking at
the disassembly, the actual code (and the location) is as

I am very sorry about this. Your are correct - there was a bug in the code in read_leb128 that was meant to check for an unterminated leb128 number. I have now checked in the patch below to fix this.


2015-02-13  Nick Clifton  <>

	* dwarf.c (read_leb128): Fix test for shift becoming too large.

diff --git a/binutils/dwarf.c b/binutils/dwarf.c
index dad381f..936f634 100644
--- a/binutils/dwarf.c
+++ b/binutils/dwarf.c
@@ -284,7 +284,7 @@ read_leb128 (unsigned char *data,

       /* PR 17512: file: 0ca183b8.
 	 FIXME: Should we signal this error somehow ?  */
-      if (shift >= sizeof (result))
+      if (shift >= sizeof (result) * 8)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]