summaryrefslogtreecommitdiff
path: root/numpy/core/setup.py
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2019-06-12 01:13:07 -0700
committerEric Wieser <wieser.eric@gmail.com>2019-09-13 00:57:17 -0700
commit6cf6ece43589670a28b765fd03402cc08ada61f0 (patch)
treec13c958f36552649312852402bb1598b0d20b0a4 /numpy/core/setup.py
parent79d7bc276afbe89c746e462d28d4bfbb4fc56148 (diff)
downloadnumpy-6cf6ece43589670a28b765fd03402cc08ada61f0.tar.gz
BUG: Disable -O3 on right_shift on compilers which emit an internal error
Needed to make CI pass
Diffstat (limited to 'numpy/core/setup.py')
-rw-r--r--numpy/core/setup.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/numpy/core/setup.py b/numpy/core/setup.py
index 338502791..e6088a48a 100644
--- a/numpy/core/setup.py
+++ b/numpy/core/setup.py
@@ -463,6 +463,12 @@ def configuration(parent_package='',top_path=None):
rep = check_long_double_representation(config_cmd)
moredefs.append(('HAVE_LDOUBLE_%s' % rep, 1))
+ if check_for_right_shift_internal_compiler_error(config_cmd):
+ moredefs.append('NPY_DO_NOT_OPTIMIZE_LONG_right_shift')
+ moredefs.append('NPY_DO_NOT_OPTIMIZE_ULONG_right_shift')
+ moredefs.append('NPY_DO_NOT_OPTIMIZE_LONGLONG_right_shift')
+ moredefs.append('NPY_DO_NOT_OPTIMIZE_ULONGLONG_right_shift')
+
# Py3K check
if sys.version_info[0] == 3:
moredefs.append(('NPY_PY3K', 1))