Skip to content

Commit 30b49b1

Browse files
Channel OVERRIDE_INTEL_IPO env. variable
Set variable in public CI to override using interprocedural optimization in public CI to avoid insufficient resources failure during compilation on Windows.
1 parent 9f078d9 commit 30b49b1

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

.github/workflows/conda-package.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,8 @@ jobs:
102102
run: |
103103
echo "WHEELS_OUTPUT_FOLDER=$GITHUB_WORKSPACE${{ runner.os == 'Linux' && '/' || '\\' }}" >> $GITHUB_ENV
104104
- name: Build conda package
105+
env:
106+
OVERRIDE_INTEL_IPO: 1 # IPO requires more resources that GH actions VM provides
105107
run: conda build --no-test --python ${{ matrix.python }} -c intel -c conda-forge --override-channels conda-recipe
106108
- name: Upload artifact
107109
uses: actions/upload-artifact@v3

conda-recipe/bld.bat

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ set "INCLUDE=%BUILD_PREFIX%\include;%INCLUDE%"
66
"%PYTHON%" setup.py clean --all
77
set "SKBUILD_ARGS=-G Ninja -- -DCMAKE_C_COMPILER:PATH=icx -DCMAKE_CXX_COMPILER:PATH=icx -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON"
88

9+
REM Overriding IPO is useful for building in resources constrained VMs (public CI)
10+
if DEFINED OVERRIDE_INTEL_IPO (
11+
set "SKBUILD_ARGS=%SKBUILD_ARGS% -DCMAKE_INTERPROCEDURAL_OPTIMIZATION:BOOL=FALSE"
12+
)
13+
914
FOR %%V IN (14.0.0 14 15.0.0 15 16.0.0 16 17.0.0 17) DO @(
1015
REM set DIR_HINT if directory exists
1116
IF EXIST "%BUILD_PREFIX%\Library\lib\clang\%%V\" (

conda-recipe/meta.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ build:
99
number: {{ GIT_DESCRIBE_NUMBER }}
1010
script_env:
1111
- WHEELS_OUTPUT_FOLDER
12+
- OVERRIDE_INTEL_IPO # [win]
1213

1314
requirements:
1415
build:

0 commit comments

Comments
 (0)