This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


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

Re: [Patch] Save space in rs6000/darwin-tramp.asm



On Sunday, August 3, 2003, at 08:31 PM, Andrew Pinski wrote:


This patch changes the pic stub in rs6000/darwin-tramp.asm to be the new stub to save space (4 bytes).

Ok?

I have no authority, but...the basic idea looks good, but why are you changing
the name of the local label? That isn't necessary.


diff -u -p -r1.3 darwin-tramp.asm
--- darwin-tramp.asm	7 Jul 2003 17:27:53 -0000	1.3
+++ darwin-tramp.asm	4 Aug 2003 03:30:08 -0000
@@ -103,18 +103,18 @@ Labort:
 #ifdef __DYNAMIC__
 	bl	L_abort$stub
 .data
-.picsymbol_stub
+.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32
+        .align 2
 L_abort$stub:
         .indirect_symbol _abort
         mflr r0
-        bcl 20,31,L0$_abort
-L0$_abort:
+        bcl 20,31,L1$spb
+L1$spb:
         mflr r11
-        addis r11,r11,ha16(L_abort$lazy_ptr-L0$_abort)
+        addis r11,r11,ha16(L_abort$lazy_ptr-L1$spb)
         mtlr r0
-        lwz r12,lo16(L_abort$lazy_ptr-L0$_abort)(r11)
+        lwzu r12,lo16(L_abort$lazy_ptr-L1$spb)(r11)
         mtctr r12
-        addi r11,r11,lo16(L_abort$lazy_ptr-L0$_abort)
         bctr
 .data
 .lazy_symbol_pointer



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