8000 Backport PR #22099: CI: Disable numpy avx512 instructions · matplotlib/matplotlib@c7cb34a · GitHub
[go: up one dir, main page]

Skip to content

Commit c7cb34a

Browse files
timhoffmmeeseeksmachine
authored andcommitted
Backport PR #22099: CI: Disable numpy avx512 instructions
1 parent bea29bf commit c7cb34a

File tree

4 files changed

+8
-3
lines changed

4 files changed

+8
-3
lines changed

.github/workflows/tests.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ on:
99

1010
env:
1111
NO_AT_BRIDGE: 1 # Necessary for GTK3 interactive test.
12+
NPY_DISABLE_CPU_FEATURES: "AVX512F,AVX512CD,AVX512VL,AVX512BW,AVX512DQ,AVX512_SKX"
1213
OPENBLAS_NUM_THREADS: 1
1314
PYTHONFAULTHANDLER: 1
1415

azure-pipelines.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@ stages:
126126
displayName: 'print env'
127127

128128
- bash: |
129+
export NPY_DISABLE_CPU_FEATURES="AVX512F,AVX512CD,AVX512VL,AVX512BW,AVX512DQ,AVX512_SKX"
129130
PYTHONFAULTHANDLER=1 python -m pytest --junitxml=junit/test-results.xml -raR --maxfail=50 --timeout=300 --durations=25 --cov-report= --cov=lib -n 2 ||
130131
[[ "$PYTHON_VERSION" = 'Pre' ]]
131132
displayName: 'pytest'

lib/matplotlib/tests/test_backend_tk.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ def test_func():
3636
try:
3737
proc = subprocess.run(
3838
[sys.executable, "-c", f"{source}\n{func.__name__}()"],
39-
env={**os.environ, "MPLBACKEND": "TkAgg"},
39+
env={**os.environ, "MPLBACKEND": "TkAgg",
40+
"NPY_DISABLE_CPU_FEATURES": ""},
4041
timeout=_test_timeout,
4142
stdout=subprocess.PIPE,
4243
stderr=subprocess.PIPE,

lib/matplotlib/tests/test_sphinxext.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ def test_tinypages(tmpdir):
2828
# coverage anyways); hide them using GCOV_ERROR_FILE.
2929
proc = Popen(
3030
cmd, stdout=PIPE, stderr=PIPE, universal_newlines=True,
31-
env={**os.environ, "MPLBACKEND": "", "GCOV_ERROR_FILE": os.devnull})
31+
env={**os.environ, "MPLBACKEND": "", "GCOV_ERROR_FILE": os.devnull,
32+
"NPY_DISABLE_CPU_FEATURES": ""})
3233
out, err = proc.communicate()
3334

3435
# Build the pages with warnings turned into errors
@@ -128,7 +129,8 @@ def build_sphinx_html(source_dir, doctree_dir, html_dir, extra_args=None):
128129
cmd = [sys.executable, '-msphinx', '-W', '-b', 'html',
129130
'-d', str(doctree_dir), str(source_dir), str(html_dir), *extra_args]
130131
proc = Popen(cmd, stdout=PIPE, stderr=PIPE, universal_newlines=True,
131-
env={**os.environ, "MPLBACKEND": ""})
132+
env={**os.environ, "MPLBACKEND": "",
133+
"NPY_DISABLE_CPU_FEATURES": ""})
132134
out, err = proc.communicate()
133135

134136
assert proc.returncode == 0, \

0 commit comments

Comments
 (0)
0