OLD | NEW |
---|---|
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/android/config.gni") | 5 import("//build/config/android/config.gni") |
6 import("//build/config/arm.gni") | 6 import("//build/config/arm.gni") |
7 import("//build/config/mips.gni") | 7 import("//build/config/mips.gni") |
8 import("//build/config/sanitizers/sanitizers.gni") | 8 import("//build/config/sanitizers/sanitizers.gni") |
9 | 9 |
10 if (is_android) { | 10 if (is_android) { |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
136 } | 136 } |
137 } | 137 } |
138 | 138 |
139 config("toolchain") { | 139 config("toolchain") { |
140 visibility = [ ":*" ] # Only targets in this file can depend on this. | 140 visibility = [ ":*" ] # Only targets in this file can depend on this. |
141 | 141 |
142 defines = [] | 142 defines = [] |
143 cflags = [] | 143 cflags = [] |
144 | 144 |
145 # TODO(jochen): Add support for arm subarchs, mips, mipsel, mips64el. | 145 # TODO(jochen): Add support for arm subarchs, mips, mipsel, mips64el. |
146 | |
147 if (v8_target_arch == "arm") { | 146 if (v8_target_arch == "arm") { |
148 defines += [ "V8_TARGET_ARCH_ARM" ] | 147 defines += [ "V8_TARGET_ARCH_ARM" ] |
149 if (current_cpu == "arm") { | 148 if (current_cpu == "arm") { |
150 if (arm_version == 7) { | 149 if (arm_version == 7) { |
151 defines += [ "CAN_USE_ARMV7_INSTRUCTIONS" ] | 150 defines += [ "CAN_USE_ARMV7_INSTRUCTIONS" ] |
152 } | 151 } |
153 if (arm_fpu == "vfpv3-d16") { | 152 if (arm_fpu == "vfpv3-d16") { |
154 defines += [ "CAN_USE_VFP3_INSTRUCTIONS" ] | 153 defines += [ "CAN_USE_VFP3_INSTRUCTIONS" ] |
155 } else if (arm_fpu == "vfpv3") { | 154 } else if (arm_fpu == "vfpv3") { |
156 defines += [ | 155 defines += [ |
157 "CAN_USE_VFP3_INSTRUCTIONS", | 156 "CAN_USE_VFP3_INSTRUCTIONS", |
158 "CAN_USE_VFP32DREGS", | 157 "CAN_USE_VFP32DREGS", |
159 ] | 158 ] |
160 } else if (arm_fpu == "neon") { | 159 } else if (arm_fpu == "neon") { |
161 defines += [ | 160 defines += [ |
162 "CAN_USE_VFP3_INSTRUCTIONS", | 161 "CAN_USE_VFP3_INSTRUCTIONS", |
163 "CAN_USE_VFP32DREGS", | 162 "CAN_USE_VFP32DREGS", |
164 "CAN_USE_NEON", | 163 "CAN_USE_NEON", |
165 ] | 164 ] |
166 } | 165 } |
167 } else { | 166 } else { |
168 # These defines ares used for the ARM simulator. | 167 # These defines ares used for the ARM simulator. |
169 defines += [ | 168 defines += [ |
170 "CAN_USE_ARMV7_INSTRUCTIONS", | 169 "CAN_USE_ARMV7_INSTRUCTIONS", |
171 "CAN_USE_VFP3_INSTRUCTIONS", | 170 "CAN_USE_VFP3_INSTRUCTIONS", |
172 "CAN_USE_VFP32DREGS", | 171 "CAN_USE_VFP32DREGS", |
173 "USE_EABI_HARDFLOAT=0", | |
174 ] | 172 ] |
173 | |
174 if (arm_float_abi == "hard") { | |
slan
2016/03/29 17:03:23
Although this passes all the tryjobs, I've just di
Dirk Pranke
2016/03/29 21:03:40
I assume you mean "(when current_cpu is "x86" or "
slan
2016/03/29 23:45:08
Yes, that is what I meant! Thanks for seeing throu
| |
175 defines += [ "USE_EABI_HARDFLOAT=1" ] | |
176 } else if (arm_float_abi == "softfp") { | |
177 defines += [ "USE_EABI_HARDFLOAT=0" ] | |
178 } | |
175 } | 179 } |
176 | 180 |
177 # TODO(jochen): Add support for arm_test_noprobe. | 181 # TODO(jochen): Add support for arm_test_noprobe. |
178 } | 182 } |
179 if (v8_target_arch == "arm64") { | 183 if (v8_target_arch == "arm64") { |
180 defines += [ "V8_TARGET_ARCH_ARM64" ] | 184 defines += [ "V8_TARGET_ARCH_ARM64" ] |
181 } | 185 } |
182 if (v8_target_arch == "mipsel") { | 186 if (v8_target_arch == "mipsel") { |
183 defines += [ "V8_TARGET_ARCH_MIPS" ] | 187 defines += [ "V8_TARGET_ARCH_MIPS" ] |
184 } | 188 } |
185 if (v8_target_arch == "mips64el") { | 189 if (v8_target_arch == "mips64el") { |
186 defines += [ "V8_TARGET_ARCH_MIPS64" ] | 190 defines += [ "V8_TARGET_ARCH_MIPS64" ] |
187 } | 191 } |
188 if (v8_target_arch == "s390") { | 192 if (v8_target_arch == "s390") { |
189 defines += [ "V8_TARGET_ARCH_S390" ] | 193 defines += [ "V8_TARGET_ARCH_S390" ] |
190 } | 194 } |
191 if (v8_target_arch == "s390x") { | 195 if (v8_target_arch == "s390x") { |
192 defines += [ | 196 defines += [ |
193 "V8_TARGET_ARCH_S390", | 197 "V8_TARGET_ARCH_S390", |
194 "V8_TARGET_ARCH_S390X", | 198 "V8_TARGET_ARCH_S390X", |
195 ] | 199 ] |
196 } | 200 } |
197 if (v8_target_arch == "x86") { | 201 if (v8_target_arch == "x86") { |
198 defines += [ "V8_TARGET_ARCH_IA32" ] | 202 defines += [ "V8_TARGET_ARCH_IA32" ] |
199 } | 203 } |
200 if (v8_target_arch == "x64") { | 204 if (v8_target_arch == "x64") { |
201 defines += [ "V8_TARGET_ARCH_X64" ] | 205 defines += [ "V8_TARGET_ARCH_X64" ] |
202 } | 206 } |
203 | 207 |
204 if (is_win) { | 208 if (is_win) { |
205 defines += [ "WIN32" ] | 209 defines += [ "WIN32" ] |
206 # TODO(jochen): Support v8_enable_prof. | 210 # TODO(jochen): Support v8_enable_prof. |
207 } | 211 } |
208 | 212 |
209 # TODO(jochen): Add support for compiling with simulators. | 213 # TODO(jochen): Add support for compiling with simulators. |
210 | 214 |
211 if (is_debug) { | 215 if (is_debug) { |
212 # TODO(jochen): Add support for different debug optimization levels. | 216 # TODO(jochen): Add support for different debug optimization levels. |
213 defines += [ | 217 defines += [ |
(...skipping 1881 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2095 | 2099 |
2096 configs -= [ "//build/config/compiler:chromium_code" ] | 2100 configs -= [ "//build/config/compiler:chromium_code" ] |
2097 configs += [ "//build/config/compiler:no_chromium_code" ] | 2101 configs += [ "//build/config/compiler:no_chromium_code" ] |
2098 configs += [ | 2102 configs += [ |
2099 ":internal_config", | 2103 ":internal_config", |
2100 ":libplatform_config", | 2104 ":libplatform_config", |
2101 ":features", | 2105 ":features", |
2102 ":toolchain", | 2106 ":toolchain", |
2103 ] | 2107 ] |
2104 } | 2108 } |
OLD | NEW |