public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Missing TO_ADDR
@ 2016-03-30  7:32 Alan Modra
  2016-03-30 12:08 ` Dan
       [not found] ` <1459339484.9097.134.camel@jericho>
  0 siblings, 2 replies; 9+ messages in thread
From: Alan Modra @ 2016-03-30  7:32 UTC (permalink / raw)
  To: binutils

Calculates the wrong end address on targets with octets_per_byte
not equal to one.

	* ldlang.c (lang_size_sections_1): Correct code detecting a
	backward non-overlapping move.

diff --git a/ld/ldlang.c b/ld/ldlang.c
index 235a246..b369f99 100644
--- a/ld/ldlang.c
+++ b/ld/ldlang.c
@@ -5068,7 +5068,7 @@ lang_size_sections_1
 		   create overlapping LMAs.  */
 		if (dot < last->vma
 		    && os->bfd_section->size != 0
-		    && dot + os->bfd_section->size <= last->vma)
+		    && dot + TO_ADDR (os->bfd_section->size) <= last->vma)
 		  {
 		    /* If dot moved backwards then leave lma equal to
 		       vma.  This is the old default lma, which might

-- 
Alan Modra
Australia Development Lab, IBM

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

end of thread, other threads:[~2016-04-08  5:16 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-30  7:32 Missing TO_ADDR Alan Modra
2016-03-30 12:08 ` Dan
     [not found] ` <1459339484.9097.134.camel@jericho>
2016-03-31  7:40   ` Alan Modra
2016-03-31 11:13     ` Dan
2016-04-01  1:28       ` Alan Modra
2016-03-31 16:03     ` Dan
2016-04-01  1:31       ` Alan Modra
2016-04-01 14:42         ` [PATCH] " Dan
2016-04-08  5:16           ` Alan Modra

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).