1DEFAULTTUNE ?= "armv7athf"
2ARM_INSTRUCTION_SET ?= "thumb"
3
4TUNEVALID[armv7a] = "Enable instructions for ARMv7-a"
5TUNECONFLICTS[armv7a] = "armv4 armv5 armv6 armv7"
6TUNE_CCARGS_MARCH .= "${@bb.utils.contains('TUNE_FEATURES', 'armv7a', ' -march=armv7-a', '', d)}"
7MACHINEOVERRIDES =. "${@bb.utils.contains('TUNE_FEATURES', 'armv7a', 'armv7a:', '', d)}"
8
9require conf/machine/include/arm/arch-armv6.inc
10require conf/machine/include/arm/feature-arm-neon.inc
11require conf/machine/include/arm/feature-arm-simd.inc
12
13# Little Endian base configs
14AVAILTUNES += "armv7a armv7at armv7a-vfpv3d16 armv7at-vfpv3d16 armv7a-vfpv3 armv7at-vfpv3 armv7a-vfpv4d16 armv7at-vfpv4d16 armv7a-neon armv7at-neon armv7a-neon-vfpv4 armv7at-neon-vfpv4"
15ARMPKGARCH:tune-armv7a             ?= "armv7a"
16ARMPKGARCH:tune-armv7at            ?= "armv7a"
17ARMPKGARCH:tune-armv7a-vfpv3d16    ?= "armv7a"
18ARMPKGARCH:tune-armv7at-vfpv3d16   ?= "armv7a"
19ARMPKGARCH:tune-armv7a-vfpv3       ?= "armv7a"
20ARMPKGARCH:tune-armv7at-vfpv3      ?= "armv7a"
21ARMPKGARCH:tune-armv7a-vfpv4d16    ?= "armv7a"
22ARMPKGARCH:tune-armv7at-vfpv4d16   ?= "armv7a"
23ARMPKGARCH:tune-armv7a-neon        ?= "armv7a"
24ARMPKGARCH:tune-armv7at-neon       ?= "armv7a"
25ARMPKGARCH:tune-armv7a-neon-vfpv4  ?= "armv7a"
26ARMPKGARCH:tune-armv7at-neon-vfpv4 ?= "armv7a"
27TUNE_FEATURES:tune-armv7a             = "arm armv7a vfp"
28TUNE_FEATURES:tune-armv7at            = "${TUNE_FEATURES:tune-armv7a} thumb"
29TUNE_FEATURES:tune-armv7a-vfpv3d16    = "${TUNE_FEATURES:tune-armv7a} vfpv3d16"
30TUNE_FEATURES:tune-armv7at-vfpv3d16   = "${TUNE_FEATURES:tune-armv7at} vfpv3d16"
31TUNE_FEATURES:tune-armv7a-vfpv3       = "${TUNE_FEATURES:tune-armv7a-vfpv3d16} vfpv3"
32TUNE_FEATURES:tune-armv7at-vfpv3      = "${TUNE_FEATURES:tune-armv7at-vfpv3d16} vfpv3"
33TUNE_FEATURES:tune-armv7a-vfpv4d16    = "${TUNE_FEATURES:tune-armv7a} vfpv4d16"
34TUNE_FEATURES:tune-armv7at-vfpv4d16   = "${TUNE_FEATURES:tune-armv7at} vfpv4d16"
35TUNE_FEATURES:tune-armv7a-neon        = "${TUNE_FEATURES:tune-armv7a} neon"
36TUNE_FEATURES:tune-armv7at-neon       = "${TUNE_FEATURES:tune-armv7at} neon"
37TUNE_FEATURES:tune-armv7a-neon-vfpv4  = "${TUNE_FEATURES:tune-armv7a-neon} vfpv4"
38TUNE_FEATURES:tune-armv7at-neon-vfpv4 = "${TUNE_FEATURES:tune-armv7at-neon} vfpv4"
39PACKAGE_EXTRA_ARCHS:tune-armv7a             = "${PACKAGE_EXTRA_ARCHS:tune-armv6} armv7a armv7a-vfp"
40PACKAGE_EXTRA_ARCHS:tune-armv7at            = "${PACKAGE_EXTRA_ARCHS:tune-armv6t} armv7a armv7a-vfp armv7at2-vfp"
41PACKAGE_EXTRA_ARCHS:tune-armv7a-vfpv3d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7a} armv7a-vfpv3d16"
42PACKAGE_EXTRA_ARCHS:tune-armv7at-vfpv3d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7at} armv7a-vfpv3d16 armv7at2-vfpv3d16"
43PACKAGE_EXTRA_ARCHS:tune-armv7a-vfpv3       = "${PACKAGE_EXTRA_ARCHS:tune-armv7a-vfpv3d16} armv7a-vfpv3"
44PACKAGE_EXTRA_ARCHS:tune-armv7at-vfpv3      = "${PACKAGE_EXTRA_ARCHS:tune-armv7at-vfpv3d16} armv7a-vfpv3 armv7at2-vfpv3"
45PACKAGE_EXTRA_ARCHS:tune-armv7a-vfpv4d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7a} armv7a-vfpv4d16"
46PACKAGE_EXTRA_ARCHS:tune-armv7at-vfpv4d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7at} armv7a-vfpv4d16 armv7at2-vfpv4d16"
47PACKAGE_EXTRA_ARCHS:tune-armv7a-neon        = "${PACKAGE_EXTRA_ARCHS:tune-armv7a} armv7a-neon"
48PACKAGE_EXTRA_ARCHS:tune-armv7at-neon       = "${PACKAGE_EXTRA_ARCHS:tune-armv7at} armv7a-neon armv7at2-neon"
49PACKAGE_EXTRA_ARCHS:tune-armv7a-neon-vfpv4  = "${PACKAGE_EXTRA_ARCHS:tune-armv7a-neon} armv7a-neon-vfpv4"
50PACKAGE_EXTRA_ARCHS:tune-armv7at-neon-vfpv4 = "${PACKAGE_EXTRA_ARCHS:tune-armv7at-neon} armv7a-neon-vfpv4 armv7at2-neon-vfpv4"
51
52# HF Tunes
53AVAILTUNES += "armv7ahf armv7athf armv7ahf-vfpv3d16 armv7athf-vfpv3d16 armv7ahf-vfpv3 armv7athf-vfpv3 armv7ahf-vfpv4d16 armv7athf-vfpv4d16 armv7ahf-neon armv7athf-neon armv7ahf-neon-vfpv4 armv7athf-neon-vfpv4"
54ARMPKGARCH:tune-armv7ahf             ?= "armv7a"
55ARMPKGARCH:tune-armv7athf            ?= "armv7a"
56ARMPKGARCH:tune-armv7ahf-vfpv3d16    ?= "armv7a"
57ARMPKGARCH:tune-armv7athf-vfpv3d16   ?= "armv7a"
58ARMPKGARCH:tune-armv7ahf-vfpv3       ?= "armv7a"
59ARMPKGARCH:tune-armv7athf-vfpv3      ?= "armv7a"
60ARMPKGARCH:tune-armv7ahf-vfpv4d16    ?= "armv7a"
61ARMPKGARCH:tune-armv7athf-vfpv4d16   ?= "armv7a"
62ARMPKGARCH:tune-armv7ahf-neon        ?= "armv7a"
63ARMPKGARCH:tune-armv7athf-neon       ?= "armv7a"
64ARMPKGARCH:tune-armv7ahf-neon-vfpv4  ?= "armv7a"
65ARMPKGARCH:tune-armv7athf-neon-vfpv4 ?= "armv7a"
66TUNE_FEATURES:tune-armv7ahf             = "${TUNE_FEATURES:tune-armv7a} callconvention-hard"
67TUNE_FEATURES:tune-armv7athf            = "${TUNE_FEATURES:tune-armv7at} callconvention-hard"
68TUNE_FEATURES:tune-armv7ahf-vfpv3d16    = "${TUNE_FEATURES:tune-armv7a-vfpv3d16} callconvention-hard"
69TUNE_FEATURES:tune-armv7athf-vfpv3d16   = "${TUNE_FEATURES:tune-armv7at-vfpv3d16} callconvention-hard"
70TUNE_FEATURES:tune-armv7ahf-vfpv3       = "${TUNE_FEATURES:tune-armv7a-vfpv3} callconvention-hard"
71TUNE_FEATURES:tune-armv7athf-vfpv3      = "${TUNE_FEATURES:tune-armv7at-vfpv3} callconvention-hard"
72TUNE_FEATURES:tune-armv7ahf-vfpv4d16    = "${TUNE_FEATURES:tune-armv7a-vfpv4d16} callconvention-hard"
73TUNE_FEATURES:tune-armv7athf-vfpv4d16   = "${TUNE_FEATURES:tune-armv7at-vfpv4d16} callconvention-hard"
74TUNE_FEATURES:tune-armv7ahf-neon        = "${TUNE_FEATURES:tune-armv7a-neon} callconvention-hard"
75TUNE_FEATURES:tune-armv7athf-neon       = "${TUNE_FEATURES:tune-armv7at-neon} callconvention-hard"
76TUNE_FEATURES:tune-armv7ahf-neon-vfpv4  = "${TUNE_FEATURES:tune-armv7a-neon-vfpv4} callconvention-hard"
77TUNE_FEATURES:tune-armv7athf-neon-vfpv4 = "${TUNE_FEATURES:tune-armv7at-neon-vfpv4} callconvention-hard"
78PACKAGE_EXTRA_ARCHS:tune-armv7ahf             = "${PACKAGE_EXTRA_ARCHS:tune-armv6hf} armv7ahf-vfp"
79PACKAGE_EXTRA_ARCHS:tune-armv7athf            = "${PACKAGE_EXTRA_ARCHS:tune-armv6thf} armv7ahf-vfp armv7at2hf-vfp"
80PACKAGE_EXTRA_ARCHS:tune-armv7ahf-vfpv3d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahf} armv7ahf-vfpv3d16"
81PACKAGE_EXTRA_ARCHS:tune-armv7athf-vfpv3d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7athf} armv7ahf-vfpv3d16 armv7at2hf-vfpv3d16"
82PACKAGE_EXTRA_ARCHS:tune-armv7ahf-vfpv3       = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahf-vfpv3d16} armv7ahf-vfpv3"
83PACKAGE_EXTRA_ARCHS:tune-armv7athf-vfpv3      = "${PACKAGE_EXTRA_ARCHS:tune-armv7athf-vfpv3d16} armv7ahf-vfpv3 armv7at2hf-vfpv3"
84PACKAGE_EXTRA_ARCHS:tune-armv7ahf-vfpv4d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahf} armv7ahf-vfpv4d16"
85PACKAGE_EXTRA_ARCHS:tune-armv7athf-vfpv4d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7athf} armv7ahf-vfpv4d16 armv7at2hf-vfpv4d16"
86PACKAGE_EXTRA_ARCHS:tune-armv7ahf-neon        = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahf} armv7ahf-neon"
87PACKAGE_EXTRA_ARCHS:tune-armv7athf-neon       = "${PACKAGE_EXTRA_ARCHS:tune-armv7athf} armv7ahf-neon armv7at2hf-neon"
88PACKAGE_EXTRA_ARCHS:tune-armv7ahf-neon-vfpv4  = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahf-neon} armv7ahf-neon-vfpv4"
89PACKAGE_EXTRA_ARCHS:tune-armv7athf-neon-vfpv4 = "${PACKAGE_EXTRA_ARCHS:tune-armv7athf-neon} armv7ahf-neon-vfpv4 armv7at2hf-neon-vfpv4"
90
91# Big Endian
92AVAILTUNES += "armv7ab armv7atb armv7ab-vfpv3d16 armv7atb-vfpv3d16 armv7ab-vfpv3 armv7atb-vfpv3 armv7ab-vfpv4d16 armv7atb-vfpv4d16 armv7ab-neon armv7atb-neon armv7ab-neon-vfpv4 armv7atb-neon-vfpv4"
93ARMPKGARCH:tune-armv7ab             ?= "armv7a"
94ARMPKGARCH:tune-armv7atb            ?= "armv7a"
95ARMPKGARCH:tune-armv7ab-vfpv3d16    ?= "armv7a"
96ARMPKGARCH:tune-armv7atb-vfpv3d16   ?= "armv7a"
97ARMPKGARCH:tune-armv7ab-vfpv3       ?= "armv7a"
98ARMPKGARCH:tune-armv7atb-vfpv3      ?= "armv7a"
99ARMPKGARCH:tune-armv7ab-vfpv4d16    ?= "armv7a"
100ARMPKGARCH:tune-armv7atb-vfpv4d16   ?= "armv7a"
101ARMPKGARCH:tune-armv7ab-neon        ?= "armv7a"
102ARMPKGARCH:tune-armv7atb-neon       ?= "armv7a"
103ARMPKGARCH:tune-armv7ab-neon-vfpv4  ?= "armv7a"
104ARMPKGARCH:tune-armv7atb-neon-vfpv4 ?= "armv7a"
105TUNE_FEATURES:tune-armv7ab             = "${TUNE_FEATURES:tune-armv7a} bigendian"
106TUNE_FEATURES:tune-armv7atb            = "${TUNE_FEATURES:tune-armv7at} bigendian"
107TUNE_FEATURES:tune-armv7ab-vfpv3d16    = "${TUNE_FEATURES:tune-armv7a-vfpv3d16} bigendian"
108TUNE_FEATURES:tune-armv7atb-vfpv3d16   = "${TUNE_FEATURES:tune-armv7at-vfpv3d16} bigendian"
109TUNE_FEATURES:tune-armv7ab-vfpv3       = "${TUNE_FEATURES:tune-armv7a-vfpv3} bigendian"
110TUNE_FEATURES:tune-armv7atb-vfpv3      = "${TUNE_FEATURES:tune-armv7at-vfpv3} bigendian"
111TUNE_FEATURES:tune-armv7ab-vfpv4d16    = "${TUNE_FEATURES:tune-armv7a-vfpv4d16} bigendian"
112TUNE_FEATURES:tune-armv7atb-vfpv4d16   = "${TUNE_FEATURES:tune-armv7at-vfpv4d16} bigendian"
113TUNE_FEATURES:tune-armv7ab-neon        = "${TUNE_FEATURES:tune-armv7a-neon} bigendian"
114TUNE_FEATURES:tune-armv7atb-neon       = "${TUNE_FEATURES:tune-armv7at-neon} bigendian"
115TUNE_FEATURES:tune-armv7ab-neon-vfpv4  = "${TUNE_FEATURES:tune-armv7a-neon-vfpv4} bigendian"
116TUNE_FEATURES:tune-armv7atb-neon-vfpv4 = "${TUNE_FEATURES:tune-armv7at-neon-vfpv4} bigendian"
117PACKAGE_EXTRA_ARCHS:tune-armv7ab             = "${PACKAGE_EXTRA_ARCHS:tune-armv6b} armv7ab-vfp"
118PACKAGE_EXTRA_ARCHS:tune-armv7atb            = "${PACKAGE_EXTRA_ARCHS:tune-armv6tb} armv7ab-vfp armv7at2b-vfp"
119PACKAGE_EXTRA_ARCHS:tune-armv7ab-vfpv3d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7ab} armv7ab-vfpv3d16"
120PACKAGE_EXTRA_ARCHS:tune-armv7atb-vfpv3d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7atb} armv7ab-vfpv3d16 armv7at2b-vfpv3d16"
121PACKAGE_EXTRA_ARCHS:tune-armv7ab-vfpv3       = "${PACKAGE_EXTRA_ARCHS:tune-armv7ab-vfpv3d16} armv7ab-vfpv3"
122PACKAGE_EXTRA_ARCHS:tune-armv7atb-vfpv3      = "${PACKAGE_EXTRA_ARCHS:tune-armv7atb-vfpv3d16} armv7ab-vfpv3 armv7at2b-vfpv3"
123PACKAGE_EXTRA_ARCHS:tune-armv7ab-vfpv4d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7ab} armv7ab-vfpv4d16"
124PACKAGE_EXTRA_ARCHS:tune-armv7atb-vfpv4d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7atb} armv7ab-vfpv4d16 armv7at2b-vfpv4d16"
125PACKAGE_EXTRA_ARCHS:tune-armv7ab-neon        = "${PACKAGE_EXTRA_ARCHS:tune-armv7ab} armv7ab-neon"
126PACKAGE_EXTRA_ARCHS:tune-armv7atb-neon       = "${PACKAGE_EXTRA_ARCHS:tune-armv7atb} armv7ab-neon armv7at2b-neon"
127PACKAGE_EXTRA_ARCHS:tune-armv7ab-neon-vfpv4  = "${PACKAGE_EXTRA_ARCHS:tune-armv7ab-neon} armv7ab-neon-vfpv4"
128PACKAGE_EXTRA_ARCHS:tune-armv7atb-neon-vfpv4 = "${PACKAGE_EXTRA_ARCHS:tune-armv7atb-neon} armv7ab-neon-vfpv4 armv7at2b-neon-vfpv4"
129
130# Big Endian + HF
131AVAILTUNES += "armv7ahfb armv7athfb armv7ahfb-vfpv3d16 armv7athfb-vfpv3d16 armv7ahfb-vfpv3 armv7athfb-vfpv3 armv7ahfb-vfpv4d16 armv7athfb-vfpv4d16 armv7ahfb-neon armv7athfb-neon armv7ahfb-neon-vfpv4 armv7athfb-neon-vfpv4"
132ARMPKGARCH:tune-armv7ahfb             ?= "armv7a"
133ARMPKGARCH:tune-armv7athfb            ?= "armv7a"
134ARMPKGARCH:tune-armv7ahfb-vfpv3d16    ?= "armv7a"
135ARMPKGARCH:tune-armv7athfb-vfpv3d16   ?= "armv7a"
136ARMPKGARCH:tune-armv7ahfb-vfpv3       ?= "armv7a"
137ARMPKGARCH:tune-armv7athfb-vfpv3      ?= "armv7a"
138ARMPKGARCH:tune-armv7ahfb-vfpv4d16    ?= "armv7a"
139ARMPKGARCH:tune-armv7athfb-vfpv4d16   ?= "armv7a"
140ARMPKGARCH:tune-armv7ahfb-neon        ?= "armv7a"
141ARMPKGARCH:tune-armv7athfb-neon       ?= "armv7a"
142ARMPKGARCH:tune-armv7ahfb-neon-vfpv4  ?= "armv7a"
143ARMPKGARCH:tune-armv7athfb-neon-vfpv4 ?= "armv7a"
144TUNE_FEATURES:tune-armv7ahfb             = "${TUNE_FEATURES:tune-armv7ahf} bigendian"
145TUNE_FEATURES:tune-armv7athfb            = "${TUNE_FEATURES:tune-armv7athf} bigendian"
146TUNE_FEATURES:tune-armv7ahfb-vfpv3d16    = "${TUNE_FEATURES:tune-armv7ahf-vfpv3d16} bigendian"
147TUNE_FEATURES:tune-armv7athfb-vfpv3d16   = "${TUNE_FEATURES:tune-armv7athf-vfpv3d16} bigendian"
148TUNE_FEATURES:tune-armv7ahfb-vfpv3       = "${TUNE_FEATURES:tune-armv7ahf-vfpv3} bigendian"
149TUNE_FEATURES:tune-armv7athfb-vfpv3      = "${TUNE_FEATURES:tune-armv7athf-vfpv3} bigendian"
150TUNE_FEATURES:tune-armv7ahfb-vfpv4d16    = "${TUNE_FEATURES:tune-armv7ahf-vfpv4d16} bigendian"
151TUNE_FEATURES:tune-armv7athfb-vfpv4d16   = "${TUNE_FEATURES:tune-armv7athf-vfpv4d16} bigendian"
152TUNE_FEATURES:tune-armv7ahfb-neon        = "${TUNE_FEATURES:tune-armv7ahf-neon} bigendian"
153TUNE_FEATURES:tune-armv7athfb-neon       = "${TUNE_FEATURES:tune-armv7athf-neon} bigendian"
154TUNE_FEATURES:tune-armv7ahfb-neon-vfpv4  = "${TUNE_FEATURES:tune-armv7ahf-neon-vfpv4} bigendian"
155TUNE_FEATURES:tune-armv7athfb-neon-vfpv4 = "${TUNE_FEATURES:tune-armv7athf-neon-vfpv4} bigendian"
156PACKAGE_EXTRA_ARCHS:tune-armv7ahfb             = "${PACKAGE_EXTRA_ARCHS:tune-armv6hfb} armv7ahfb-vfp"
157PACKAGE_EXTRA_ARCHS:tune-armv7athfb            = "${PACKAGE_EXTRA_ARCHS:tune-armv6thfb} armv7ahfb-vfp armv7at2hfb-vfp"
158PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-vfpv3d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahfb} armv7ahfb-vfpv3d16"
159PACKAGE_EXTRA_ARCHS:tune-armv7athfb-vfpv3d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7athfb} armv7ahfb-vfpv3d16 armv7at2hfb-vfpv3d16"
160PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-vfpv3       = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-vfpv3d16} armv7ahfb-vfpv3"
161PACKAGE_EXTRA_ARCHS:tune-armv7athfb-vfpv3      = "${PACKAGE_EXTRA_ARCHS:tune-armv7athfb-vfpv3d16} armv7ahfb-vfpv3 armv7at2hfb-vfpv3"
162PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-vfpv4d16    = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahfb} armv7ahfb-vfpv4d16"
163PACKAGE_EXTRA_ARCHS:tune-armv7athfb-vfpv4d16   = "${PACKAGE_EXTRA_ARCHS:tune-armv7athfb} armv7ahfb-vfpv4d16 armv7at2hfb-vfpv4d16"
164PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-neon        = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahfb} armv7ahfb-neon"
165PACKAGE_EXTRA_ARCHS:tune-armv7athfb-neon       = "${PACKAGE_EXTRA_ARCHS:tune-armv7athfb} armv7ahfb-neon armv7at2hfb-neon"
166PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-neon-vfpv4  = "${PACKAGE_EXTRA_ARCHS:tune-armv7ahfb-neon} armv7ahfb-neon-vfpv4"
167PACKAGE_EXTRA_ARCHS:tune-armv7athfb-neon-vfpv4 = "${PACKAGE_EXTRA_ARCHS:tune-armv7athfb-neon} armv7ahfb-neon-vfpv4 armv7at2hfb-neon-vfpv4"
168