public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] Fix for failures in mips gas tests due to discriminator change
@ 2012-07-26  2:26 Teresa Johnson
  2012-07-26 13:30 ` Alan Modra
  0 siblings, 1 reply; 3+ messages in thread
From: Teresa Johnson @ 2012-07-26  2:26 UTC (permalink / raw)
  To: Hans-Peter Nilsson; +Cc: binutils

Missing initialization caused failures for the mips target.

Tested for mipsisa32r2el-unknown-linux-gnu. Ok for trunk?

Thanks,
Teresa

2012-07-25  Teresa Johnson  <tejohnson@google.com>

        * bfd/dwarf2.c (find_line): Initialize discriminator_ptr
        if it is non-NULL.

Index: bfd/dwarf2.c
===================================================================
RCS file: /cvs/src/src/bfd/dwarf2.c,v
retrieving revision 1.149
diff -u -p -r1.149 dwarf2.c
--- bfd/dwarf2.c        24 Jul 2012 21:06:57 -0000      1.149
+++ bfd/dwarf2.c        26 Jul 2012 02:13:43 -0000
@@ -3344,6 +3344,8 @@ find_line (bfd *abfd,
   if (functionname_ptr != NULL)
     *functionname_ptr = NULL;
   *linenumber_ptr = 0;
+  if (discriminator_ptr)
+    *discriminator_ptr = 0;

   if (! _bfd_dwarf2_slurp_debug_info (abfd, NULL,
                                      debug_sections, symbols, pinfo))



On Wed, Jul 25, 2012 at 4:22 PM, Hans-Peter Nilsson
<hans-peter.nilsson@axis.com> wrote:
>
> My autotester complains, for mipsisa32r2el-unknown-linux-gnu
> cross from a x86_64-linux host:
>
> Running /tmp/hpautotest-binutils/bsrc/src/gas/testsuite/gas/mips/mips.exp ...
> FAIL: assembly line numbers
>
> The time this regression started
> (2012-07-24-13:49:25..2012-07-24-21:07:06 UTC), seems to
> coincide with your line number patch:
>
> 2012-07-24  Teresa Johnson  <tejohnson@google.com>
>
>         * addr2line.c (find_address_in_section): Invoke
>         bfd_find_nearest_line_discriminator to get the discriminator.
>         (find_offset_in_section): Likewise.
>         (translate_addresses): Print discriminator if it is non-zero.
>         * objdump.c (show_line): Invoke
>         bfd_find_nearest_line_discriminator to get the discriminator,
>         and keep track of prev_discriminator. Print discriminator
>         if it is non-zero.
>         (disassemble_data): Initialize prev_discriminator.
>         (dump_reloc_set): Invoke bfd_find_nearest_line_discriminator
>         to get the discriminator, and keep track of last_discriminator.
>         Print discriminator if it is non-zero.
>
> Please look into it.  Thanks.
>
> brgds, H-P




--
Teresa Johnson | Software Engineer | tejohnson@google.com | 408-460-2413

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Fix for failures in mips gas tests due to discriminator change
  2012-07-26  2:26 [PATCH] Fix for failures in mips gas tests due to discriminator change Teresa Johnson
@ 2012-07-26 13:30 ` Alan Modra
  2012-07-26 18:22   ` Cary Coutant
  0 siblings, 1 reply; 3+ messages in thread
From: Alan Modra @ 2012-07-26 13:30 UTC (permalink / raw)
  To: Teresa Johnson; +Cc: Hans-Peter Nilsson, binutils

On Wed, Jul 25, 2012 at 07:25:33PM -0700, Teresa Johnson wrote:
>         * bfd/dwarf2.c (find_line): Initialize discriminator_ptr
>         if it is non-NULL.

OK.

-- 
Alan Modra
Australia Development Lab, IBM

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Fix for failures in mips gas tests due to discriminator change
  2012-07-26 13:30 ` Alan Modra
@ 2012-07-26 18:22   ` Cary Coutant
  0 siblings, 0 replies; 3+ messages in thread
From: Cary Coutant @ 2012-07-26 18:22 UTC (permalink / raw)
  To: Teresa Johnson, Hans-Peter Nilsson, binutils

>>         * bfd/dwarf2.c (find_line): Initialize discriminator_ptr
>>         if it is non-NULL.
>
> OK.

Thanks, I've committed this for Teresa.

-cary

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-07-26 18:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-26  2:26 [PATCH] Fix for failures in mips gas tests due to discriminator change Teresa Johnson
2012-07-26 13:30 ` Alan Modra
2012-07-26 18:22   ` Cary Coutant

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).