This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

SH: collision of labels


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;
 }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]