Skip to content

Commit 27831ab

Browse files
bashbaugalycm
andauthored
spec source for new extensions (#711)
* extension specifications for cl_khr_extended_async_copies cl_khr_async_copy_fence cl_khr_expect_assume cl_khr_command_buffer (provisional) * update syntax highlighting for new extensions * Make a sub-section a sub-sub-section * Apply suggestions from code review Co-authored-by: Alastair Murray <alastair.murray@codeplay.com> * Update xml/cl.xml with command buffer extension version Co-authored-by: Alastair Murray <alastair.murray@codeplay.com> * remove INFO from the command buffer query enums * Apply suggestions from code review Co-authored-by: Alastair Murray <alastair.murray@codeplay.com> * use the refcount footnote Co-authored-by: Alastair Murray <alastair.murray@codeplay.com> * Split double use of `cl_command_buffer_properties_khr` 1. Change type of `cl_command_buffer_properties_khr` to `cl_properties` 2. Add a new `cl_command_buffer_flags_khr` type. 3. Rename `CL_COMMAND_BUFFER_PROPERTIES_KHR` to `CL_COMMAND_BUFFER_FLAGS_KHR`. 3a. Change the expected type of this to `cl_command_buffer_flags_khr`. 4. Change type of `cl_ndrange_kernel_command_properties_khr` to `cl_properties` Co-authored-by: Alastair Murray <alastair.murray@codeplay.com>
1 parent 13eabb4 commit 27831ab

11 files changed

Lines changed: 2805 additions & 58 deletions

OpenCL_Ext.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,9 @@ include::ext/cl_khr_semaphore.asciidoc[]
100100
include::ext/cl_khr_external_semaphore.asciidoc[]
101101
include::ext/cl_khr_external_memory.asciidoc[]
102102

103+
include::ext/cl_khr_command_buffer.asciidoc[]
104+
include::ext/cl_khr_expect_assume.asciidoc[]
105+
103106
// NOTE: To keep meaningful section numbers, new
104107
// extension documents should be added above here!
105108

config/rouge/lib/rouge/lexers/opencl.rb

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ class OpenCL < Cpp
6868
cl_kernel
6969
cl_event
7070
cl_sampler
71+
cl_semaphore_khr
7172
cl_bool
7273
cl_bitfield
7374
cl_properties
@@ -140,6 +141,20 @@ class OpenCL < Cpp
140141
cl_command_queue_capabilities_intel
141142
cl_device_feature_capabilities_intel
142143
cl_device_integer_dot_product_capabilities_khr
144+
cl_semaphore_properties_khr
145+
cl_semaphore_info_khr
146+
cl_semaphore_type_khr
147+
cl_semaphore_payload_khr
148+
cl_external_semaphore_handle_type_khr
149+
cl_external_memory_handle_type_khr
150+
cl_device_command_buffer_capabilities_khr
151+
cl_command_buffer_khr
152+
cl_sync_point_khr
153+
cl_command_buffer_info_khr
154+
cl_command_buffer_state_khr
155+
cl_command_buffer_properties_khr
156+
cl_ndrange_kernel_command_properties_khr
157+
cl_mutable_command_khr
143158
cl_dx9_surface_info_khr
144159
cl_motion_estimation_desc_intel
145160
cl_mem_ext_host_ptr

config/rouge/lib/rouge/lexers/opencl_c.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ class OpenCL_C < Cpp
6868
as_short2
6969
as_short8
7070
as_uint
71+
async_work_group_copy_fence
72+
async_work_group_copy_2D2D
73+
async_work_group_copy_3D3D
7174
atomic_compare_exchange_strong
7275
atomic_compare_exchange_strong_explicit
7376
atomic_compare_exchange_weak

env/extensions.asciidoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -339,6 +339,14 @@ declare the following SPIR-V capabilities:
339339
* *DotProductInput4x8BitKHR* if `CL_DEVICE_INTEGER_DOT_PRODUCT_INPUT_4x8BIT_KHR` is supported
340340
* *DotProductInput4x8BitPackedKHR*
341341

342+
==== `cl_khr_expect_assume`
343+
344+
If the OpenCL environment supports the extension `cl_khr_expect_assume`, then the environment must accept modules that declare use of the extension `SPV_KHR_expect_assume` via *OpExtension*.
345+
346+
If the OpenCL environment supports the extension `cl_khr_expect_assume` and use of the SPIR-V extension `SPV_KHR_expect_assume` is declared in the module via *OpExtension*, then the environment must accept modules that declare the following SPIR-V capabilities:
347+
348+
* *ExpectAssumeKHR*
349+
342350
=== Embedded Profile Extensions
343351

344352
==== `cles_khr_int64`

ext/cl_khr_async_work_group_copy_fence.asciidoc

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
// http://creativecommons.org/licenses/by/4.0/
44

55
[[cl_khr_async_work_group_copy_fence]]
6-
== Async Work Group Copy Fence (Provisional)
6+
== Async Work Group Copy Fence
77

8-
This section describes the *cl_khr_async_work_group_copy_fence* provisional extension.
8+
This section describes the *cl_khr_async_work_group_copy_fence* extension.
99
The extension adds a new built-in function to OpenCL C to establish a memory synchronization ordering of asynchronous copies.
1010

1111
=== General information
@@ -16,6 +16,7 @@ The extension adds a new built-in function to OpenCL C to establish a memory syn
1616
|====
1717
| *Date* | *Version* | *Description*
1818
| 2020-04-21 | 0.9.0 | First assigned version (provisional).
19+
| 2021-11-10 | 1.0.0 | First non-provisional version.
1920
|====
2021

2122
[[cl_khr_async_work_group_copy_fence-additions-to-chapter-6-of-the-opencl-specification]]
@@ -54,5 +55,3 @@ work-group executing the kernel with the same argument values;
5455
otherwise the results are undefined. This rule applies to ND-ranges
5556
implemented with uniform and non-uniform work-groups.
5657
|=======================================================================
57-
58-
NOTE: This is a preview of an OpenCL provisional extension specification that has been Ratified under the Khronos Intellectual Property Framework. It is being made publicly available prior to being uploaded to the Khronos registry to enable review and feedback from the community. If you have feedback please create an issue on https://github.com/KhronosGroup/OpenCL-Docs/

0 commit comments

Comments
 (0)