2009-03-11 Zoltan Varga <vargaz@gmail.com>
[mono-debugger.git] / libgc / powerpc_darwin_mach_dep.s
blobfd23110b80b511db8d95e32e6629587b7e62907b
2 ; GC_push_regs function. Under some optimization levels GCC will clobber
3 ; some of the non-volatile registers before we get a chance to save them
4 ; therefore, this cannot be inline asm.
6 .text
7 .align 2
8 .globl _GC_push_regs
9 _GC_push_regs:
11 ; Prolog
12 mflr r0
13 stw r0,8(r1)
14 stwu r1,-80(r1)
16 ; Push r13-r31
17 mr r3,r13
18 bl L_GC_push_one$stub
19 mr r3,r14
20 bl L_GC_push_one$stub
21 mr r3,r15
22 bl L_GC_push_one$stub
23 mr r3,r16
24 bl L_GC_push_one$stub
25 mr r3,r17
26 bl L_GC_push_one$stub
27 mr r3,r18
28 bl L_GC_push_one$stub
29 mr r3,r19
30 bl L_GC_push_one$stub
31 mr r3,r20
32 bl L_GC_push_one$stub
33 mr r3,r21
34 bl L_GC_push_one$stub
35 mr r3,r22
36 bl L_GC_push_one$stub
37 mr r3,r23
38 bl L_GC_push_one$stub
39 mr r3,r24
40 bl L_GC_push_one$stub
41 mr r3,r25
42 bl L_GC_push_one$stub
43 mr r3,r26
44 bl L_GC_push_one$stub
45 mr r3,r27
46 bl L_GC_push_one$stub
47 mr r3,r28
48 bl L_GC_push_one$stub
49 mr r3,r29
50 bl L_GC_push_one$stub
51 mr r3,r30
52 bl L_GC_push_one$stub
53 mr r3,r31
54 bl L_GC_push_one$stub
57 lwz r0,88(r1)
58 addi r1,r1,80
59 mtlr r0
61 ; Return
62 blr
64 ; PIC stuff, generated by GCC
66 .data
67 .section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32
68 .align 2
69 L_GC_push_one$stub:
70 .indirect_symbol _GC_push_one
71 mflr r0
72 bcl 20,31,L0$_GC_push_one
73 L0$_GC_push_one:
74 mflr r11
75 addis r11,r11,ha16(L_GC_push_one$lazy_ptr-L0$_GC_push_one)
76 mtlr r0
77 lwzu r12,lo16(L_GC_push_one$lazy_ptr-L0$_GC_push_one)(r11)
78 mtctr r12
79 bctr
80 .data
81 .lazy_symbol_pointer
82 L_GC_push_one$lazy_ptr:
83 .indirect_symbol _GC_push_one
84 .long dyld_stub_binding_helper