Skip to content

Commit a99cabc

Browse files
committed
[SYCL][Doc] Add feature test macro to sycl_ext_oneapi_bfloat16
The sycl_ext_oneapi_bfloat16 extension was missing a feature test macro and the related versioning table. This commit adds these to the extension and adds the definition of the macro to the definitions file. Closes #18638. Signed-off-by: Larsen, Steffen <[email protected]>
1 parent 421bfc1 commit a99cabc

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

sycl/doc/extensions/supported/sycl_ext_oneapi_bfloat16.asciidoc

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,24 @@ in software.
9191

9292
== Specification
9393

94+
=== Feature test macro
95+
96+
This extension provides a feature-test macro as described in the core SYCL
97+
specification. An implementation supporting this extension must predefine the
98+
macro `SYCL_EXT_ONEAPI_BFLOAT16` to one of the values defined in the table
99+
below. Applications can test for the existence of this macro to determine if
100+
the implementation supports this feature, or applications can test the macro's
101+
value to determine which of the extension's features the implementation
102+
supports.
103+
104+
[%header,cols="1,5"]
105+
|===
106+
|Value
107+
|Description
108+
109+
|1
110+
|Initial version of this extension.
111+
|===
94112

95113
=== New `bfloat16` class
96114

sycl/source/feature_test.hpp.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ inline namespace _V1 {
5656
#define SYCL_EXT_ONEAPI_SUB_GROUP 1
5757
#define SYCL_EXT_ONEAPI_PROPERTIES 1
5858
#define SYCL_EXT_ONEAPI_NATIVE_MATH 1
59+
#define SYCL_EXT_ONEAPI_BFLOAT16 1
5960
#define SYCL_EXT_ONEAPI_BFLOAT16_MATH_FUNCTIONS 1
6061
#define SYCL_EXT_ONEAPI_COMPOSITE_DEVICE 1
6162
#define SYCL_EXT_INTEL_DATAFLOW_PIPES 1

0 commit comments

Comments
 (0)