From 43f06e468770c314e314d6254193b5f350bf58ec Mon Sep 17 00:00:00 2001 From: Ben Ashbaugh Date: Tue, 4 Feb 2025 17:49:54 -0800 Subject: [PATCH 1/2] switch awesome_bot checker from Travis to GitHub actions --- .github/workflows/CI.yml | 30 ++++++++++++++++++++++++++++++ .travis.yml | 9 --------- 2 files changed, 30 insertions(+), 9 deletions(-) create mode 100644 .github/workflows/CI.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml new file mode 100644 index 0000000..4a0de65 --- /dev/null +++ b/.github/workflows/CI.yml @@ -0,0 +1,30 @@ +# Copyright 2025 The Khronos Group, Inc. +# SPDX-License-Identifier: Apache-2.0 + +# Github CI file for the OpenCL-Guide +# This file is based heavily on the same file for the Vulkan-Guide. + +name: CI + +# Controls when the action will run. +on: + # Triggers the workflow on push or manual dispatch + push: + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - uses: ruby/setup-ruby@v1 + with: + ruby-version: '3.0' + + - name: awesome_bot + run: | + gem install awesome_bot + awesome_bot --allow-dupe chapters/*.md --white-list https://www.youtube.com/,https://github.com/KhronosGroup,https://github.com/microsoft diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index e5c41b7..0000000 --- a/.travis.yml +++ /dev/null @@ -1,9 +0,0 @@ -language: ruby -rvm: - - 2.4 -before_script: - - gem install awesome_bot -script: - - awesome_bot --allow-dupe chapters/*.md --white-list https://www.youtube.com/,https://github.com/KhronosGroup,https://github.com/microsoft -notifications: - email: false From 634a4e899cfa1e55a41cea015247cdd949654397 Mon Sep 17 00:00:00 2001 From: Ben Ashbaugh Date: Tue, 4 Feb 2025 17:55:19 -0800 Subject: [PATCH 2/2] update links to eliminate redirects --- chapters/additional_resources.md | 2 +- chapters/cpp_for_opencl.md | 2 +- chapters/getting_started_windows.md | 4 ++-- chapters/how_does_opencl_compare.md | 2 +- chapters/how_does_opencl_work.md | 2 +- chapters/programming_opencl_kernels.md | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/chapters/additional_resources.md b/chapters/additional_resources.md index ea4a8d7..83274cf 100644 --- a/chapters/additional_resources.md +++ b/chapters/additional_resources.md @@ -4,7 +4,7 @@ There are many additional resources to help you find our more about OpenCL and t The remaining sections of this User Guide will show you how to install the Khronos OpenCL SDK on your machine and start programming using the provided samples as a starting point. -The definitive versions of all OpenCL core specifications and extensions are on the [OpenCL Registry](https://www.khronos.org/registry/OpenCL/). +The definitive versions of all OpenCL core specifications and extensions are on the [OpenCL Registry](https://registry.khronos.org/OpenCL/). Khronos-supplied OpenCL resources and other key tools are curated by the OpenCL Working Group on the [OpenCL Resource Guide](https://www.khronos.org/opencl/resources). diff --git a/chapters/cpp_for_opencl.md b/chapters/cpp_for_opencl.md index fe6abda..54d8812 100644 --- a/chapters/cpp_for_opencl.md +++ b/chapters/cpp_for_opencl.md @@ -104,7 +104,7 @@ The bugs and implementation of new features in clang can be tracked via the [Ope ### Online compilation -Kernels written in C++ for OpenCL can be compiled online on devices that support the [cl_ext_cxx_for_opencl](https://www.khronos.org/registry/OpenCL/extensions/ext/cl_ext_cxx_for_opencl.html) extension. +Kernels written in C++ for OpenCL can be compiled online on devices that support the [cl_ext_cxx_for_opencl](https://registry.khronos.org/OpenCL/extensions/ext/cl_ext_cxx_for_opencl.html) extension. ## Libraries diff --git a/chapters/getting_started_windows.md b/chapters/getting_started_windows.md index 7f1827b..664efb2 100644 --- a/chapters/getting_started_windows.md +++ b/chapters/getting_started_windows.md @@ -20,7 +20,7 @@ Steps will be provided to obtain a minimal and productive environment. ## Installation -In this guide we'll be using latest (at the time of writing) Windows 10. Installation for the most part will happen via [winget](https://docs.microsoft.com/en-us/windows/package-manager/winget/), the 1st party command-line tool for installing software on Windows. If for whatever reason you do not have the `winget` client on your PATH, it is bundled with the [App Installer](https://apps.microsoft.com/store/detail/9NBLGGH4NNS1?hl=en-us&gl=US) package in the Microsoft Store. Updating this component should also install the command-line tool. +In this guide we'll be using latest (at the time of writing) Windows 10. Installation for the most part will happen via [winget](https://learn.microsoft.com/en-us/windows/package-manager/winget/), the 1st party command-line tool for installing software on Windows. If for whatever reason you do not have the `winget` client on your PATH, it is bundled with the [App Installer](https://apps.microsoft.com/detail/9nblggh4nns1?hl=en-US&gl=US) package in the Microsoft Store. Updating this component should also install the command-line tool. _(NOTE: installation commands if not issued from a shell with Administrator privileges, UAC prompts will pop up. If you are in an automated scenario where that's an issue, make sure to work in such a shell.)_ @@ -36,7 +36,7 @@ winget install "Visual Studio Build Tools 2022" #### Command-line component selection -In automated scenarios with no GUI available, please consult the [VS docs](https://docs.microsoft.com/en-us/visualstudio/install/command-line-parameter-examples?view=vs-2022) on specifying the required workloads. A minimal configuration which may be imported using the GUI or specfied on the command-line is as: +In automated scenarios with no GUI available, please consult the [VS docs](https://learn.microsoft.com/en-us/visualstudio/install/command-line-parameter-examples?view=vs-2022) on specifying the required workloads. A minimal configuration which may be imported using the GUI or specfied on the command-line is as: ```powershell & "C:\Program Files (x86)\Microsoft Visual Studio\Installer\setup.exe" install --passive --norestart --productId Microsoft.VisualStudio.Product.BuildTools --channelId VisualStudio.17.Release --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Redist.14.Latest diff --git a/chapters/how_does_opencl_compare.md b/chapters/how_does_opencl_compare.md index a61f4ed..c2ac729 100644 --- a/chapters/how_does_opencl_compare.md +++ b/chapters/how_does_opencl_compare.md @@ -16,5 +16,5 @@ SYCL and OpenVX implementations can be accelerated over lower level Khronos APIs [Vulkan](https://www.vulkan.org/) is a widely used new generation GPU API that can accelerate compute operations on any compatible GPU using compute shaders (shaders are the graphics equivalent of OpenCL's kernels), as well as rendering 3D graphics. When comparing OpenCL and GPU APIs such as Vulkan, some developers that are just interested in compute find that OpenCL provides a more straightforward programming model, a lighter weight runtime, more language flexibility compared to graphics shading languages - for example OpenCL C has pointers - and more rigorously defined numerical precision for math operations that can be critical for many applications. And of course, Vulkan can only be used to program GPUs, whereas OpenCL can be used to program heterogeneous accelerators. -Vulkan and many implementations of OpenCL use Khronos’ [SPIR-V](https://www.khronos.org/spir/) standard as a programming language intermediate representation that enables significant language compiler tooling flexibility. +Vulkan and many implementations of OpenCL use Khronos’ [SPIR-V](https://www.khronos.org/spirv/) standard as a programming language intermediate representation that enables significant language compiler tooling flexibility. diff --git a/chapters/how_does_opencl_work.md b/chapters/how_does_opencl_work.md index d7fab25..3205178 100644 --- a/chapters/how_does_opencl_work.md +++ b/chapters/how_does_opencl_work.md @@ -32,7 +32,7 @@ and executed across the available parallel processors is called *OpenCL C*. OpenCL C is based on C99 and is defined as part of the OpenCL specification. Kernels written in other programming languages may be executed using OpenCL by compiling to an intermediate program representation, such as -[SPIR-V](https://www.khronos.org/spir/). +[SPIR-V](https://www.khronos.org/spirv/). OpenCL is a low-level programming framework so the programmer has direct, explicit control over where and when kernels are run, how the memory they use is diff --git a/chapters/programming_opencl_kernels.md b/chapters/programming_opencl_kernels.md index d53888f..02d963a 100644 --- a/chapters/programming_opencl_kernels.md +++ b/chapters/programming_opencl_kernels.md @@ -28,7 +28,7 @@ There are two offline compilation approaches:

