Skip to content

[SYCL][Doc] Less verbose name for proposed FP4,8#21302

Merged
sarnex merged 1 commit intointel:syclfrom
gmlueck:me/less-verbose-fp4-8
Feb 18, 2026
Merged

[SYCL][Doc] Less verbose name for proposed FP4,8#21302
sarnex merged 1 commit intointel:syclfrom
gmlueck:me/less-verbose-fp4-8

Conversation

@gmlueck
Copy link
Contributor

@gmlueck gmlueck commented Feb 17, 2026

Update the class names for all the FP8 and FP4 types to follow this pattern:

template<size_t N>
class fp8_e4m3_x {/*...*/};

using fp8_e4m3 = fp8_e4m3_x<1>;
using fp8_e4m3_x2 = fp8_e4m3_x<2>;

This is less verbose in the common case where the user knows they want either 1 or 2 elements. For anyone writing generic code, where the number of elements is a parameter, you can still use the fp8_e4m3_x<N> form.

Update the class names for all the FP8 and FP4 types to follow
this pattern:

```
template<size_t N>
class fp8_e4m3_x {/*...*/};

using fp8_e4m3 = fp8_e4m3_x<1>;
using fp8_e4m3_x2 = fp8_e4m3_x<2>;
```

This is less verbose in the common case where the user knows they want
either 1 or 2 elements.  For anyone writing generic code, where the
number of elements is a parameter, you can still use the `fp8_e4m3_x<N>`
form.
@gmlueck gmlueck requested a review from a team as a code owner February 17, 2026 19:02
@github-actions
Copy link
Contributor

@intel/llvm-gatekeepers please consider merging

@gmlueck
Copy link
Contributor Author

gmlueck commented Feb 18, 2026

@intel/llvm-gatekeepers I think this is ready to merge.

@sarnex sarnex merged commit b3b917e into intel:sycl Feb 18, 2026
3 checks passed
@gmlueck gmlueck deleted the me/less-verbose-fp4-8 branch February 18, 2026 15:57
luszczewskakasia1 pushed a commit to luszczewskakasia1/llvm that referenced this pull request Feb 26, 2026
Update the class names for all the FP8 and FP4 types to follow this
pattern:

```
template<size_t N>
class fp8_e4m3_x {/*...*/};

using fp8_e4m3 = fp8_e4m3_x<1>;
using fp8_e4m3_x2 = fp8_e4m3_x<2>;
```

This is less verbose in the common case where the user knows they want
either 1 or 2 elements. For anyone writing generic code, where the
number of elements is a parameter, you can still use the `fp8_e4m3_x<N>`
form.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants