diff options
| author | Yong He <yonghe@outlook.com> | 2023-09-03 12:56:31 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-09-03 12:56:31 -0700 |
| commit | 1d4b5b6fd2433a10cc7ab87626cb560f54b0acbb (patch) | |
| tree | 6196d519190720fd2968ac7d4b373e3c967d5fe6 /source/slang/slang-emit-hlsl.cpp | |
| parent | 355bb4287861f96082751042f4e58ff3598b4e5e (diff) | |
Proper lowering of functiosn that returns NonCopyable values. (#3179)
* Proper lowering of functiosn that returns NonCopyable values.
* Fix tests.
* Fix clang errors.
* Fix.
* Fix clang error.
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-emit-hlsl.cpp')
| -rw-r--r-- | source/slang/slang-emit-hlsl.cpp | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/source/slang/slang-emit-hlsl.cpp b/source/slang/slang-emit-hlsl.cpp index 30de45773..66902a624 100644 --- a/source/slang/slang-emit-hlsl.cpp +++ b/source/slang/slang-emit-hlsl.cpp @@ -1136,31 +1136,6 @@ void HLSLSourceEmitter::_emitPrefixTypeAttr(IRAttr* attr) } } -void HLSLSourceEmitter::_emitInstAsVarInitializerImpl(IRInst* inst) -{ - // Some opcodes can be folded into a variable initialization - // by allowing the variable to be "default-constructed." - // - switch (inst->getOp()) - { - case kIROp_AllocateOpaqueHandle: - if (shouldFoldInstIntoUseSites(inst)) - { - return; - } - break; - - default: - break; - } - - // We fall back to the default behavior for all targets, - // which is to emit `inst` as an initial-value expression - // after an `=`. - // - Super::_emitInstAsVarInitializerImpl(inst); -} - void HLSLSourceEmitter::emitSimpleFuncParamImpl(IRParam* param) { emitRateQualifiers(param); |
