]> rtime.felk.cvut.cz Git - coffee/buildroot.git/blob - arch/Config.in.arm
arch/arm: remove BR2_GCC_TARGET_ARCH definitions on ARM
[coffee/buildroot.git] / arch / Config.in.arm
1 # arm cpu features
2 config BR2_ARM_CPU_HAS_NEON
3         bool
4
5 # for some cores, NEON support is optional
6 config BR2_ARM_CPU_MAYBE_HAS_NEON
7         bool
8
9 # for some cores, VFPv2 is optional
10 config BR2_ARM_CPU_MAYBE_HAS_VFPV2
11         bool
12
13 config BR2_ARM_CPU_HAS_VFPV2
14         bool
15
16 # for some cores, VFPv3 is optional
17 config BR2_ARM_CPU_MAYBE_HAS_VFPV3
18         bool
19         select BR2_ARM_CPU_MAYBE_HAS_VFPV2
20
21 config BR2_ARM_CPU_HAS_VFPV3
22         bool
23         select BR2_ARM_CPU_HAS_VFPV2
24
25 # for some cores, VFPv4 is optional
26 config BR2_ARM_CPU_MAYBE_HAS_VFPV4
27         bool
28         select BR2_ARM_CPU_MAYBE_HAS_VFPV3
29
30 config BR2_ARM_CPU_HAS_VFPV4
31         bool
32         select BR2_ARM_CPU_HAS_VFPV3
33
34 config BR2_ARM_CPU_HAS_THUMB
35         bool
36
37 config BR2_ARM_CPU_HAS_THUMB2
38         bool
39
40 config BR2_ARM_CPU_ARMV4
41         bool
42
43 config BR2_ARM_CPU_ARMV5
44         bool
45
46 config BR2_ARM_CPU_ARMV6
47         bool
48
49 config BR2_ARM_CPU_ARMV7A
50         bool
51
52 choice
53         prompt "Target Architecture Variant"
54         depends on BR2_arm || BR2_armeb
55         default BR2_arm926t
56         help
57           Specific CPU variant to use
58
59 config BR2_arm920t
60         bool "arm920t"
61         select BR2_ARM_CPU_HAS_THUMB
62         select BR2_ARM_CPU_ARMV4
63 config BR2_arm922t
64         bool "arm922t"
65         select BR2_ARM_CPU_HAS_THUMB
66         select BR2_ARM_CPU_ARMV4
67 config BR2_arm926t
68         bool "arm926t"
69         select BR2_ARM_CPU_MAYBE_HAS_VFPV2
70         select BR2_ARM_CPU_HAS_THUMB
71         select BR2_ARM_CPU_ARMV5
72 config BR2_arm1136jf_s
73         bool "arm1136jf-s"
74         select BR2_ARM_CPU_HAS_VFPV2
75         select BR2_ARM_CPU_HAS_THUMB
76         select BR2_ARM_CPU_ARMV6
77 config BR2_arm1176jz_s
78         bool "arm1176jz-s"
79         select BR2_ARM_CPU_HAS_THUMB
80         select BR2_ARM_CPU_ARMV6
81 config BR2_arm1176jzf_s
82         bool "arm1176jzf-s"
83         select BR2_ARM_CPU_HAS_VFPV2
84         select BR2_ARM_CPU_HAS_THUMB
85         select BR2_ARM_CPU_ARMV6
86 config BR2_cortex_a5
87         bool "cortex-A5"
88         select BR2_ARM_CPU_MAYBE_HAS_NEON
89         select BR2_ARM_CPU_MAYBE_HAS_VFPV4
90         select BR2_ARM_CPU_HAS_THUMB2
91         select BR2_ARM_CPU_ARMV7A
92 config BR2_cortex_a7
93         bool "cortex-A7"
94         select BR2_ARM_CPU_HAS_NEON
95         select BR2_ARM_CPU_HAS_VFPV4
96         select BR2_ARM_CPU_HAS_THUMB2
97         select BR2_ARM_CPU_ARMV7A
98 config BR2_cortex_a8
99         bool "cortex-A8"
100         select BR2_ARM_CPU_HAS_NEON
101         select BR2_ARM_CPU_HAS_VFPV3
102         select BR2_ARM_CPU_HAS_THUMB2
103         select BR2_ARM_CPU_ARMV7A
104 config BR2_cortex_a9
105         bool "cortex-A9"
106         select BR2_ARM_CPU_MAYBE_HAS_NEON
107         select BR2_ARM_CPU_MAYBE_HAS_VFPV3
108         select BR2_ARM_CPU_HAS_THUMB2
109         select BR2_ARM_CPU_ARMV7A
110 config BR2_cortex_a12
111         bool "cortex-A12"
112         select BR2_ARM_CPU_HAS_NEON
113         select BR2_ARM_CPU_HAS_VFPV4
114         select BR2_ARM_CPU_HAS_THUMB2
115         select BR2_ARM_CPU_ARMV7A
116 config BR2_cortex_a15
117         bool "cortex-A15"
118         select BR2_ARM_CPU_HAS_NEON
119         select BR2_ARM_CPU_HAS_VFPV4
120         select BR2_ARM_CPU_HAS_THUMB2
121         select BR2_ARM_CPU_ARMV7A
122 config BR2_fa526
123         bool "fa526/626"
124         select BR2_ARM_CPU_ARMV4
125 config BR2_pj4
126         bool "pj4"
127         select BR2_ARM_CPU_HAS_VFPV3
128         select BR2_ARM_CPU_ARMV7A
129 config BR2_strongarm
130         bool "strongarm sa110/sa1100"
131         select BR2_ARM_CPU_ARMV4
132 config BR2_xscale
133         bool "xscale"
134         select BR2_ARM_CPU_HAS_THUMB
135         select BR2_ARM_CPU_ARMV5
136 config BR2_iwmmxt
137         bool "iwmmxt"
138         select BR2_ARM_CPU_ARMV5
139 endchoice
140
141 choice
142         prompt "Target ABI"
143         depends on BR2_arm || BR2_armeb
144         default BR2_ARM_EABI
145         help
146           Application Binary Interface to use. The Application Binary
147           Interface describes the calling conventions (how arguments
148           are passed to functions, how the return value is passed, how
149           system calls are made, etc.).
150
151 config BR2_ARM_EABI
152         bool "EABI"
153         help
154           The EABI is currently the standard ARM ABI, which is used in
155           most projects. It supports both the 'soft' floating point
156           model (in which floating point instructions are emulated in
157           software) and the 'softfp' floating point model (in which
158           floating point instructions are executed using an hardware
159           floating point unit, but floating point arguments to
160           functions are passed in integer registers).
161
162           The 'softfp' floating point model is link-compatible with
163           the 'soft' floating point model, i.e you can link a library
164           built 'soft' with some other code built 'softfp'.
165
166           However, passing the floating point arguments in integer
167           registers is a bit inefficient, so if your ARM processor has
168           a floating point unit, and you don't have pre-compiled
169           'soft' or 'softfp' code, using the EABIhf ABI will provide
170           better floating point performances.
171
172           If your processor does not have a floating point unit, then
173           you must use this ABI.
174
175 config BR2_ARM_EABIHF
176         bool "EABIhf"
177         depends on BR2_ARM_CPU_MAYBE_HAS_VFPV2 || BR2_ARM_CPU_HAS_VFPV2
178         help
179           The EABIhf is an extension of EABI which supports the 'hard'
180           floating point model. This model uses the floating point
181           unit to execute floating point instructions, and passes
182           floating point arguments in floating point registers.
183
184           It is more efficient than EABI for floating point related
185           workload. However, it does not allow to link against code
186           that has been pre-built for the 'soft' or 'softfp' floating
187           point models.
188
189           If your processor has a floating point unit, and you don't
190           depend on existing pre-compiled code, this option is most
191           likely the best choice.
192
193 endchoice
194
195 config BR2_ARM_ENABLE_NEON
196         bool "Enable NEON SIMD extension support"
197         depends on BR2_ARM_CPU_MAYBE_HAS_NEON
198         select BR2_ARM_CPU_HAS_NEON
199         help
200           For some CPU cores, the NEON SIMD extension is optional.
201           Select this option if you are certain your particular
202           implementation has NEON support and you want to use it.
203
204 choice
205         prompt "Floating point strategy"
206         depends on BR2_ARM_EABI || BR2_ARM_EABIHF
207         default BR2_ARM_FPU_VFPV4D16 if BR2_ARM_CPU_HAS_VFPV4
208         default BR2_ARM_FPU_VFPV3D16 if BR2_ARM_CPU_HAS_VFPV3
209         default BR2_ARM_FPU_VFPV2 if BR2_ARM_CPU_HAS_VFPV2
210         default BR2_ARM_SOFT_FLOAT if !BR2_ARM_CPU_HAS_VFPV2
211
212 config BR2_ARM_SOFT_FLOAT
213         bool "Soft float"
214         depends on BR2_ARM_EABI
215         select BR2_SOFT_FLOAT
216         help
217           This option allows to use software emulated floating
218           point. It should be used for ARM cores that do not include a
219           Vector Floating Point unit, such as ARMv5 cores (ARM926 for
220           example) or certain ARMv6 cores.
221
222 config BR2_ARM_FPU_VFPV2
223         bool "VFPv2"
224         depends on BR2_ARM_CPU_HAS_VFPV2 || BR2_ARM_CPU_MAYBE_HAS_VFPV2
225         help
226           This option allows to use the VFPv2 floating point unit, as
227           available in some ARMv5 processors (ARM926EJ-S) and some
228           ARMv6 processors (ARM1136JF-S, ARM1176JZF-S and ARM11
229           MPCore).
230
231           Note that this option is also safe to use for newer cores
232           such as Cortex-A, because the VFPv3 and VFPv4 units are
233           backward compatible with VFPv2.
234
235 config BR2_ARM_FPU_VFPV3
236         bool "VFPv3"
237         depends on BR2_ARM_CPU_HAS_VFPV3 || BR2_ARM_CPU_MAYBE_HAS_VFPV3
238         help
239           This option allows to use the VFPv3 floating point unit, as
240           available in some ARMv7 processors (Cortex-A{8, 9}). This
241           option requires a VFPv3 unit that has 32 double-precision
242           registers, which is not necessarily the case in all SOCs
243           based on Cortex-A{8, 9}. If you're unsure, use VFPv3-D16
244           instead, which is guaranteed to work on all Cortex-A{8, 9}.
245
246           Note that this option is also safe to use for newer cores
247           that have a VFPv4 unit, because VFPv4 is backward compatible
248           with VFPv3. They must of course also have 32
249           double-precision registers.
250
251 config BR2_ARM_FPU_VFPV3D16
252         bool "VFPv3-D16"
253         depends on BR2_ARM_CPU_HAS_VFPV3 || BR2_ARM_CPU_MAYBE_HAS_VFPV3
254         help
255           This option allows to use the VFPv3 floating point unit, as
256           available in some ARMv7 processors (Cortex-A{8, 9}). This
257           option requires a VFPv3 unit that has 16 double-precision
258           registers, which is generally the case in all SOCs based on
259           Cortex-A{8, 9}, even though VFPv3 is technically optional on
260           Cortex-A9. This is the safest option for those cores.
261
262           Note that this option is also safe to use for newer cores
263           such that have a VFPv4 unit, because the VFPv4 is backward
264           compatible with VFPv3.
265
266 config BR2_ARM_FPU_VFPV4
267         bool "VFPv4"
268         depends on BR2_ARM_CPU_HAS_VFPV4 || BR2_ARM_CPU_MAYBE_HAS_VFPV4
269         help
270           This option allows to use the VFPv4 floating point unit, as
271           available in some ARMv7 processors (Cortex-A{5, 7, 12,
272           15}). This option requires a VFPv4 unit that has 32
273           double-precision registers, which is not necessarily the
274           case in all SOCs based on Cortex-A{5, 7, 12, 15}. If you're
275           unsure, you should probably use VFPv4-D16 instead.
276
277           Note that if you want binary code that works on all ARMv7
278           cores, including the earlier Cortex-A{8, 9}, you should
279           instead select VFPv3.
280
281 config BR2_ARM_FPU_VFPV4D16
282         bool "VFPv4-D16"
283         depends on BR2_ARM_CPU_HAS_VFPV4 || BR2_ARM_CPU_MAYBE_HAS_VFPV4
284         help
285           This option allows to use the VFPv4 floating point unit, as
286           available in some ARMv7 processors (Cortex-A{5, 7, 12,
287           15}). This option requires a VFPv4 unit that has 16
288           double-precision registers, which is always available on
289           Cortex-A12 and Cortex-A15, but optional on Cortex-A5 and
290           Cortex-A7.
291
292           Note that if you want binary code that works on all ARMv7
293           cores, including the earlier Cortex-A{8, 9}, you should
294           instead select VFPv3-D16.
295
296 config BR2_ARM_FPU_NEON
297         bool "NEON"
298         depends on BR2_ARM_CPU_HAS_NEON
299         help
300           This option allows to use the NEON SIMD unit, as available
301           in some ARMv7 processors, as a floating-point unit. It
302           should however be noted that using NEON for floating point
303           operations doesn't provide a complete compatibility with the
304           IEEE 754.
305
306 config BR2_ARM_FPU_NEON_VFPV4
307         bool "NEON/VFPv4"
308         depends on BR2_ARM_CPU_HAS_VFPV4 || BR2_ARM_CPU_MAYBE_HAS_VFPV4
309         depends on BR2_ARM_CPU_HAS_NEON
310         help
311           This option allows to use both the VFPv4 and the NEON SIMD
312           units for floating point operations. Note that some ARMv7
313           cores do not necessarily have VFPv4 and/or NEON support, for
314           example on Cortex-A5 and Cortex-A7, support for VFPv4 and
315           NEON is optional.
316
317 endchoice
318
319 choice
320         prompt "ARM instruction set"
321         depends on BR2_ARM_CPU_HAS_THUMB || BR2_ARM_CPU_HAS_THUMB2
322
323 config BR2_ARM_INSTRUCTIONS_ARM_CHOICE
324         bool "ARM"
325         help
326           This option instructs the compiler to generate regular ARM
327           instructions, that are all 32 bits wide.
328
329 config BR2_ARM_INSTRUCTIONS_THUMB
330         bool "Thumb"
331         depends on BR2_ARM_CPU_HAS_THUMB
332         help
333           This option instructions the compiler to generate Thumb
334           instructions, which allows to mix 16 bits instructions and
335           32 bits instructions. This generally provides a much smaller
336           compiled binary size.
337
338 config BR2_ARM_INSTRUCTIONS_THUMB2
339         bool "Thumb2"
340         depends on BR2_ARM_CPU_HAS_THUMB2
341         help
342           This option instructions the compiler to generate Thumb2
343           instructions, which allows to mix 16 bits instructions and
344           32 bits instructions. This generally provides a much smaller
345           compiled binary size.
346
347 endchoice
348
349 config BR2_ARM_INSTRUCTIONS_ARM
350         def_bool y
351         depends on !(BR2_ARM_INSTRUCTIONS_THUMB || BR2_ARM_INSTRUCTIONS_THUMB2)
352
353 config BR2_ARCH
354         default "arm"   if BR2_arm
355         default "armeb" if BR2_armeb
356
357 config BR2_ENDIAN
358         default "LITTLE" if BR2_arm
359         default "BIG"    if BR2_armeb
360
361 config BR2_ARCH_HAS_ATOMICS
362         default y
363
364 config BR2_GCC_TARGET_CPU
365         default "arm920t"       if BR2_arm920t
366         default "arm922t"       if BR2_arm922t
367         default "arm926ej-s"    if BR2_arm926t
368         default "arm1136j-s"    if BR2_arm1136j_s
369         default "arm1136jf-s"   if BR2_arm1136jf_s
370         default "arm1176jz-s"   if BR2_arm1176jz_s
371         default "arm1176jzf-s"  if BR2_arm1176jzf_s
372         default "cortex-a5"     if BR2_cortex_a5
373         default "cortex-a7"     if BR2_cortex_a7
374         default "cortex-a8"     if BR2_cortex_a8
375         default "cortex-a9"     if BR2_cortex_a9
376         default "cortex-a12"    if BR2_cortex_a12
377         default "cortex-a15"    if BR2_cortex_a15
378         default "fa526"         if BR2_fa526
379         default "marvell-pj4"   if BR2_pj4
380         default "strongarm"     if BR2_strongarm
381         default "xscale"        if BR2_xscale
382         default "iwmmxt"        if BR2_iwmmxt
383
384 config BR2_GCC_TARGET_ABI
385         default "aapcs-linux"
386
387 config BR2_GCC_TARGET_FPU
388         default "vfp"           if BR2_ARM_FPU_VFPV2
389         default "vfpv3"         if BR2_ARM_FPU_VFPV3
390         default "vfpv3-d16"     if BR2_ARM_FPU_VFPV3D16
391         default "vfpv4"         if BR2_ARM_FPU_VFPV4
392         default "vfpv4-d16"     if BR2_ARM_FPU_VFPV4D16
393         default "neon"          if BR2_ARM_FPU_NEON
394         default "neon-vfpv4"    if BR2_ARM_FPU_NEON_VFPV4
395
396 config BR2_GCC_TARGET_FLOAT_ABI
397         default "soft"          if BR2_ARM_SOFT_FLOAT
398         default "softfp"        if !BR2_ARM_SOFT_FLOAT && BR2_ARM_EABI
399         default "hard"          if !BR2_ARM_SOFT_FLOAT && BR2_ARM_EABIHF
400
401 config BR2_GCC_TARGET_MODE
402         default "arm"           if BR2_ARM_INSTRUCTIONS_ARM
403         default "thumb"         if BR2_ARM_INSTRUCTIONS_THUMB || BR2_ARM_INSTRUCTIONS_THUMB2