This is the mail archive of the binutils@sourceware.org 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: PATCH: ld/2338: objdump -d -l doesn't work correctly


On Fri, Mar 03, 2006 at 01:12:09PM +1030, Alan Modra wrote:
> On Tue, Feb 28, 2006 at 11:41:38AM -0800, H. J. Lu wrote:
> > @@ -803,6 +815,15 @@ add_line_info (struct line_info_table *t
> >        {
> >  	/* Abnormal but easy: lcl_head is 1) in the *middle* of the line
> >  	   list and 2) the head of 'info'.  */
> > +	if (address == table->lcl_head->prev_line->address
> > +	    && end_sequence != 0
> > +	    && table->lcl_head->end_sequence != 0
> > +	    && table->lcl_head->prev_line->end_sequence == 0)
> > +	  {
> > +	    /* If the new adress is the same, we need to make sure that
> > +	       the order of end_sequence is correct.  */
> > +	    table->lcl_head = table->lcl_head->prev_line;
> > +	  }
> >  	info->prev_line = table->lcl_head->prev_line;
> >  	table->lcl_head->prev_line = info;
> >  	break;
> 
> Convince me that this is correct.  ie. that you have actually done some
> analysis and that this is the only place in add_line_info that needs to
> do something special with end_sequence.

We can only 2 lines pointing to the same address: one is end_sequence
and the other isn't. That is the only place where it can happen.



H.J.


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