-Early OpenCL implementations primarily used proprietary binary formats and caching of driver-compiled binaries to achieve offline compilation. However, the binaries created by the compiler in a specific device driver are not portable to other devices, and so applications using cached binaries lost the portbility to any device that is possible through online compilation of OpenCL C. To solve this portability problem, and to enable a richer language and compiler ecosystem, Khronos has defined a cross-vendor, portable intermediate program representation called [SPIR-V](https://www.khronos.org/spir/). An increasing number of OpenCL implementations are supporting ingestion of offline-compiled kernel programs in the SPIR-V format. +Early OpenCL implementations primarily used proprietary binary formats and caching of driver-compiled binaries to achieve offline compilation. However, the binaries created by the compiler in a specific device driver are not portable to other devices, and so applications using cached binaries lost the portbility to any device that is possible through online compilation of OpenCL C. To solve this portability problem, and to enable a richer language and compiler ecosystem, Khronos has defined a cross-vendor, portable intermediate program representation called [SPIR-V](https://www.khronos.org/spirv/). An increasing number of OpenCL implementations are supporting ingestion of offline-compiled kernel programs in the SPIR-V format. SPIR-V enables independent innovation by the compiler and silicon communities. Compiler front ends that generate SPIR-V kernels that can be ingested and executed by any OpenCL driver that understands the SPIR-V format. For example the [C++ for OpenCL](cpp_for_opencl.md) open source front-end and compilers for [SYCL](https://www.khronos.org/sycl/) can generate SPIR-V code. Both languages bring C++ functionality to programming OpenCL. While C++ for OpenCL allows using C++ features in the traditional OpenCL kernel code, SYCL provides single-source C++ solution both for the host code and the kernel code. There is also ongoing work on providing SPIR-V support in non C/C++-based languages e.g. [Julia](https://github.com/JuliaGPU/GPUCompiler.jl).