SH: collision of labels
kaz Kojima
kkojima@rr.iij4u.or.jp
Thu Jun 27 20:49:00 GMT 2002
Hi,
This is a tiny patch for SH to avoid the collision of labels.
kaz
--
2002-06-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
* sysdeps/sh/dl-machine.h (elf_machine_load_address): Use
local labels in assembler instructions.
Index: sysdeps/sh/dl-machine.h
===================================================================
RCS file: /cvs/glibc/libc/sysdeps/sh/dl-machine.h,v
retrieving revision 1.21
diff -u -3 -p -r1.21 dl-machine.h
--- sysdeps/sh/dl-machine.h 8 Apr 2002 20:59:36 -0000 1.21
+++ sysdeps/sh/dl-machine.h 27 Jun 2002 07:48:04 -0000
@@ -53,16 +53,16 @@ static inline Elf32_Addr __attribute__ (
elf_machine_load_address (void)
{
Elf32_Addr addr;
- asm ("mov.l .L1,r0\n\
- mov.l .L3,r2\n\
+ asm ("mov.l 1f,r0\n\
+ mov.l 3f,r2\n\
add r12,r2\n\
mov.l @(r0,r12),r0\n\
- bra .L2\n\
+ bra 2f\n\
sub r0,r2\n\
.align 2\n\
- .L1: .long _dl_start@GOT\n\
- .L3: .long _dl_start@GOTOFF\n\
- .L2: mov r2,%0"
+ 1: .long _dl_start@GOT\n\
+ 3: .long _dl_start@GOTOFF\n\
+ 2: mov r2,%0"
: "=r" (addr) : : "r0", "r1", "r2");
return addr;
}
More information about the Libc-hacker
mailing list