This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: Possible binutils wide output regression
- From: Carlos O'Donell <carlos_odonell at mentor dot com>
- To: Nick Clifton <nickc at redhat dot com>
- Cc: binutils <binutils at sourceware dot org>
- Date: Wed, 5 Oct 2011 10:07:48 -0400
- Subject: Re: Possible binutils wide output regression
- References: <4E8C2309.8010008@redhat.com>
On 10/5/2011 5:27 AM, Nick Clifton wrote:
> Hi Carlos,
>
> My binutils regression tester has turned up the following new failures:
>
> Checking Binutils in: alpha-unknown-osf4.0 ... GAS: 2 LD: 1 BIN: 7 done
> BIN ERROR: /work/sources/binutils/current/binutils/testsuite/binutils-all/dw2-decodedline.S: assembly failed
> BIN REGRESSION: objdump -WL (reason: unexpected output)
> BIN REGRESSION: objdump -WL
>
> Checking Binutils in: arm-aout ... GAS: 54 BIN: 4 done
> BIN ERROR: /work/sources/binutils/current/binutils/testsuite/binutils-all/dw2-decodedline.S: assembly failed
> BIN REGRESSION: objdump -WL (reason: unexpected output)
> BIN REGRESSION: objdump -WL
>
>
> Checking Binutils in: arm-epoc-pe ... GAS: 2 LD: 6 BIN: 6 done
> BIN ERROR: /work/sources/binutils/current/binutils/testsuite/binutils-all/dw2-decodedline.S: assembly failed
> BIN REGRESSION: objdump -WL (reason: unexpected output)
> BIN REGRESSION: objdump -WL
>
> etc. I suggest a fix like the attached. Do you agree ?
Yes, this is exactly what I was asking in my patch submission email.
Sorry, I should have brought the question up again when you ACK'd the
the patch but didn't answer the question.
For non-elf targets we probably want to avoid this test as is done
with the previous objdump dwarf2 test?
> Index: binutils/testsuite/binutils-all/objdump.exp
> ===================================================================
> RCS file: /cvs/src/src/binutils/testsuite/binutils-all/objdump.exp,v
> retrieving revision 1.28
> diff -u -3 -p -r1.28 objdump.exp
> --- binutils/testsuite/binutils-all/objdump.exp 4 Oct 2011 14:25:40 -0000 1.28
> +++ binutils/testsuite/binutils-all/objdump.exp 5 Oct 2011 09:25:07 -0000
> @@ -204,28 +204,32 @@ if { ![is_elf_format] } then {
>
> # Test objdump -WL on a file that contains line information for multiple files and search directories.
>
> -if { ![binutils_assemble $srcdir/$subdir/dw2-decodedline.S tmpdir/dw2-decodedline.o] } then {
> - fail "objdump decoded line"
> -}
> -
> -if [is_remote host] {
> - set decodedline_testfile [remote_download host tmpdir/dw2-decodedline.o]
> +if { ![is_elf_format] } then {
> + unsupported "objump decode line"
> } else {
> - set decodedline_testfile tmpdir/dw2-decodedline.o
> -}
> + if { ![binutils_assemble $srcdir/$subdir/dw2-decodedline.S tmpdir/dw2-decodedline.o] } then {
> + fail "objdump decoded line"
> + }
>
> -set got [remote_exec host "$OBJDUMP $OBJDUMPFLAGS -WL $decodedline_testfile" "" "/dev/null" "objdump.out"]
> + if [is_remote host] {
> + set decodedline_testfile [remote_download host tmpdir/dw2-decodedline.o]
> + } else {
> + set decodedline_testfile tmpdir/dw2-decodedline.o
> + }
>
> -if { [lindex $got 0] != 0 || ![string match "" [lindex $got 1]] } then {
> - fail "objdump -WL (reason: unexpected output)"
> - send_log $got
> - send_log "\n"
> -}
> + set got [remote_exec host "$OBJDUMP $OBJDUMPFLAGS -WL $decodedline_testfile" "" "/dev/null" "objdump.out"]
>
> -if { [regexp_diff objdump.out $srcdir/$subdir/objdump.WL] } then {
> - fail "objdump -WL"
> -} else {
> - pass "objdump -WL"
> + if { [lindex $got 0] != 0 || ![string match "" [lindex $got 1]] } then {
> + fail "objdump -WL (reason: unexpected output)"
> + send_log $got
> + send_log "\n"
> + }
> +
> + if { [regexp_diff objdump.out $srcdir/$subdir/objdump.WL] } then {
> + fail "objdump -WL"
> + } else {
> + pass "objdump -WL"
> + }
> }
>
> # Options which are not tested: -a -d -D -R -T -x -l --stabs
Looks good to me.
Cheers,
Carlos.
--
Carlos O'Donell
Mentor Graphics / CodeSourcery
carlos@codesourcery.com
+1 (613) 963 1026