diff options
| author | Yong He <yonghe@outlook.com> | 2023-10-02 03:33:58 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-10-02 18:33:58 +0800 |
| commit | ccf2611c024ab12dcccd978f3f501d4ee9fc52bc (patch) | |
| tree | f4df843e3b46886005d6bfbae34dc3bcc6fb8321 /source/slang/slang-ir.cpp | |
| parent | 6138de5f084cafdc98381237c2d8bed7c8804f1c (diff) | |
Add SPIRV intrinsics for ShaderExecutionReordering and RW/Buffer. (#3252)
* Add SPIRV intrinsics for ShaderExecutionReordering.
* Add intrinsics for `Buffer` and `RWBuffer`.
* Various spirv fixes.
* Marshal bool vector type.
* Inline global constants + OpFOrdNotEqual->OpFUnordNotEqual.
* Fix.
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-ir.cpp')
| -rw-r--r-- | source/slang/slang-ir.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/source/slang/slang-ir.cpp b/source/slang/slang-ir.cpp index f8d2b3117..3b7fb9ac8 100644 --- a/source/slang/slang-ir.cpp +++ b/source/slang/slang-ir.cpp @@ -3448,6 +3448,18 @@ namespace Slang return inst; } + IRInst* IRBuilder::emitGlobalValueRef(IRInst* globalInst) + { + auto inst = createInst<IRGlobalValueRef>( + this, + kIROp_GlobalValueRef, + (IRType*)globalInst->getFullType(), + globalInst); + + addInst(inst); + return inst; + } + IRInst* IRBuilder::emitPackAnyValue(IRType* type, IRInst* value) { auto inst = createInst<IRPackAnyValue>( |
