Skip to content

Commit

Permalink
fix a few more missing anchors and incorrect attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
bashbaug committed Mar 31, 2024
1 parent 18deda4 commit 5c06fd5
Show file tree
Hide file tree
Showing 11 changed files with 38 additions and 25 deletions.
2 changes: 1 addition & 1 deletion OpenCL_C.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9735,7 +9735,7 @@ The *F* conversion specifier produces `INF`, `INFINITY`, or `NAN` instead of

**e,E** A `double`, `half__n__`, `float__n__` or `double__n__` argument
representing a floating-point number is converted in the style
__[__**-**__]d__**.**__ddd __**e{plusmn}}**_dd_, where there is one digit
__[__**-**__]d__**.**__ddd __**e{plusmn}**_dd_, where there is one digit
(which is nonzero if the argument is nonzero) before the decimal-point
character and the number of digits after it is equal to the precision; if
the precision is missing, it is taken as 6; if the precision is zero and the
Expand Down
6 changes: 3 additions & 3 deletions api/cl_khr_extended_versioning.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ Versioning>> section.

=== New Macro Names

* {CL_VERSION_MAJOR_BITS_KHR_anchor}
* {CL_VERSION_MINOR_BITS_KHR_anchor}
* {CL_VERSION_PATCH_BITS_KHR_anchor}
* {CL_VERSION_MAJOR_BITS_KHR}
* {CL_VERSION_MINOR_BITS_KHR}
* {CL_VERSION_PATCH_BITS_KHR}
* `CL_VERSION_MAJOR_MASK_KHR`
* `CL_VERSION_MINOR_MASK_KHR`
* `CL_VERSION_PATCH_MASK_KHR`
Expand Down
2 changes: 1 addition & 1 deletion api/cl_khr_external_semaphore.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ while (true) {
* Revision 0.9.0, 2021-09-10
** Initial version (provisional).
* Revision 0.9.1, 2023-11-16
** Added {CL_SEMAPHORE_EXPORTABLE_KHR_anchor}.
** Added {CL_SEMAPHORE_EXPORTABLE_KHR}.
* Revision 0.9.2, 2023-11-21
** Added re-import function call to `<<cl_khr_external_semaphore_sync_fd>>`

2 changes: 1 addition & 1 deletion api/cl_khr_external_semaphore_sync_fd.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,6 @@ external semaphore using the APIs introduced by
* Revision 0.9.0, 2021-09-10
** Initial version (provisional).
* Revision 0.9.1, 2023-11-16
** Added {CL_SEMAPHORE_EXPORTABLE_KHR_anchor}.
** Added {CL_SEMAPHORE_EXPORTABLE_KHR}.
* Revision 0.9.2, 2023-11-21
** Added re-import function call to `<<cl_khr_external_semaphore_sync_fd>>`
2 changes: 1 addition & 1 deletion api/cl_khr_gl_event.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ runtime.
. Where can events generated from GL syncs be usable?
+
--
*PROPOSED*: Only with clEnqueueAcquireGLObjects, and attempting to use such
*PROPOSED*: Only with {clEnqueueAcquireGLObjects}, and attempting to use such
an event elsewhere will generate an error.
There is no apparent use case for using such events elsewhere, and possibly
some cost to supporting it, balanced by the cost of checking the source of
Expand Down
2 changes: 1 addition & 1 deletion api/cl_khr_semaphore.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ In particular, this extension defines:
* {cl_device_info_TYPE}
** {CL_DEVICE_SEMAPHORE_TYPES_KHR}
* {cl_semaphore_type_khr_TYPE}
** {CL_SEMAPHORE_TYPE_BINARY_KHR} 1
** {CL_SEMAPHORE_TYPE_BINARY_KHR}
* {cl_semaphore_info_khr_TYPE}
** {CL_SEMAPHORE_CONTEXT_KHR}
** {CL_SEMAPHORE_REFERENCE_COUNT_KHR}
Expand Down
2 changes: 1 addition & 1 deletion api/cl_khr_spir.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ feature in OpenCL 2.1.
* {cl_device_info_TYPE}
** {CL_DEVICE_SPIR_VERSIONS}
* {cl_program_binary_type_TYPE}
** CL_PROGRAM_BINARY_TYPE_INTERMEDIATE}
** {CL_PROGRAM_BINARY_TYPE_INTERMEDIATE}

=== Version History

