{"id":26346847,"url":"https://github.com/dominiklindorfer/sycl-intelgpu-quickstart","last_synced_at":"2026-05-09T16:17:04.569Z","repository":{"id":261960678,"uuid":"885836301","full_name":"DominikLindorfer/SYCL-IntelGPU-Quickstart","owner":"DominikLindorfer","description":"Lightweight \u0026 simplified approach to SYCL development","archived":false,"fork":false,"pushed_at":"2024-11-09T14:32:16.000Z","size":2888,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-16T07:14:36.496Z","etag":null,"topics":["c","cpp","dpp","gpu","gpu-programming","intel","oneapi","oneapi-dpc","sycl","vscode"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DominikLindorfer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-09T14:23:59.000Z","updated_at":"2024-11-23T09:27:07.000Z","dependencies_parsed_at":"2024-11-09T15:27:29.263Z","dependency_job_id":"5a7df3bd-63c0-4b4e-87cd-c56fc22ebfa5","html_url":"https://github.com/DominikLindorfer/SYCL-IntelGPU-Quickstart","commit_stats":null,"previous_names":["dominiklindorfer/sycl-experiments","dominiklindorfer/sycl-intelgpu-quickstart"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DominikLindorfer%2FSYCL-IntelGPU-Quickstart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DominikLindorfer%2FSYCL-IntelGPU-Quickstart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DominikLindorfer%2FSYCL-IntelGPU-Quickstart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DominikLindorfer%2FSYCL-IntelGPU-Quickstart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DominikLindorfer","download_url":"https://codeload.github.com/DominikLindorfer/SYCL-IntelGPU-Quickstart/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243836021,"owners_count":20355616,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","cpp","dpp","gpu","gpu-programming","intel","oneapi","oneapi-dpc","sycl","vscode"],"created_at":"2025-03-16T07:14:38.776Z","updated_at":"2025-10-20T03:09:00.850Z","avatar_url":"https://github.com/DominikLindorfer.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SYCL Programming Setup and Execution\n\nThis project demonstrates a minimal setup for SYCL programming using Intel’s oneAPI DPC++ compiler, avoiding the complexity (and error-prone / misconfigured) use of the provided CMake-based setups in [Intel's official samples](https://github.com/oneapi-src/oneAPI-samples/). The `src` directory contains the example programs, and the `build` directory is used for compiling and running them.\n\n## Project Structure\n\n- **`src/`**: Contains source files with basic SYCL programs:\n  - `hello_world.cpp`: Simple device query and \"Hello, World\" message.\n  - `vector_add.cpp`: Performs vector addition on the device.\n  - `mat_mul.cpp`: Executes a matrix multiplication on the device.\n  - `PrefixSum.cpp`: Computes the inclusive prefix sum in parallel.\n\n- **`build/`**: Folder for executing compilation commands listed below.\n\n## Setup Instructions\n\nTo get the environment ready for compiling and running SYCL programs, I followed these steps:\n\n### 1. Install Prerequisites\n\n- **Visual Studio Build Tools and Visual Studio**: Downloaded from [here](https://visualstudio.microsoft.com/de/downloads/). Both were necessary to successfully set up the SYCL environment.\n- **Intel oneAPI Base Toolkit**: Downloaded from [here](https://www.intel.com/content/www/us/en/developer/tools/oneapi/base-toolkit-download.html). This toolkit includes the DPC++ compiler (`dpcpp`) used to compile SYCL programs.\n\n### 2. Set Up VSCode\n\nIn Visual Studio Code, select the correct setvars environment by navigating to the path where you installed the oneAPI toolkit into, e.g. `...\\Intel\\oneAPI\\setvars.bat`. This script initializes the environment variables required by oneAPI tools:\n\n![image](https://github.com/user-attachments/assets/e37283e3-0164-435c-9457-f6e58b2234b0)\n\nwhich is followed by a success message:\n\n![image](https://github.com/user-attachments/assets/28db2568-e51e-4b6f-b838-1d363f5c0bc5)\n\n\n### 3. Compilation and Execution\n\nIntel's provided tutorials at [oneAPI-samples](https://github.com/oneapi-src/oneAPI-samples/tree/master) were overly complicated for me, using CMake extensively, which often failed to compile examples. I had also tried this [VSCode extension](https://marketplace.visualstudio.com/items?itemName=intel-corporation.oneapi-extension-pack) without luck. \n\nInstead, I compiled the programs with these straightforward commands:\n\n```bash\ncd build\n\ndpcpp -o hello_world.exe ..\\src\\hello_world.cpp\ndpcpp -o vector_add.exe ..\\src\\vector_add.cpp\ndpcpp -o mat_mul.exe ..\\src\\mat_mul.cpp\ndpcpp -o PrefixSum.exe ..\\src\\PrefixSum.cpp\n```\n\nEach command compiles an individual source file to an executable, making the setup simple and quick.\n\n### 4. Running the Programs\n\nTo run any of the executables, navigate to the `build` directory and execute them as follows:\n\n```bash\n./hello_world.exe\n./vector_add.exe\n./mat_mul.exe\n./PrefixSum.exe\n```\n\nThe output e.g. of `hello_world.cpp` will indicate which device the code is running on (CPU or GPU), along with a \"Hello, World!\" message:\n\n```\nRunning on 13th Gen Intel(R) Core(TM) i5-13600K\nHello, World!\n```\n\nor\n\n```\nRunning on Intel(R) UHD Graphics 770\nHello, World!\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdominiklindorfer%2Fsycl-intelgpu-quickstart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdominiklindorfer%2Fsycl-intelgpu-quickstart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdominiklindorfer%2Fsycl-intelgpu-quickstart/lists"}