makeas.sh revision 1.5 1 1.1 is #!/bin/sh
2 1.1 is
3 1.5 is # $NetBSD: makeas.sh,v 1.5 2000/05/12 20:08:04 is Exp $
4 1.1 is
5 1.5 is # Copyright (c) 1999, 2000 Ignatios Souvatzis
6 1.1 is # All rights reserved.
7 1.1 is #
8 1.1 is # Redistribution and use in source and binary forms, with or without
9 1.1 is # modification, are permitted provided that the following conditions
10 1.1 is # are met:
11 1.1 is # 1. Redistributions of source code must retain the above copyright
12 1.1 is # notice, this list of conditions and the following disclaimer.
13 1.1 is # 2. Redistributions in binary form must reproduce the above copyright
14 1.1 is # notice, this list of conditions and the following disclaimer in the
15 1.1 is # documentation and/or other materials provided with the distribution.
16 1.1 is # 3. All advertising materials mentioning features or use of this software
17 1.1 is # must display the following acknowledgement:
18 1.1 is # This product includes software developed for the NetBSD Project
19 1.1 is # by Ignatios Souvatzis.
20 1.1 is # 4. The name of the author may not be used to endorse or promote products
21 1.1 is # derived from this software without specific prior written permission
22 1.1 is #
23 1.1 is # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
24 1.1 is # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
25 1.1 is # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
26 1.1 is # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
27 1.1 is # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
28 1.1 is # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
29 1.1 is # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
30 1.1 is # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
31 1.1 is # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
32 1.1 is # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 1.1 is
34 1.1 is
35 1.1 is
36 1.1 is REALCODE=fplsp_wrap.S
37 1.1 is FILELIST=Makefile.list
38 1.1 is
39 1.1 is dummy () {
40 1.1 is while [ X$1 != X ]; do
41 1.1 is /bin/cat > $1.S << EOM
42 1.1 is /* \$NetBSD\$ */
43 1.1 is
44 1.1 is /*
45 1.5 is * Dummy file. Real code is elsewhere.
46 1.1 is *
47 1.1 is * DO NOT EDIT - this file is automatically generated.
48 1.1 is *
49 1.1 is */
50 1.1 is EOM
51 1.1 is echo -n " " $1.S >> $FILELIST
52 1.1 is shift
53 1.1 is done
54 1.1 is }
55 1.1 is
56 1.2 is linebreak () {
57 1.2 is echo " \\" >> ${FILELIST}
58 1.2 is echo -n " " >> ${FILELIST}
59 1.2 is }
60 1.2 is
61 1.1 is mk () {
62 1.1 is NAME=$1
63 1.1 is OFFS=$2
64 1.5 is THESRC=$3.S
65 1.5 is shift; shift; shift
66 1.1 is
67 1.5 is echo -n " " ${THESRC} >> $FILELIST
68 1.5 is /bin/cat > ${THESRC} << EOJ
69 1.5 is /* \$NetBSD\$ */
70 1.5 is
71 1.5 is /*
72 1.5 is * FPLSP wrapper for $NAME
73 1.5 is * DO NOT EDIT - this file is automatically generated.
74 1.5 is */
75 1.5 is
76 1.5 is #include <machine/asm.h>
77 1.1 is
78 1.1 is ENTRY($NAME)
79 1.1 is #ifdef __SVR4_ABI__
80 1.5 is jbra _ASM_LABEL(___060FPLSP$OFFS)
81 1.1 is #else
82 1.4 thorpej movel %sp@(8),%sp@-
83 1.4 thorpej movel %sp@(8),%sp@-
84 1.5 is jbsr _ASM_LABEL(___060FPLSP$OFFS)
85 1.4 thorpej fmoved %fp0,%sp@
86 1.4 thorpej movel %sp@+,%d0
87 1.4 thorpej movel %sp@+,%d1
88 1.1 is rts
89 1.1 is #endif
90 1.1 is EOJ
91 1.1 is dummy $*
92 1.1 is }
93 1.1 is
94 1.1 is mks () {
95 1.1 is NAME=$1
96 1.1 is OFFS=$2
97 1.5 is THESRC=$3.S
98 1.5 is shift; shift; shift
99 1.5 is
100 1.5 is echo -n " " ${THESRC} >> $FILELIST
101 1.5 is /bin/cat > ${THESRC} << EOJ
102 1.5 is /* \$NetBSD\$ */
103 1.5 is
104 1.5 is /*
105 1.5 is * FPLSP wrapper for $NAME
106 1.5 is * DO NOT EDIT - this file is automatically generated.
107 1.5 is */
108 1.1 is
109 1.5 is #include <machine/asm.h>
110 1.1 is
111 1.1 is ENTRY($NAME)
112 1.1 is #ifdef __SVR4_ABI__
113 1.5 is jbra _ASM_LABEL(___060FPLSP$OFFS)
114 1.1 is #else
115 1.4 thorpej movel %sp@(4),%sp@-
116 1.5 is jbsr _ASM_LABEL(___060FPLSP$OFFS)
117 1.4 thorpej fmoves %fp0,%sp@
118 1.4 thorpej movel %sp@+,%d0
119 1.1 is rts
120 1.1 is #endif
121 1.1 is EOJ
122 1.1 is dummy $*
123 1.1 is }
124 1.1 is
125 1.1 is /bin/cat > ${REALCODE} << EOJ
126 1.1 is /* \$NetBSD\$ */
127 1.1 is
128 1.1 is /*
129 1.1 is * FPLSP wrapper.
130 1.1 is *
131 1.1 is * DO NOT EDIT - this file is automatically generated!
132 1.1 is */
133 1.1 is
134 1.1 is #include <machine/asm.h>
135 1.1 is
136 1.1 is EOJ
137 1.1 is
138 1.1 is /bin/cat > ${FILELIST} << EOJ
139 1.1 is # \$NetBSD\$
140 1.1 is
141 1.1 is #
142 1.1 is # list of M68060 architecture dependent files for libm.
143 1.1 is #
144 1.1 is # Created by a script. Do not edit manually!
145 1.1 is #
146 1.1 is
147 1.1 is EOJ
148 1.1 is
149 1.1 is echo -n ARCH_SRCS = >> $FILELIST
150 1.1 is
151 1.1 is mks __ieee754_acosf 0000 e_acosf
152 1.1 is mk __ieee754_acos 0008 e_acos
153 1.1 is mks __ieee754_asinf 0018 e_asinf
154 1.1 is mk __ieee754_asin 0020 e_asin
155 1.2 is linebreak
156 1.1 is mks atanf 0030 s_atanf
157 1.1 is mk atan 0038 s_atan
158 1.1 is mks __ieee754_atanhf 0048 e_atanhf
159 1.1 is mk __ieee754_atanh 0050 e_atanh
160 1.2 is linebreak
161 1.3 is mks cosf 0060 s_cosf
162 1.3 is mk cos 0068 s_cos
163 1.1 is mks __ieee754_coshf 0078 e_coshf
164 1.1 is mk __ieee754_cosh 0080 e_cosh
165 1.2 is linebreak
166 1.1 is mks __ieee754_expf 0090 e_expf
167 1.1 is mk __ieee754_exp 0098 e_exp
168 1.1 is mks expm1f 00a8 s_expm1f
169 1.1 is mk expm1 00b0 s_expm1
170 1.2 is linebreak
171 1.1 is mks __ieee754_log10f 00f0 e_log10f
172 1.1 is mk __ieee754_log10 00f8 e_log10
173 1.1 is mks logbf 0108 s_logbf
174 1.1 is mk logb 0110 s_logb
175 1.2 is linebreak
176 1.1 is mks __ieee754_logf 0120 e_logf
177 1.1 is mk __ieee754_log 0128 e_log
178 1.1 is mks log1pf 0138 s_log1pf
179 1.1 is mk log1p 0140 s_log1p
180 1.2 is linebreak
181 1.3 is mks sinf 0198 s_sinf
182 1.3 is mk sin 01a0 s_sin
183 1.1 is mks __ieee754_sinhf 01c8 e_sinhf
184 1.1 is mk __ieee754_sinh 01d0 e_sinh
185 1.2 is linebreak
186 1.1 is mks tanf 01e0 s_tanf k_tanf
187 1.1 is mk tan 01e8 s_tan k_tan
188 1.1 is mks tanhf 01f8 s_tanhf
189 1.1 is mk tanh 0200 s_tanh
190 1.2 is linebreak
191 1.1 is mks __ieee754_sqrtf 02e8 e_sqrtf
192 1.1 is mk __ieee754_sqrt 02f0 e_sqrt
193 1.1 is
194 1.1 is /bin/cat >> ${REALCODE} << EOJ
195 1.1 is
196 1.1 is L060FPLSP_BASE:
197 1.1 is #include "fplsp.hex"
198 1.1 is EOJ
199 1.1 is
200 1.1 is echo "" >> ${FILELIST}
201 1.1 is echo ARCH_ADDS = ${REALCODE} >> ${FILELIST}
202