OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [insight/] [sim/] [mips/] [configure.in] - Blame information for rev 578

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 578 markom
dnl Process this file with autoconf to produce a configure script.
2
sinclude(../common/aclocal.m4)
3
AC_PREREQ(2.5)dnl
4
AC_INIT(Makefile.in)
5
 
6
SIM_AC_COMMON
7
 
8
dnl Options available in this module
9
SIM_AC_OPTION_INLINE()
10
SIM_AC_OPTION_ALIGNMENT(NONSTRICT_ALIGNMENT)
11
SIM_AC_OPTION_HOSTENDIAN
12
SIM_AC_OPTION_WARNINGS
13
 
14
# DEPRECATED
15
#
16
# Instead of defining a `subtarget' macro, code should be checking
17
# the value of {STATE,CPU}_ARCHITECTURE to identify the architecture
18
# in question.
19
#
20
case "${target}" in
21
  mips*tx39*)           SIM_SUBTARGET="-DSUBTARGET_R3900=1";;
22
  *)                    SIM_SUBTARGET="";;
23
esac
24
AC_SUBST(SIM_SUBTARGET)
25
 
26
 
27
 
28
#
29
# Select the byte order of the target
30
#
31
mips_endian=
32
default_endian=
33
case "${target}" in
34
  mips64el*-*-*)        mips_endian=LITTLE_ENDIAN ;;
35
  mips64vr*el-*-*)      default_endian=LITTLE_ENDIAN ;;
36
  mips64*-*-*)          default_endian=BIG_ENDIAN ;;
37
  mips16*-*-*)          default_endian=BIG_ENDIAN ;;
38
  mips*-*-*)            default_endian=BIG_ENDIAN ;;
39
  *)                    default_endian=BIG_ENDIAN ;;
40
esac
41
SIM_AC_OPTION_ENDIAN($mips_endian,$default_endian)
42
 
43
 
44
 
45
#
46
# Select the bitsize of the target
47
#
48
mips_addr_bitsize=
49
case "${target}" in
50
  mips64*-*-*)          mips_bitsize=64 ; mips_msb=63 ;;
51
  mips16*-*-*)          mips_bitsize=64 ; mips_msb=63 ;;
52
  mips*-*-*)            mips_bitsize=32 ; mips_msb=31 ;;
53
  *)                    mips_bitsize=64 ; mips_msb=63 ;;
54
esac
55
SIM_AC_OPTION_BITSIZE($mips_bitsize,$mips_msb,$mips_addr_bitsize)
56
 
57
 
58
 
59
#
60
# Select the floating hardware support of the target
61
#
62
mips_fpu=HARDWARE_FLOATING_POINT
63
mips_fpu_bitsize=
64
case "${target}" in
65
  mips*tx39*)           mips_fpu=HARD_FLOATING_POINT
66
                        mips_fpu_bitsize=32
67
                        ;;
68
  mips64*-*-*)          mips_fpu=HARD_FLOATING_POINT ;;
69
  mips16*-*-*)          mips_fpu=HARD_FLOATING_POINT ;;
70
  mips*-*-*)            mips_fpu=HARD_FLOATING_POINT ; mips_fpu_bitsize=32 ;;
71
  *)                    mips_fpu=HARD_FLOATING_POINT ;;
72
esac
73
SIM_AC_OPTION_FLOAT($mips_fpu,$mips_fpu_bitsize)
74
 
75
 
76
 
77
#
78
# Select the level of SMP support
79
#
80
case "${target}" in
81
  *)                    mips_smp=0 ;;
82
esac
83
SIM_AC_OPTION_SMP($mips_smp)
84
 
85
 
86
 
87
#
88
# Select the IGEN architecture
89
#
90
sim_gen=IGEN
91
sim_igen_machine="-M mipsIV"
92
sim_m16_machine="-M mips16"
93
sim_igen_filter="32,64,f"
94
sim_m16_filter="16"
95
case "${target}" in
96
  mips*tx39*)           sim_gen=IGEN
97
                        sim_igen_filter="32,f"
98
                        sim_igen_machine="-M r3900"
99
                        ;;
100
  mips64vr43*-*-*)      sim_gen=IGEN
101
                        sim_igen_machine="-M mipsIV"
102
                        ;;
103
  mips64vr5*-*-*)       sim_gen=IGEN
104
                        sim_igen_machine="-M vr5000"
105
                        ;;
106
  mips64vr41*)          sim_gen=M16
107
                        sim_igen_machine="-M vr4100"
108
                        sim_m16_machine="-M vr4100"
109
                        sim_igen_filter="32,64,f"
110
                        sim_m16_filter="16"
111
                        ;;
112
  mips64*-*-*)          sim_igen_filter="32,64,f"
113
                        sim_gen=IGEN
114
                        ;;
115
  mips16*-*-*)          sim_gen=M16
116
                        sim_igen_filter="32,64,f"
117
                        sim_m16_filter="16"
118
                        ;;
119
  mips*lsi*)            sim_gen=M16
120
                        sim_igen_machine="-M mipsIII,mips16"
121
                        sim_m16_machine="-M mips16,mipsIII"
122
                        sim_igen_filter="32,f"
123
                        sim_m16_filter="16"
124
                        ;;
125
  mips*-*-*)            sim_gen=IGEN
126
                        sim_igen_filter="32,f"
127
                        ;;
128
esac
129
sim_igen_flags="-F ${sim_igen_filter} ${sim_igen_machine} ${sim_igen_smp}"
130
sim_m16_flags=" -F ${sim_m16_filter}  ${sim_m16_machine}  ${sim_igen_smp}"
131
AC_SUBST(sim_igen_flags)
132
AC_SUBST(sim_m16_flags)
133
AC_SUBST(sim_gen)
134
 
135
 
136
#
137
# Add simulated hardware devices
138
#
139
hw_enabled=no
140
case "${target}" in
141
  mips*tx39*)
142
        hw_enabled=yes
143
        hw_extra_devices="tx3904cpu tx3904irc tx3904tmr tx3904sio"
144
        mips_extra_objs="dv-sockser.o"
145
        SIM_SUBTARGET="$SIM_SUBTARGET -DTARGET_TX3904=1"
146
        ;;
147
  *)
148
        mips_extra_objs=""
149
        ;;
150
esac
151
SIM_AC_OPTION_HARDWARE($hw_enabled,$hw_devices,$hw_extra_devices)
152
AC_SUBST(mips_extra_objs)
153
 
154
 
155
# Choose simulator engine
156
case "${target}" in
157
  *)    mips_igen_engine="engine.o"
158
        ;;
159
esac
160
AC_SUBST(mips_igen_engine)
161
 
162
 
163
AC_PATH_X
164
mips_extra_libs=""
165
AC_SUBST(mips_extra_libs)
166
 
167
AC_CHECK_HEADERS(string.h strings.h stdlib.h stdlib.h)
168
AC_CHECK_LIB(m, fabs)
169
AC_CHECK_FUNCS(aint anint sqrt)
170
 
171
SIM_AC_OUTPUT

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.