File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -59,6 +59,8 @@ if [ ! -z ${GG_BUILD_SYCL} ]; then
5959 export ONEAPI_DEVICE_SELECTOR=" level_zero:0"
6060 # Enable sysman for correct memory reporting
6161 export ZES_ENABLE_SYSMAN=1
62+ # to circumvent precision issues on CPY operations
63+ export SYCL_PROGRAM_COMPILE_OPTIONS=" -cl-fp32-correctly-rounded-divide-sqrt"
6264 CMAKE_EXTRA=" ${CMAKE_EXTRA} -DGGML_SYCL=1 -DCMAKE_C_COMPILER=icx -DCMAKE_CXX_COMPILER=icpx -DGGML_SYCL_F16=ON"
6365fi
6466
Original file line number Diff line number Diff line change @@ -302,6 +302,10 @@ cmake -B build -DGGML_SYCL=ON -DCMAKE_C_COMPILER=icx -DCMAKE_CXX_COMPILER=icpx -
302302cmake --build build --config Release -j -v
303303```
304304
305+ It is possible to come across some precision issues when running tests that stem from using faster
306+ instructions, which can be circumvented by setting the environment variable ` SYCL_PROGRAM_COMPILE_OPTIONS `
307+ as ` -cl-fp32-correctly-rounded-divide-sqrt `
308+
305309#### Nvidia GPU
306310
307311The SYCL backend depends on [ oneMath] ( https://github.com/uxlfoundation/oneMath ) for Nvidia and AMD devices.
@@ -322,6 +326,9 @@ cmake -B build -DGGML_SYCL=ON -DGGML_SYCL_TARGET=NVIDIA -DGGML_SYCL_DEVICE_ARCH=
322326cmake --build build --config Release -j -v
323327```
324328
329+ It is possible to come across some precision issues when running tests that stem from using faster
330+ instructions, which can be circumvented by passing the ` -fno-fast-math ` flag to the compiler.
331+
325332#### AMD GPU
326333
327334The SYCL backend depends on [ oneMath] ( https://github.com/uxlfoundation/oneMath ) for Nvidia and AMD devices.
You can’t perform that action at this time.
0 commit comments