Home | History | Annotate | Line # | Download | only in m68060
makeas.sh revision 1.3.4.1
      1      1.1        is #!/bin/sh
      2      1.1        is 
      3  1.3.4.1  wrstuden # $NetBSD: makeas.sh,v 1.3.4.1 1999/12/27 18:30:00 wrstuden Exp $
      4      1.1        is 
      5      1.1        is # Copyright (c) 1999 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.1        is  * Dummy file. Real code is in ${REALCODE}.
     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.1        is shift; shift
     65      1.1        is 
     66      1.1        is /bin/cat >> ${REALCODE} << EOJ
     67      1.1        is 
     68      1.1        is ENTRY($NAME)
     69      1.1        is #ifdef __SVR4_ABI__
     70      1.1        is 	jbra L060FPLSP$OFFS
     71      1.1        is #else
     72  1.3.4.1  wrstuden 	movel %sp@(8),%sp@-
     73  1.3.4.1  wrstuden 	movel %sp@(8),%sp@-
     74      1.1        is 	jbsr L060FPLSP$OFFS
     75  1.3.4.1  wrstuden 	fmoved %fp0,%sp@
     76  1.3.4.1  wrstuden 	movel %sp@+,%d0
     77  1.3.4.1  wrstuden 	movel %sp@+,%d1
     78      1.1        is 	rts
     79      1.1        is #endif
     80      1.1        is EOJ
     81      1.1        is dummy $*
     82      1.1        is }
     83      1.1        is 
     84      1.1        is mks () {
     85      1.1        is NAME=$1
     86      1.1        is OFFS=$2
     87      1.1        is shift; shift
     88      1.1        is 
     89      1.1        is /bin/cat >> ${REALCODE} << EOJ
     90      1.1        is 
     91      1.1        is ENTRY($NAME)
     92      1.1        is #ifdef __SVR4_ABI__
     93      1.1        is 	jbra L060FPLSP$OFFS
     94      1.1        is #else
     95  1.3.4.1  wrstuden 	movel %sp@(4),%sp@-
     96      1.1        is 	jbsr L060FPLSP$OFFS
     97  1.3.4.1  wrstuden 	fmoves %fp0,%sp@
     98  1.3.4.1  wrstuden 	movel %sp@+,%d0
     99      1.1        is 	rts
    100      1.1        is #endif
    101      1.1        is EOJ
    102      1.1        is dummy $*
    103      1.1        is }
    104      1.1        is 
    105      1.1        is /bin/cat > ${REALCODE} << EOJ
    106      1.1        is /* \$NetBSD\$ */
    107      1.1        is 
    108      1.1        is /*
    109      1.1        is  * FPLSP wrapper.
    110      1.1        is  *
    111      1.1        is  * DO NOT EDIT - this file is automatically generated!
    112      1.1        is  */
    113      1.1        is 
    114      1.1        is #include <machine/asm.h>
    115      1.1        is 
    116      1.1        is EOJ
    117      1.1        is 
    118      1.1        is /bin/cat > ${FILELIST} << EOJ
    119      1.1        is # \$NetBSD\$
    120      1.1        is 
    121      1.1        is #
    122      1.1        is # list of M68060 architecture dependent files for libm.
    123      1.1        is #
    124      1.1        is # Created by a script. Do not edit manually!
    125      1.1        is #
    126      1.1        is 
    127      1.1        is EOJ
    128      1.1        is 
    129      1.1        is echo -n ARCH_SRCS = >> $FILELIST
    130      1.1        is 
    131      1.1        is mks	__ieee754_acosf		0000	e_acosf
    132      1.1        is mk	__ieee754_acos		0008	e_acos
    133      1.1        is mks	__ieee754_asinf		0018	e_asinf
    134      1.1        is mk	__ieee754_asin		0020	e_asin
    135      1.2        is linebreak
    136      1.1        is mks	atanf			0030	s_atanf
    137      1.1        is mk	atan			0038	s_atan
    138      1.1        is mks	__ieee754_atanhf	0048	e_atanhf
    139      1.1        is mk	__ieee754_atanh		0050	e_atanh
    140      1.2        is linebreak
    141      1.3        is mks	cosf			0060	s_cosf
    142      1.3        is mk	cos			0068	s_cos
    143      1.1        is mks	__ieee754_coshf		0078	e_coshf
    144      1.1        is mk	__ieee754_cosh		0080	e_cosh
    145      1.2        is linebreak
    146      1.1        is mks	__ieee754_expf		0090	e_expf
    147      1.1        is mk	__ieee754_exp		0098	e_exp
    148      1.1        is mks	expm1f			00a8	s_expm1f
    149      1.1        is mk	expm1			00b0	s_expm1
    150      1.2        is linebreak
    151      1.1        is mks	__ieee754_log10f	00f0	e_log10f
    152      1.1        is mk	__ieee754_log10		00f8	e_log10
    153      1.1        is mks	logbf			0108	s_logbf
    154      1.1        is mk	logb			0110	s_logb
    155      1.2        is linebreak
    156      1.1        is mks	__ieee754_logf		0120	e_logf
    157      1.1        is mk	__ieee754_log		0128	e_log
    158      1.1        is mks	log1pf			0138	s_log1pf
    159      1.1        is mk	log1p			0140	s_log1p
    160      1.2        is linebreak
    161      1.3        is mks	sinf			0198	s_sinf
    162      1.3        is mk	sin			01a0	s_sin
    163      1.1        is mks	__ieee754_sinhf		01c8	e_sinhf
    164      1.1        is mk	__ieee754_sinh		01d0	e_sinh
    165      1.2        is linebreak
    166      1.1        is mks	tanf			01e0	s_tanf k_tanf
    167      1.1        is mk	tan			01e8	s_tan k_tan
    168      1.1        is mks	tanhf			01f8	s_tanhf
    169      1.1        is mk	tanh			0200	s_tanh
    170      1.2        is linebreak
    171      1.1        is mks	__ieee754_sqrtf		02e8	e_sqrtf
    172      1.1        is mk	__ieee754_sqrt		02f0	e_sqrt
    173      1.1        is 
    174      1.1        is /bin/cat >> ${REALCODE} << EOJ
    175      1.1        is 
    176      1.1        is L060FPLSP_BASE:
    177      1.1        is #include "fplsp.hex"
    178      1.1        is EOJ
    179      1.1        is 
    180      1.1        is echo ""	>> ${FILELIST}
    181      1.1        is echo ARCH_ADDS = ${REALCODE} >> ${FILELIST}
    182