Name Strings
SPV_INTEL_predicated_io
Contact
To report problems with this extension, please open a new issue at:
Contributors
-
Ben Ashbaugh, Intel
-
Yury Plyakhin, Intel
Notice
Copyright (c) 2025-2026 Intel Corporation. All rights reserved.
Status
-
Complete
Version
Last Modified Date |
2026-04-29 |
Revision |
1 |
Dependencies
This extension is written against the SPIR-V Specification, Version 1.6, Revision 7.
This extension requires SPIR-V 1.0.
This extension interacts with the SPV_KHR_untyped_pointers extension, by accepting untyped pointers as pointer operands.
This extension interacts with the SPV_INTEL_cache_controls extension, by supporting cache control decorations on the pointer operands.
Overview
This extension adds predicated load and store instructions. Predicated load performs load from memory if predicate is true, otherwise, it uses default_value as a result:
if (predicate)
result = load(address);
else
result = default_value;
Predicated store performs store of value to memory if predicate is true. Otherwise, it does nothing:
if (predicate)
store(address, value);
These instructions allow to reduce branches and hence simplify control flow graph resulting in more efficient machine code.
Extension Name
To use this extension within a SPIR-V module, the appropriate OpExtension must be present in the module:
OpExtension "SPV_INTEL_predicated_io"
Modifications to the SPIR-V Specification, Version 1.6
Capabilities
Modify Section 3.2.30, Capability, adding rows to the Capability table:
| Capability | Implicitly Declares | |
|---|---|---|
6257 |
PredicatedIOINTEL |
|
Instructions
Modify Section 3.3.8, Memory Instructions, adding to the end of the list of instructions:
Load through a Pointer, if Predicate is true, otherwise use Default Value as a result of the operation. Result Type is the type of the loaded object. It must be a scalar or vector of numerical-type. Pointer is the pointer to load through. Its type must be a pointer. Predicate must be a Scalar Boolean type. The type of Default Value must be the same as Result Type. If present, any Memory Operands must begin with a memory operand literal. If not present, it is the same as specifying the memory operand None. Volatile is not allowed. |
Capability: |
||||||
6 + variable |
6258 |
<id> |
<id> |
<id> |
<id> |
<id> |
Optional |
Store through a Pointer, if Predicate is true. Pointer is the pointer to store through. Its type must be a pointer. Object is the object to store. It’s type must be a scalar or vector of numerical-type. Predicate must be a Scalar Boolean type. If present, any Memory Operands must begin with a memory operand literal. If not present, it is the same as specifying the memory operand None. Volatile is not allowed. |
Capability: |
||||
4 + variable |
6259 |
<id> |
<id> |
<id> |
Optional |
Issues
-
Should we require Aligned to always be provided as memory operand?
RESOLVED: No, we do not need to require that the alignment memory operand is present, since alignment requirements are well-defined without it. For typed pointers the compiler can assert that the pointer is aligned to the type that it points to: https://registry.khronos.org/OpenCL/specs/3.0-unified/html/OpenCL_Env.html#_alignment_of_types
For untyped pointers, we expect untyped pointers will have the alignment memory operand in general.
-
Should we document that Aligned is the only supported memory operand?
RESOLVED: No, we should not. Potentially other memory operands can be also useful. We will not document requirements for memory operands (except Volatile) in this spec.
-
Should we allow Volatile memory operand?
RESOLVED: No, we should not. We don’t expect customers for volatile predicated load/stores. Predicated load/stores are a performance feature. If anyone needs volatile load/store, they can use normal control flow. Since, supporting volatile semantics doesn’t look necessary for predicated memory access and requires additional efforts (both implementation and testing), we have decided to disallow it.
Revision History
| Rev | Date | Author | Changes |
|---|---|---|---|
1 |
2026-04-29 |
Yury Plyakhin |
Initial version for publication |