llama.cpp/examples/sycl
Neo Zhang Jianyu 01684139c3
support SYCL backend windows build (#5208)
* support SYCL backend windows build

* add windows build in CI

* add for win build CI

* correct install oneMKL

* fix install issue

* fix ci

* fix install cmd

* fix install cmd

* fix install cmd

* fix install cmd

* fix install cmd

* fix win build

* fix win build

* fix win build

* restore other CI part

* restore as base

* rm no new line

* fix no new line issue, add -j

* fix grammer issue

* allow to trigger manually, fix format issue

* fix format

* add newline

* fix format

* fix format

* fix format issuse

---------

Co-authored-by: Abhilash Majumder <30946547+abhilash1910@users.noreply.github.com>
2024-01-31 08:08:07 +05:30
..
build.sh ggml : add unified SYCL backend for Intel GPUs (#2690) 2024-01-28 17:56:23 +02:00
CMakeLists.txt ggml : add unified SYCL backend for Intel GPUs (#2690) 2024-01-28 17:56:23 +02:00
ls-sycl-device.cpp ggml : add unified SYCL backend for Intel GPUs (#2690) 2024-01-28 17:56:23 +02:00
README.md ggml : add unified SYCL backend for Intel GPUs (#2690) 2024-01-28 17:56:23 +02:00
run-llama2.sh ggml : add unified SYCL backend for Intel GPUs (#2690) 2024-01-28 17:56:23 +02:00
win-build-sycl.bat support SYCL backend windows build (#5208) 2024-01-31 08:08:07 +05:30
win-run-llama2.bat support SYCL backend windows build (#5208) 2024-01-31 08:08:07 +05:30

llama.cpp/example/sycl

This example program provide the tools for llama.cpp for SYCL on Intel GPU.

Tool

Tool Name Function Status
ls-sycl-device List all SYCL devices with ID, compute capability, max work group size, ect. Support

ls-sycl-device

List all SYCL devices with ID, compute capability, max work group size, ect.

  1. Build the llama.cpp for SYCL for all targets.

  2. Enable oneAPI running environment

source /opt/intel/oneapi/setvars.sh
  1. Execute
./build/bin/ls-sycl-device

Check the ID in startup log, like:

found 4 SYCL devices:
  Device 0: Intel(R) Arc(TM) A770 Graphics,	compute capability 1.3,
    max compute_units 512,	max work group size 1024,	max sub group size 32,	global mem size 16225243136
  Device 1: Intel(R) FPGA Emulation Device,	compute capability 1.2,
    max compute_units 24,	max work group size 67108864,	max sub group size 64,	global mem size 67065057280
  Device 2: 13th Gen Intel(R) Core(TM) i7-13700K,	compute capability 3.0,
    max compute_units 24,	max work group size 8192,	max sub group size 64,	global mem size 67065057280
  Device 3: Intel(R) Arc(TM) A770 Graphics,	compute capability 3.0,
    max compute_units 512,	max work group size 1024,	max sub group size 32,	global mem size 16225243136

Attribute Note
compute capability 1.3 Level-zero running time, recommended
compute capability 3.0 OpenCL running time, slower than level-zero in most cases