winxp SP2 running cygwin. Upgrading binutils from 2.16.1 to 2.17 (and cvs head) the following problem has appeared. when using a startup file that uses variables from the linker script, the values passed to the final binary are incorrect if the section is empty, data section is used for this example.
In the example below the value for __data_start is incorrect if the data section is empty, if the var is uncommented then the value for __data_start is correct. Built with command line: arm-elf-as --gdwarf-2 test.s -o test.o arm-elf-ld -Ttext 0x00000000 -Tdata 0x20000000 -Map=test.map -o test.elf test.o test.s dump: .data #var1: .long 0x10 .text .arm .global _start _start: /* Relocate .data section (Copy from ROM to RAM) */ LDR r1, =_etext LDR r2, =__data_start LDR r3, =_edata LoopRel: CMP r2, r3 LDRLO r0, [r1], #4 STRLO r0, [r2], #4 BLO LoopRel main: B main .end -- Summary: ld fails to link correct variables from linker script. Product: binutils Version: 2.18 (HEAD) Status: NEW Severity: normal Priority: P2 Component: ld AssignedTo: unassigned at sources dot redhat dot com ReportedBy: sjo at anglia dot com CC: bug-binutils at gnu dot org GCC build triplet: i686-pc-cygwin GCC host triplet: i686-pc-cygwin GCC target triplet: arm-elf http://sourceware.org/bugzilla/show_bug.cgi?id=3223 ------- 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