Bug 144 - gas creates unaligned relocations in .debug_line section
Summary: gas creates unaligned relocations in .debug_line section
Status: RESOLVED FIXED
Alias: None
Product: binutils
Classification: Unclassified
Component: gas (show other bugs)
Version: 2.15
: P2 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-05-03 16:58 UTC by Rainer Orth
Modified: 2007-12-05 23:51 UTC (History)
1 user (show)

See Also:
Host: sparc-sun-solaris2.8
Target: sparc-sun-solaris2.8
Build: sparc-sun-solaris2.8
Last reconfirmed:


Attachments
patch against 2.17 (614 bytes, patch)
2007-11-22 19:34 UTC, Andrew Dixie
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Rainer Orth 2004-05-03 16:58:08 UTC
As described in GCC PR target/15267

  http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15267

and analysed further in

  http://gcc.gnu.org/ml/gcc-patches/2004-04/msg01791.html

gas 2.14.91 (and 2.14) create unaligned relocations that the native Solaris 8
linker cannot cope with.  This breaks GCC bootstrap when using gas, but not gld.
Comment 1 Andrew Dixie 2007-11-22 19:34:16 UTC
Created attachment 2105 [details]
patch against 2.17

I don't know how to structure the patch properly for binutils standards and
portability.
Atleast it show's where the issue is coming from.
Comment 2 Nick Clifton 2007-11-28 12:49:31 UTC
Hi Andrew,

  Does the problem still exist with an assembler built from the current head of
the binutils sources in the CVS repository ?  (I suspect that it does, but I
would like this confirmed and there does not seem to be a simple test case
available).

  Thanks very much for suggesting a patch.  It does look OK, but there is one
problem - you only provide definitions of the TC_BEGIN_UNALIGNED and
TC_END_UNALIGNED macros for the sparc target.  Building for any other target
will result in a compile time error for the undefined macros.  Please could you
supply a revised patch that corrects this ?

  It would also help to know how you tested the patch.  Did you run the gas
testsuite after building a toolchain with the patch applied ?  If so, were there
any regressions ?

Cheers
  Nick
Comment 3 Andrew Dixie 2007-12-05 23:46:23 UTC
(In reply to comment #2)
>   Does the problem still exist with an assembler built from the current head 
of
> the binutils sources in the CVS repository ? 

Actually no it doesn't, was fixed by:
http://www.cygwin.com/ml/binutils/2006-11/msg00290.html