forked from RevathiJambunathan/WarpX
-
Notifications
You must be signed in to change notification settings - Fork 0
205 lines (186 loc) · 6.54 KB
/
intel.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
name: 🐧 Intel
on:
push:
branches:
- "development"
pull_request:
paths-ignore:
- "Docs/**"
concurrency:
group: ${{ github.ref }}-${{ github.head_ref }}-intel
cancel-in-progress: true
jobs:
# Ref.: https://github.com/rscohn2/oneapi-ci
# intel-basekit intel-hpckit are too large in size
build_icc:
name: oneAPI ICC SP&DP
runs-on: ubuntu-20.04
if: github.event.pull_request.draft == false
# For oneAPI, Ninja is slower than the default:
#env:
# CMAKE_GENERATOR: Ninja
steps:
- uses: actions/checkout@v4
- name: install dependencies
run: |
.github/workflows/dependencies/icc.sh
- name: CCache Cache
uses: actions/cache@v4
with:
path: ~/.cache/ccache
key: ccache-${{ github.workflow }}-${{ github.job }}-git-${{ github.sha }}
restore-keys: |
ccache-${{ github.workflow }}-${{ github.job }}-git-
- name: build WarpX
run: |
export CCACHE_COMPRESS=1
export CCACHE_COMPRESSLEVEL=10
export CCACHE_MAXSIZE=200M
export CCACHE_DEPEND=1
ccache -z
set +eu
source /opt/intel/oneapi/setvars.sh
set -eu
export CXX=$(which icpc)
export CC=$(which icc)
python3 -m pip install --upgrade pip
python3 -m pip install --upgrade build packaging setuptools wheel
cmake -S . -B build_dp \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DpyAMReX_IPO=OFF \
-DWarpX_PYTHON=ON \
-DWarpX_PYTHON_IPO=OFF \
-DWarpX_MPI=OFF \
-DWarpX_OPENPMD=ON \
-DWarpX_openpmd_internal=OFF
cmake --build build_dp -j 4
cmake -S . -B build_sp \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DpyAMReX_IPO=OFF \
-DWarpX_PYTHON=ON \
-DWarpX_PYTHON_IPO=OFF \
-DWarpX_MPI=OFF \
-DWarpX_OPENPMD=ON \
-DWarpX_openpmd_internal=OFF \
-DWarpX_PRECISION=SINGLE
cmake --build build_sp -j 4
cmake --build build_sp --target pip_install
ccache -s
du -hs ~/.cache/ccache
build_icpx:
name: oneAPI ICX SP
runs-on: ubuntu-20.04
# Since 2021.4.0, AMReX_GpuUtility.H: error: comparison with NaN always evaluates to false in fast floating point modes
# oneAPI 2022.2.0 hangs for -O2 and higher:
# https://github.com/ECP-WarpX/WarpX/issues/3442
env:
CXXFLAGS: "-Werror -Wno-error=pass-failed -Wno-tautological-constant-compare"
# For oneAPI, Ninja is slower than the default:
# CMAKE_GENERATOR: Ninja
if: github.event.pull_request.draft == false
steps:
- uses: actions/checkout@v4
- name: install dependencies
shell: bash
run: |
.github/workflows/dependencies/dpcpp.sh
- name: CCache Cache
uses: actions/cache@v4
with:
path: ~/.cache/ccache
key: ccache-${{ github.workflow }}-${{ github.job }}-git-${{ github.sha }}
restore-keys: |
ccache-${{ github.workflow }}-${{ github.job }}-git-
- name: build WarpX
shell: bash
run: |
export CCACHE_COMPRESS=1
export CCACHE_COMPRESSLEVEL=10
export CCACHE_MAXSIZE=100M
export CCACHE_DEPEND=1
ccache -z
set +e
source /opt/intel/oneapi/setvars.sh
set -e
export PATH=$PATH:/opt/intel/oneapi/compiler/2024.2/bin # FIXME
export CXX=$(which icpx)
export CC=$(which icx)
python3 -m pip install --upgrade pip
python3 -m pip install --upgrade build packaging setuptools wheel
cmake -S . -B build_sp \
-DCMAKE_CXX_FLAGS_RELEASE="-O1 -DNDEBUG" \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DWarpX_EB=OFF \
-DWarpX_PYTHON=ON \
-DWarpX_MPI=OFF \
-DWarpX_OPENPMD=ON \
-DWarpX_PRECISION=SINGLE
cmake --build build_sp -j 4
cmake --build build_sp --target pip_install
ccache -s
du -hs ~/.cache/ccache
- name: run pywarpx
run: |
set +e
source /opt/intel/oneapi/setvars.sh
set -e
export OMP_NUM_THREADS=2
Examples/Physics_applications/laser_acceleration/inputs_test_3d_laser_acceleration_picmi.py
build_dpcc:
name: oneAPI DPC++ SP
runs-on: ubuntu-20.04
# Since 2021.4.0, AMReX_GpuUtility.H: error: comparison with NaN always evaluates to false in fast floating point modes
# oneAPI 2022.2.0 hangs for -O2 and higher:
# https://github.com/ECP-WarpX/WarpX/issues/3442
env:
CXXFLAGS: "-Werror -Wno-tautological-constant-compare"
# For oneAPI, Ninja is slower than the default:
# CMAKE_GENERATOR: Ninja
if: github.event.pull_request.draft == false
steps:
- uses: actions/checkout@v4
- name: install dependencies
shell: bash
run: |
.github/workflows/dependencies/dpcpp.sh
- name: CCache Cache
uses: actions/cache@v4
with:
path: ~/.cache/ccache
key: ccache-${{ github.workflow }}-${{ github.job }}-git-${{ github.sha }}
restore-keys: |
ccache-${{ github.workflow }}-${{ github.job }}-git-
- name: build WarpX
shell: bash
run: |
export CCACHE_COMPRESS=1
export CCACHE_COMPRESSLEVEL=10
export CCACHE_MAXSIZE=100M
export CCACHE_DEPEND=1
ccache -z
set +e
source /opt/intel/oneapi/setvars.sh
set -e
export PATH=$PATH:/opt/intel/oneapi/compiler/2024.2/bin # FIXME
export CXX=$(which icpx)
export CC=$(which icx)
export CXXFLAGS="-fsycl ${CXXFLAGS}"
cmake -S . -B build_sp \
-DCMAKE_CXX_FLAGS_RELEASE="-O1 -DNDEBUG" \
-DBUILD_SHARED_LIBS=ON \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DWarpX_COMPUTE=SYCL \
-DWarpX_EB=ON \
-DWarpX_FFT=ON \
-DWarpX_PYTHON=ON \
-DWarpX_MPI=OFF \
-DWarpX_OPENPMD=ON \
-DWarpX_PRECISION=SINGLE
cmake --build build_sp -j 4
ccache -s
du -hs ~/.cache/ccache
# Skip this as it will copy the binary artifacts and we are tight on disk space
# python3 -m pip install --upgrade pip
# python3 -m pip install --upgrade build packaging setuptools wheel
# PYWARPX_LIB_DIR=$PWD/build_sp/lib/site-packages/pywarpx/ python3 -m pip wheel .
# python3 -m pip install *.whl