Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(921)

Side by Side Diff: build/common.gypi

Issue 1702009: Add a gyp flag for disabling sse2. This makes it easier for (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2010 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 # IMPORTANT: 5 # IMPORTANT:
6 # Please don't directly include this file if you are building via gyp_chromium, 6 # Please don't directly include this file if you are building via gyp_chromium,
7 # since gyp_chromium is automatically forcing its inclusion. 7 # since gyp_chromium is automatically forcing its inclusion.
8 { 8 {
9 'variables': { 9 'variables': {
10 # .gyp files or targets should set chromium_code to 1 if they build 10 # .gyp files or targets should set chromium_code to 1 if they build
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 'python_ver%': '2.5', 99 'python_ver%': '2.5',
100 100
101 # Set ARM-v7 compilation flags 101 # Set ARM-v7 compilation flags
102 'armv7%': 0, 102 'armv7%': 0,
103 103
104 # Set Neon compilation flags (only meaningful if armv7==1). 104 # Set Neon compilation flags (only meaningful if armv7==1).
105 'arm_neon%': 1, 105 'arm_neon%': 1,
106 106
107 # The system root for cross-compiles. Default: none. 107 # The system root for cross-compiles. Default: none.
108 'sysroot%': '', 108 'sysroot%': '',
109
110 # On Linux, we build with sse2 for Chromium builds.
111 'disable_sse2%': 0,
109 }, 112 },
110 113
111 # Define branding and buildtype on the basis of their settings within the 114 # Define branding and buildtype on the basis of their settings within the
112 # variables sub-dict above, unless overridden. 115 # variables sub-dict above, unless overridden.
113 'branding%': '<(branding)', 116 'branding%': '<(branding)',
114 'buildtype%': '<(buildtype)', 117 'buildtype%': '<(buildtype)',
115 'target_arch%': '<(target_arch)', 118 'target_arch%': '<(target_arch)',
116 'host_arch%': '<(host_arch)', 119 'host_arch%': '<(host_arch)',
117 'toolkit_views%': '<(toolkit_views)', 120 'toolkit_views%': '<(toolkit_views)',
118 'chromeos%': '<(chromeos)', 121 'chromeos%': '<(chromeos)',
119 'inside_chromium_build%': '<(inside_chromium_build)', 122 'inside_chromium_build%': '<(inside_chromium_build)',
120 'fastbuild%': '<(fastbuild)', 123 'fastbuild%': '<(fastbuild)',
121 'linux_fpic%': '<(linux_fpic)', 124 'linux_fpic%': '<(linux_fpic)',
122 'python_ver%': '<(python_ver)', 125 'python_ver%': '<(python_ver)',
123 'armv7%': '<(armv7)', 126 'armv7%': '<(armv7)',
124 'arm_neon%': '<(arm_neon)', 127 'arm_neon%': '<(arm_neon)',
125 'sysroot%': '<(sysroot)', 128 'sysroot%': '<(sysroot)',
129 'disable_sse2%': '<(disable_sse2)',
126 130
127 # The release channel that this build targets. This is used to restrict 131 # The release channel that this build targets. This is used to restrict
128 # channel-specific build options, like which installer packages to create. 132 # channel-specific build options, like which installer packages to create.
129 # The default is 'all', which does no channel-specific filtering. 133 # The default is 'all', which does no channel-specific filtering.
130 'channel%': 'all', 134 'channel%': 'all',
131 135
132 # Override chromium_mac_pch and set it to 0 to suppress the use of 136 # Override chromium_mac_pch and set it to 0 to suppress the use of
133 # precompiled headers on the Mac. Prefix header injection may still be 137 # precompiled headers on the Mac. Prefix header injection may still be
134 # used, but prefix headers will not be precompiled. This is useful when 138 # used, but prefix headers will not be precompiled. This is useful when
135 # using distcc to distribute a build to compile slaves that don't 139 # using distcc to distribute a build to compile slaves that don't
(...skipping 773 matching lines...) Expand 10 before | Expand all | Expand 10 after
909 # performance penalty. 913 # performance penalty.
910 # 914 #
911 # -mfpmath=sse -msse2 makes the compiler use SSE instructions 915 # -mfpmath=sse -msse2 makes the compiler use SSE instructions
912 # which keep floating-point values in SSE registers in its 916 # which keep floating-point values in SSE registers in its
913 # native precision (32-bit for single precision, and 64-bit for 917 # native precision (32-bit for single precision, and 64-bit for
914 # double precision values). This means the floating-point value 918 # double precision values). This means the floating-point value
915 # used during computation does not change depending on how the 919 # used during computation does not change depending on how the
916 # compiler optimized the code, since the value is always kept 920 # compiler optimized the code, since the value is always kept
917 # in its specified precision. 921 # in its specified precision.
918 'conditions': [ 922 'conditions': [
919 ['branding=="Chromium"', { 923 ['branding=="Chromium" and disable_sse2==0', {
920 'cflags': [ 924 'cflags': [
921 '-march=pentium4', 925 '-march=pentium4',
agl 2010/04/27 14:07:08 This knocks out rather more than just SSE2, but wh
922 '-msse2', 926 '-msse2',
923 '-mfpmath=sse', 927 '-mfpmath=sse',
924 ], 928 ],
925 }], 929 }],
926 # ChromeOS targets Pinetrail, which is ssse3, but most of the 930 # ChromeOS targets Pinetrail, which is ssse3, but most of the
927 # benefit comes from sse2 so this setting allows ChromeOS 931 # benefit comes from sse2 so this setting allows ChromeOS
928 # to build on other CPUs. In the future -march=atom would help 932 # to build on other CPUs. In the future -march=atom would help
929 # but requires a newer compiler. 933 # but requires a newer compiler.
930 ['chromeos==1', { 934 ['chromeos==1 and disable_sse2==0', {
931 'cflags': [ 935 'cflags': [
932 '-msse2', 936 '-msse2',
933 ], 937 ],
934 }], 938 }],
935 ], 939 ],
936 # -mmmx allows mmintrin.h to be used for mmx intrinsics. 940 # -mmmx allows mmintrin.h to be used for mmx intrinsics.
937 # video playback is mmx and sse2 optimized. 941 # video playback is mmx and sse2 optimized.
938 'cflags': [ 942 'cflags': [
939 '-m32', 943 '-m32',
940 '-mmmx', 944 '-mmmx',
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after
1305 # and therefore SYMROOT, needs to be set at the project level. 1309 # and therefore SYMROOT, needs to be set at the project level.
1306 'SYMROOT': '<(DEPTH)/xcodebuild', 1310 'SYMROOT': '<(DEPTH)/xcodebuild',
1307 }, 1311 },
1308 } 1312 }
1309 1313
1310 # Local Variables: 1314 # Local Variables:
1311 # tab-width:2 1315 # tab-width:2
1312 # indent-tabs-mode:nil 1316 # indent-tabs-mode:nil
1313 # End: 1317 # End:
1314 # vim: set expandtab tabstop=2 shiftwidth=2: 1318 # vim: set expandtab tabstop=2 shiftwidth=2:
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698