Expand Down
2 changes: 1 addition & 1 deletion api/opencl_architecture.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2226,7 +2226,7 @@ working with version numbers easier.
{cl_version_TYPE}.
* `CL_VERSION_PATCH` extracts the _patch_ version from a packed
{cl_version_TYPE}.
* `CL_MAKE_VERSION` returns a packed `cl_version_TYPE} from a
* `CL_MAKE_VERSION` returns a packed {cl_version_TYPE} from a
_major_, _minor_ and _patch_ version.
* {CL_VERSION_MAJOR_BITS_anchor}, {CL_VERSION_MINOR_BITS_anchor}, and
{CL_VERSION_PATCH_BITS_anchor} are the number of bits in the
Expand Down
6 changes: 6 additions & 0 deletions api/opencl_platform_layer.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -1813,13 +1813,17 @@ include::{generated}/api/version-notes/CL_DEVICE_UUID_KHR.asciidoc[]

Device UUIDs must be immutable for a given device across processes,
driver APIs, driver versions, and system reboots.

{CL_UUID_SIZE_KHR_anchor} is the size of the UUID, in bytes.
| {CL_DRIVER_UUID_KHR_anchor}

include::{generated}/api/version-notes/CL_DRIVER_UUID_KHR.asciidoc[]

| {cl_uchar_TYPE}[{CL_UUID_SIZE_KHR}]
| Returns a universally unique identifier (UUID) for the software driver
for the device.

{CL_UUID_SIZE_KHR} is the size of the UUID, in bytes.
| {CL_DEVICE_LUID_VALID_KHR_anchor}

include::{generated}/api/version-notes/CL_DEVICE_LUID_VALID_KHR.asciidoc[]
Expand All @@ -1843,6 +1847,8 @@ include::{generated}/api/version-notes/CL_DEVICE_LUID_KHR.asciidoc[]
value can be cast to an `LUID` object and must be equal to the locally
unique identifier of an `IDXGIAdapter1` object that corresponds to the
OpenCL device.

{CL_LUID_SIZE_KHR_anchor} is the size of the LUID, in bytes.
| {CL_DEVICE_NODE_MASK_KHR_anchor}

include::{generated}/api/version-notes/CL_DEVICE_NODE_MASK_KHR.asciidoc[]
Expand Down
31 changes: 19 additions & 12 deletions api/opencl_runtime_layer.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6213,10 +6213,10 @@ include::{generated}/api/version-notes/clGetGLObjectInfo.asciidoc[]

* _memobj_ is the memory object to query.
* _gl_object_type_ returns the type of OpenGL object attached to _memobj_
and can be {CL_GL_OBJECT_BUFFER}, {CL_GL_OBJECT_TEXTURE2D},
{CL_GL_OBJECT_TEXTURE3D}, {CL_GL_OBJECT_TEXTURE2D_ARRAY},
{CL_GL_OBJECT_TEXTURE1D}, {CL_GL_OBJECT_TEXTURE1D_ARRAY},
{CL_GL_OBJECT_TEXTURE_BUFFER}, or {CL_GL_OBJECT_RENDERBUFFER}.
and can be {CL_GL_OBJECT_BUFFER_anchor}, {CL_GL_OBJECT_TEXTURE2D_anchor},
{CL_GL_OBJECT_TEXTURE3D_anchor}, {CL_GL_OBJECT_TEXTURE2D_ARRAY_anchor},
{CL_GL_OBJECT_TEXTURE1D_anchor}, {CL_GL_OBJECT_TEXTURE1D_ARRAY_anchor},
{CL_GL_OBJECT_TEXTURE_BUFFER_anchor}, or {CL_GL_OBJECT_RENDERBUFFER_anchor}.
If _gl_object_type_ is `NULL`, it is ignored
* _gl_object_name_ returns the OpenGL object name used to create _memobj_.
If _gl_object_name_ is `NULL`, it is ignored.
Expand Down Expand Up @@ -10875,7 +10875,10 @@ Also see `<<cl_khr_subgroups>>`.

include::{generated}/api/version-notes/CL_KERNEL_MAX_SUB_GROUP_SIZE_FOR_NDRANGE.asciidoc[]

Also see `<<cl_khr_subgroups>>`.
ifdef::cl_khr_subgroups[]
The equivalent {CL_KERNEL_MAX_SUB_GROUP_SIZE_FOR_NDRANGE_KHR_anchor} may be used if
the `<<cl_khr_subgroups>>` extension is supported.
endif::cl_khr_subgroups[]
| {size_t_TYPE}*
| {size_t_TYPE}
| Returns the maximum sub-group size for this kernel.
Expand All @@ -10892,7 +10895,10 @@ Also see `<<cl_khr_subgroups>>`.

include::{generated}/api/version-notes/CL_KERNEL_SUB_GROUP_COUNT_FOR_NDRANGE.asciidoc[]

Also see `<<cl_khr_subgroups>>`.
ifdef::cl_khr_subgroups[]
The equivalent {CL_KERNEL_SUB_GROUP_COUNT_FOR_NDRANGE_KHR_anchor} may be used if
the `<<cl_khr_subgroups>>` extension is supported.
endif::cl_khr_subgroups[]
| {size_t_TYPE}*
| {size_t_TYPE}
| Returns the number of sub-groups that will be present in each
Expand Down Expand Up @@ -12769,14 +12775,15 @@ This section describes the semaphore types and functions defined by the

* {cl_semaphore_type_khr_TYPE} represent the different types of
semaphores.
** It is mandatory to support {CL_SEMAPHORE_TYPE_BINARY_KHR}.
// TODO: This isn't a very good anchor for {CL_SEMAPHORE_TYPE_BINARY_KHR}...
** It is mandatory to support {CL_SEMAPHORE_TYPE_BINARY_KHR_anchor}.
* {cl_semaphore_properties_khr_TYPE} represents properties associated with
semaphores.
** {CL_SEMAPHORE_TYPE_KHR} must be supported.
* {cl_semaphore_info_khr_TYPE} represents queries for additional
information about semaphores.
** All enums described in the "`New API Enums`" section of the
`<<cl_khr_semaphore>>` extension for cl_semaphore_info_khr_TYPE} must
`<<cl_khr_semaphore>>` extension for {cl_semaphore_info_khr_TYPE} must
be supported.
* {cl_semaphore_payload_khr_TYPE} represents payload values of semaphores.
* {cl_semaphore_khr_TYPE} represent semaphore objects.
Expand Down Expand Up @@ -12813,7 +12820,7 @@ properties by {cl_semaphore_properties_khr_TYPE} that can be passed to
| {CL_SEMAPHORE_DEVICE_HANDLE_LIST_KHR_anchor}
| {cl_device_id_TYPE}[]
| Specifies the list of OpenCL devices (terminated with
{CL_SEMAPHORE_DEVICE_HANDLE_LIST_END_KHR}) to associate with the
{CL_SEMAPHORE_DEVICE_HANDLE_LIST_END_KHR_anchor}) to associate with the
semaphore.
Only a single device is permitted in the list.

Expand All @@ -12823,7 +12830,7 @@ ifdef::cl_khr_external_semaphore[]
include::{generated}/api/version-notes/CL_SEMAPHORE_EXPORT_HANDLE_TYPES_KHR.asciidoc[]
| {cl_external_semaphore_handle_type_khr_TYPE}[]
| Specifies the list of semaphore handle type properties (terminated
with {CL_SEMAPHORE_EXPORT_HANDLE_TYPES_LIST_END_KHR}) that can be
with {CL_SEMAPHORE_EXPORT_HANDLE_TYPES_LIST_END_KHR_anchor}) that can be
used to export the semaphore being created.
endif::cl_khr_external_semaphore[]
|====
Expand Down Expand Up @@ -15825,7 +15832,7 @@ description here and is defined as:
include::{generated}/api/structs/cl_mutable_base_config_khr.txt[]

* _type_ is the type of this structure, and must be
{CL_STRUCTURE_TYPE_MUTABLE_BASE_CONFIG_KHR}
{CL_STRUCTURE_TYPE_MUTABLE_BASE_CONFIG_KHR_anchor}
* _next_ is `NULL` or a pointer to an extending structure.
* _num_mutable_dispatch_ is the number of mutable-dispatch objects to
configure in this enqueue of the command-buffer.
Expand All @@ -15845,7 +15852,7 @@ The {cl_mutable_dispatch_arg_khr_TYPE} structure is passed to
include::{generated}/api/structs/cl_mutable_dispatch_config_khr.txt[]

* _type_ is the type of this structure, and must be
{CL_STRUCTURE_TYPE_MUTABLE_DISPATCH_CONFIG_KHR}.
{CL_STRUCTURE_TYPE_MUTABLE_DISPATCH_CONFIG_KHR_anchor}.
* _next_ is `NULL` or a pointer to an extending structure.
* _command_ is a mutable-command object returned by
{clCommandNDRangeKernelKHR} representing a kernel execution as part of a
Expand Down
6 changes: 3 additions & 3 deletions scripts/checklinks.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@
sourcefile.close()

# We're not going to check API links.
#filelinks = re.findall(r"{((cl\w+)|(CL\w+))}", sourcetext)
filelinks = re.findall(r"{((CL\w+))}", sourcetext)
fileanchors = re.findall(r"{((cl\w+)|(CL\w+))_anchor}", sourcetext)
#filelinks = re.findall(r"{((cl\w+)|(CL_\w+))}", sourcetext)
filelinks = re.findall(r"{((CL_\w+))}", sourcetext)
fileanchors = re.findall(r"{((cl\w+)|(CL_\w+))_anchor}", sourcetext)

filelinks = [re.sub(r"_anchor\b", "", link[0]) for link in filelinks]
fileanchors = [anchor[0] for anchor in fileanchors]
Expand Down

0 comments on commit 5c06fd5

Please sign in to comment.