Until today the implementation of binutils for the AVR architecture did not
support 8-bit relocations. This means that constructs like counted strings:

.byte 2f-1f
1: .ascii "blah"
2:

were impossible, because GAS would tell me "illegal relocation size: 1". The
above example works fine on almost every other supported architecture.

The attached patch implements support for BFD_RELOC_8 relocation type in
binutils, and for the respective R_AVR_8 relocation type in avr-elf32. Both
relocations that are resolved at assembly time as well as link-time applied
relocations work.

Also attaching a simple testcase which should assemle fine with the patch
applied, and will emit two errors without the patch applied.

-- 
           Summary: Support for 8-bit relocations for AVR architecture
           Product: binutils
           Version: 2.18
            Status: NEW
          Severity: normal
          Priority: P2
         Component: binutils
        AssignedTo: unassigned at sources dot redhat dot com
        ReportedBy: anpaza at mail dot ru
                CC: bug-binutils at gnu dot org
GCC target triplet: avr-linux-gnu


http://sourceware.org/bugzilla/show_bug.cgi?id=11297

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to