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

Side by Side Diff: build/common.gypi

Issue 187423002: Require SSE2 for all 32-bit Linux builds and remove disable_sse2 option. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | third_party/qcms/qcms.gyp » ('j') | 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) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 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 expected to be overriden on the GYP command line (-D) or by 9 # Variables expected to be overriden on the GYP command line (-D) or by
10 # ~/.gyp/include.gypi. 10 # ~/.gyp/include.gypi.
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 # Detect NEON support at run-time. 283 # Detect NEON support at run-time.
284 'arm_neon_optional%': 0, 284 'arm_neon_optional%': 0,
285 285
286 # The system root for cross-compiles. Default: none. 286 # The system root for cross-compiles. Default: none.
287 'sysroot%': '', 287 'sysroot%': '',
288 'chroot_cmd%': '', 288 'chroot_cmd%': '',
289 289
290 # The system libdir used for this ABI. 290 # The system libdir used for this ABI.
291 'system_libdir%': 'lib', 291 'system_libdir%': 'lib',
292 292
293 # On Linux, we build with sse2 for Chromium builds.
294 'disable_sse2%': 0,
295
296 # Use libjpeg-turbo as the JPEG codec used by Chromium. 293 # Use libjpeg-turbo as the JPEG codec used by Chromium.
297 'use_libjpeg_turbo%': 1, 294 'use_libjpeg_turbo%': 1,
298 295
299 # Use system libjpeg. Note that the system's libjepg will be used even if 296 # Use system libjpeg. Note that the system's libjepg will be used even if
300 # use_libjpeg_turbo is set. 297 # use_libjpeg_turbo is set.
301 'use_system_libjpeg%': 0, 298 'use_system_libjpeg%': 0,
302 299
303 # By default, component is set to static_library and it can be overriden 300 # By default, component is set to static_library and it can be overriden
304 # by the GYP command line or by ~/.gyp/include.gypi. 301 # by the GYP command line or by ~/.gyp/include.gypi.
305 'component%': 'static_library', 302 'component%': 'static_library',
(...skipping 1354 matching lines...) Expand 10 before | Expand all | Expand 10 after
1660 }], 1657 }],
1661 1658
1662 # Native Client glibc toolchain is enabled 1659 # Native Client glibc toolchain is enabled
1663 # by default except on arm and mips. 1660 # by default except on arm and mips.
1664 ['target_arch=="arm" or target_arch=="mipsel"', { 1661 ['target_arch=="arm" or target_arch=="mipsel"', {
1665 'disable_glibc%': 1, 1662 'disable_glibc%': 1,
1666 }, { 1663 }, {
1667 'disable_glibc%': 0, 1664 'disable_glibc%': 0,
1668 }], 1665 }],
1669 1666
1670 # Disable SSE2 when building for ARM or MIPS.
1671 ['target_arch=="arm" or target_arch=="mipsel"', {
1672 'disable_sse2%': 1,
1673 }, {
1674 'disable_sse2%': '<(disable_sse2)',
1675 }],
1676
1677 # Set the relative path from this file to the GYP file of the JPEG 1667 # Set the relative path from this file to the GYP file of the JPEG
1678 # library used by Chromium. 1668 # library used by Chromium.
1679 ['use_system_libjpeg==1 or use_libjpeg_turbo==0', { 1669 ['use_system_libjpeg==1 or use_libjpeg_turbo==0', {
1680 # Configuration for using the system libjeg is here. 1670 # Configuration for using the system libjeg is here.
1681 'libjpeg_gyp_path': '../third_party/libjpeg/libjpeg.gyp', 1671 'libjpeg_gyp_path': '../third_party/libjpeg/libjpeg.gyp',
1682 }, { 1672 }, {
1683 'libjpeg_gyp_path': '../third_party/libjpeg_turbo/libjpeg.gyp', 1673 'libjpeg_gyp_path': '../third_party/libjpeg_turbo/libjpeg.gyp',
1684 }], 1674 }],
1685 1675
1686 # Options controlling the use of GConf (the classic GNOME configuration 1676 # Options controlling the use of GConf (the classic GNOME configuration
(...skipping 1514 matching lines...) Expand 10 before | Expand all | Expand 10 after
3201 # rounded to its original precision) but they have significant 3191 # rounded to its original precision) but they have significant
3202 # runtime performance penalty. 3192 # runtime performance penalty.
3203 # 3193 #
3204 # -mfpmath=sse -msse2 makes the compiler use SSE instructions 3194 # -mfpmath=sse -msse2 makes the compiler use SSE instructions
3205 # which keep floating-point values in SSE registers in its 3195 # which keep floating-point values in SSE registers in its
3206 # native precision (32-bit for single precision, and 64-bit 3196 # native precision (32-bit for single precision, and 64-bit
3207 # for double precision values). This means the floating-point 3197 # for double precision values). This means the floating-point
3208 # value used during computation does not change depending on 3198 # value used during computation does not change depending on
3209 # how the compiler optimized the code, since the value is 3199 # how the compiler optimized the code, since the value is
3210 # always kept in its specified precision. 3200 # always kept in its specified precision.
3201 #
3202 # Refer to http://crbug.com/348761 for rationale behind SSE2
3203 # being a minimum requirement for 32-bit Linux builds and
3204 # http://crbug.com/313032 for an example where this has "bit"
3205 # us in the past.
3206 'cflags': [
3207 '-march=pentium4',
Paweł Hajdan Jr. 2014/03/10 23:49:54 Do we need to force -march=pentium4 here?
scherkus (not reviewing) 2014/03/11 00:08:52 As far as I can tell it was added in r12228 with m
Paweł Hajdan Jr. 2014/03/11 00:28:16 Thank you, looks good to me now.
3208 '-msse2',
3209 '-mfpmath=sse',
3210 '-mmmx', # Allows mmintrin.h for MMX intrinsics.
3211 '-m32',
3212 ],
3213 'ldflags': [
3214 '-m32',
3215 ],
3211 'conditions': [ 3216 'conditions': [
3212 ['branding=="Chromium" and disable_sse2==0', {
3213 'cflags': [
3214 '-march=pentium4',
3215 '-msse2',
3216 '-mfpmath=sse',
3217 ],
3218 }],
3219 # ChromeOS targets Pinetrail, which is sse3, but most of the
3220 # benefit comes from sse2 so this setting allows ChromeOS
3221 # to build on other CPUs. In the future -march=atom would
3222 # help but requires a newer compiler.
3223 ['chromeos==1 and disable_sse2==0', {
3224 'cflags': [
3225 '-msse2',
3226 '-mfpmath=sse',
3227 ],
3228 }],
3229 # Use gold linker for Android ia32 target. 3217 # Use gold linker for Android ia32 target.
3230 ['OS=="android"', { 3218 ['OS=="android"', {
3231 'cflags': [ 3219 'cflags': [
3232 '-fuse-ld=gold', 3220 '-fuse-ld=gold',
3233 ], 3221 ],
3234 'ldflags': [ 3222 'ldflags': [
3235 '-fuse-ld=gold', 3223 '-fuse-ld=gold',
3236 ], 3224 ],
3237 }], 3225 }],
3238 # Install packages have started cropping up with 3226 # Install packages have started cropping up with
3239 # different headers between the 32-bit and 64-bit 3227 # different headers between the 32-bit and 64-bit
3240 # versions, so we have to shadow those differences off 3228 # versions, so we have to shadow those differences off
3241 # and make sure a 32-bit-on-64-bit build picks up the 3229 # and make sure a 32-bit-on-64-bit build picks up the
3242 # right files. 3230 # right files.
3243 # For android build, use NDK headers instead of host headers 3231 # For android build, use NDK headers instead of host headers
3244 ['host_arch!="ia32" and OS!="android"', { 3232 ['host_arch!="ia32" and OS!="android"', {
3245 'include_dirs+': [ 3233 'include_dirs+': [
3246 '/usr/include32', 3234 '/usr/include32',
3247 ], 3235 ],
3248 }], 3236 }],
3249 ], 3237 ],
3250 # -mmmx allows mmintrin.h to be used for mmx intrinsics.
3251 # video playback is mmx and sse2 optimized.
3252 'cflags': [
3253 '-m32',
3254 '-mmmx',
3255 ],
3256 'ldflags': [
3257 '-m32',
3258 ],
3259 }], 3238 }],
3260 ], 3239 ],
3261 }], 3240 }],
3262 ['target_arch=="arm"', { 3241 ['target_arch=="arm"', {
3263 'target_conditions': [ 3242 'target_conditions': [
3264 ['_toolset=="target"', { 3243 ['_toolset=="target"', {
3265 'cflags_cc': [ 3244 'cflags_cc': [
3266 # The codesourcery arm-2009q3 toolchain warns at that the ABI 3245 # The codesourcery arm-2009q3 toolchain warns at that the ABI
3267 # has changed whenever it encounters a varargs function. This 3246 # has changed whenever it encounters a varargs function. This
3268 # silences those warnings, as they are not helpful and 3247 # silences those warnings, as they are not helpful and
(...skipping 1783 matching lines...) Expand 10 before | Expand all | Expand 10 after
5052 # settings in target dicts. SYMROOT is a special case, because many other 5031 # settings in target dicts. SYMROOT is a special case, because many other
5053 # Xcode variables depend on it, including variables such as 5032 # Xcode variables depend on it, including variables such as
5054 # PROJECT_DERIVED_FILE_DIR. When a source group corresponding to something 5033 # PROJECT_DERIVED_FILE_DIR. When a source group corresponding to something
5055 # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the 5034 # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the
5056 # files to appear (when present) in the UI as actual files and not red 5035 # files to appear (when present) in the UI as actual files and not red
5057 # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR, 5036 # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR,
5058 # and therefore SYMROOT, needs to be set at the project level. 5037 # and therefore SYMROOT, needs to be set at the project level.
5059 'SYMROOT': '<(DEPTH)/xcodebuild', 5038 'SYMROOT': '<(DEPTH)/xcodebuild',
5060 }, 5039 },
5061 } 5040 }
OLDNEW
« no previous file with comments | « no previous file | third_party/qcms/qcms.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698