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 if (cpu_arch == "arm") { | 5 if (cpu_arch == "arm") { |
6 declare_args() { | 6 declare_args() { |
7 # Version of the ARM processor when compiling on ARM. Ignored on non-ARM | 7 # Version of the ARM processor when compiling on ARM. Ignored on non-ARM |
8 # platforms. | 8 # platforms. |
9 arm_version = 7 | 9 arm_version = 7 |
10 | 10 |
11 # The ARM floating point mode. This is either the string "hard", "soft", or | 11 # The ARM floating point mode. This is either the string "hard", "soft", or |
12 # "softfp". An empty string means to use the default one for the | 12 # "softfp". An empty string means to use the default one for the |
13 # arm_version. | 13 # arm_version. |
14 arm_float_abi = "" | 14 arm_float_abi = "" |
15 } | 15 } |
16 | 16 |
17 assert(arm_float_abi == "" || | 17 assert(arm_float_abi == "" || |
18 arm_float_abi == "hard" || | 18 arm_float_abi == "hard" || |
19 arm_float_abi == "soft" || | 19 arm_float_abi == "soft" || |
20 arm_float_abi == "softfp") | 20 arm_float_abi == "softfp") |
21 | 21 |
22 if (is_android) { | 22 if (is_android) { |
23 arm_use_neon = false | 23 arm_use_neon = false |
24 # Our version of arm_neon_optional from common.gypi. This is not used in the | 24 arm_optionally_use_neon = false |
25 # current build so is commented out for now. | |
26 #arm_optionally_use_neon = false | |
27 } else { | 25 } else { |
28 arm_use_neon = true | 26 arm_use_neon = true |
29 #arm_optionally_use_neon = true | 27 arm_optionally_use_neon = true |
30 } | 28 } |
31 | 29 |
32 if (arm_version == 6) { | 30 if (arm_version == 6) { |
33 arm_arch = "armv6" | 31 arm_arch = "armv6" |
34 arm_tune = "" | 32 arm_tune = "" |
35 if (arm_float_abi == "") { | 33 if (arm_float_abi == "") { |
36 arm_float_abi = "softfp" | 34 arm_float_abi = "softfp" |
37 } | 35 } |
38 arm_fpu = "vfp" | 36 arm_fpu = "vfp" |
39 # Thumb is a reduced instruction set available on some ARM processors that | 37 # Thumb is a reduced instruction set available on some ARM processors that |
40 # has increased code density. | 38 # has increased code density. |
41 arm_use_thumb = false | 39 arm_use_thumb = false |
42 | 40 |
43 } else if (arm_version == 7) { | 41 } else if (arm_version == 7) { |
44 arm_arch = "armv7-a" | 42 arm_arch = "armv7-a" |
45 arm_tune = "" | 43 arm_tune = "" |
46 if (arm_float_abi == "") { | 44 if (arm_float_abi == "") { |
47 arm_float_abi = "softfp" | 45 arm_float_abi = "softfp" |
48 } | 46 } |
49 arm_use_thumb = true | 47 arm_use_thumb = true |
50 | 48 |
51 if (arm_use_neon) { | 49 if (arm_use_neon) { |
52 arm_fpu = "neon" | 50 arm_fpu = "neon" |
53 } else { | 51 } else { |
54 arm_fpu = "vfpv3-d16" | 52 arm_fpu = "vfpv3-d16" |
55 } | 53 } |
56 } | 54 } |
57 } | 55 } |
OLD | NEW |