Skip to content

Commit c5aed7c

Browse files
mengdilinfacebook-github-bot
authored andcommitted
FIX SVE CI latency regression (facebookresearch#3918)
Summary: Sometimes between Sept 25 to Oct 2, downloading and linking against `openblas=*=*openmp*` package to run tests have caused a 4-7x slow down. Link it with the regular openblas package which is not compiled with `USE_OPENMP=1`. We will set the openblas omp threads via the environment variable `OPENBLAS_NUM_THREADS` according to https://github.com/OpenMathLib/OpenBLAS/wiki/Faq#multi-threaded Pull Request resolved: facebookresearch#3918 Test Plan: SVE CI should finish within 40 minutes Reviewed By: ramilbakhshyiev Differential Revision: D64059860 Pulled By: mengdilin fbshipit-source-id: 3ba2bda5fce5122f051421f459692f15ad5360a4
1 parent 2e6551f commit c5aed7c

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

.github/actions/build_cmake/action.yml

+1-6
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,7 @@ runs:
3636
3737
# install base packages for ARM64
3838
if [ "${{ runner.arch }}" = "ARM64" ]; then
39-
# installing libmamba-solver is necessary for openblas=*=*openmp*
40-
conda install --solver=classic conda-forge::conda-libmamba-solver conda-forge::libmamba conda-forge::libmambapy conda-forge::libarchive
41-
42-
# installing openblas that was compiled with USE_OPENMP=1.
43-
# Context: https://github.com/facebookresearch/faiss/wiki/Troubleshooting#surprising-faiss-openmp-and-openblas-interaction
44-
conda install -y -q -c conda-forge openblas=*=*openmp* gxx_linux-aarch64 sysroot_linux-aarch64
39+
conda install -y -q -c conda-forge openblas gxx_linux-aarch64 sysroot_linux-aarch64
4540
fi
4641
4742
# install base packages for X86_64

.github/workflows/build.yml

+3
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,9 @@ jobs:
124124
uses: ./.github/actions/build_cmake
125125
with:
126126
opt_level: sve
127+
env:
128+
# Context: https://github.com/facebookresearch/faiss/wiki/Troubleshooting#surprising-faiss-openmp-and-openblas-interaction
129+
OPENBLAS_NUM_THREADS: '1'
127130
linux-x86_64-conda:
128131
name: Linux x86_64 (conda)
129132
needs: linux-x86_64-cmake

0 commit comments

Comments
 (0)