annotate libgcc/config/sparc/crti.S @ 144:8f4e72ab4e11

fix segmentation fault caused by nothing next cur_op to end
author Takahiro SHIMIZU <anatofuz@cr.ie.u-ryukyu.ac.jp>
date Sun, 23 Dec 2018 21:23:56 +0900
parents 84e7813d76e9
children 1830386684a0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 ! crti.S for SPARC
kono
parents:
diff changeset
2
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
3 ! Copyright (C) 1992-2018 Free Software Foundation, Inc.
111
kono
parents:
diff changeset
4 ! Written By David Vinayak Henkel-Wallace, June 1992
kono
parents:
diff changeset
5 !
kono
parents:
diff changeset
6 ! This file is free software; you can redistribute it and/or modify it
kono
parents:
diff changeset
7 ! under the terms of the GNU General Public License as published by the
kono
parents:
diff changeset
8 ! Free Software Foundation; either version 3, or (at your option) any
kono
parents:
diff changeset
9 ! later version.
kono
parents:
diff changeset
10 !
kono
parents:
diff changeset
11 ! This file is distributed in the hope that it will be useful, but
kono
parents:
diff changeset
12 ! WITHOUT ANY WARRANTY; without even the implied warranty of
kono
parents:
diff changeset
13 ! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
kono
parents:
diff changeset
14 ! General Public License for more details.
kono
parents:
diff changeset
15 !
kono
parents:
diff changeset
16 ! Under Section 7 of GPL version 3, you are granted additional
kono
parents:
diff changeset
17 ! permissions described in the GCC Runtime Library Exception, version
kono
parents:
diff changeset
18 ! 3.1, as published by the Free Software Foundation.
kono
parents:
diff changeset
19 !
kono
parents:
diff changeset
20 ! You should have received a copy of the GNU General Public License and
kono
parents:
diff changeset
21 ! a copy of the GCC Runtime Library Exception along with this program;
kono
parents:
diff changeset
22 ! see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
kono
parents:
diff changeset
23 ! <http://www.gnu.org/licenses/>.
kono
parents:
diff changeset
24
kono
parents:
diff changeset
25 ! This file just make a stack frame for the contents of the .fini and
kono
parents:
diff changeset
26 ! .init sections. Users may put any desired instructions in those
kono
parents:
diff changeset
27 ! sections.
kono
parents:
diff changeset
28
kono
parents:
diff changeset
29 ! This file is linked in before the Values-Xx.o files and also before
kono
parents:
diff changeset
30 ! crtbegin, with which perhaps it should be merged.
kono
parents:
diff changeset
31
kono
parents:
diff changeset
32 .section ".init"
kono
parents:
diff changeset
33 .proc 022
kono
parents:
diff changeset
34 .global _init
kono
parents:
diff changeset
35 .type _init,#function
kono
parents:
diff changeset
36 .align 4
kono
parents:
diff changeset
37 _init:
kono
parents:
diff changeset
38 #ifdef _FLAT
kono
parents:
diff changeset
39 #ifdef __sparcv9
kono
parents:
diff changeset
40 stx %i7, [%sp+2167]
kono
parents:
diff changeset
41 add %sp, -176, %sp
kono
parents:
diff changeset
42 #else
kono
parents:
diff changeset
43 st %i7, [%sp+60]
kono
parents:
diff changeset
44 add %sp, -96, %sp
kono
parents:
diff changeset
45 #endif
kono
parents:
diff changeset
46 mov %o7, %i7
kono
parents:
diff changeset
47 #else
kono
parents:
diff changeset
48 #ifdef __sparcv9
kono
parents:
diff changeset
49 save %sp, -176, %sp
kono
parents:
diff changeset
50 #else
kono
parents:
diff changeset
51 save %sp, -96, %sp
kono
parents:
diff changeset
52 #endif
kono
parents:
diff changeset
53 #endif
kono
parents:
diff changeset
54
kono
parents:
diff changeset
55
kono
parents:
diff changeset
56 .section ".fini"
kono
parents:
diff changeset
57 .proc 022
kono
parents:
diff changeset
58 .global _fini
kono
parents:
diff changeset
59 .type _fini,#function
kono
parents:
diff changeset
60 .align 4
kono
parents:
diff changeset
61 _fini:
kono
parents:
diff changeset
62 #ifdef _FLAT
kono
parents:
diff changeset
63 #ifdef __sparcv9
kono
parents:
diff changeset
64 stx %i7, [%sp+2167]
kono
parents:
diff changeset
65 add %sp, -176, %sp
kono
parents:
diff changeset
66 #else
kono
parents:
diff changeset
67 st %i7, [%sp+60]
kono
parents:
diff changeset
68 add %sp, -96, %sp
kono
parents:
diff changeset
69 #endif
kono
parents:
diff changeset
70 mov %o7, %i7
kono
parents:
diff changeset
71 #else
kono
parents:
diff changeset
72 #ifdef __sparcv9
kono
parents:
diff changeset
73 save %sp, -176, %sp
kono
parents:
diff changeset
74 #else
kono
parents:
diff changeset
75 save %sp, -96, %sp
kono
parents:
diff changeset
76 #endif
kono
parents:
diff changeset
77 #endif