diff options
| author | Yong He <yonghe@outlook.com> | 2023-07-10 12:23:07 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-10 12:23:07 -0700 |
| commit | e4d7def727f75cee3f8fdfe6f286da2b8114b329 (patch) | |
| tree | 197686d1c1736e3fd141b4b62bff5dc193a897c0 /source/slang/slang-ir.cpp | |
| parent | 5569b4850dabbb7dbcb72278bb2918c281e0d475 (diff) | |
Fix hit object emit for HLSL + FuncType specialization bug fix. (#2976)
* Fix hit object emit for HLSL.
* Fix a bug involving specialization of functon type.
* Add a test case.
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-ir.cpp')
| -rw-r--r-- | source/slang/slang-ir.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/slang/slang-ir.cpp b/source/slang/slang-ir.cpp index 74679de96..84730c913 100644 --- a/source/slang/slang-ir.cpp +++ b/source/slang/slang-ir.cpp @@ -1570,6 +1570,10 @@ namespace Slang parent = mergeCandidateParentsForHoistableInst(parent, operandParent); } + if (inst->getFullType()) + { + parent = mergeCandidateParentsForHoistableInst(parent, inst->getFullType()->getParent()); + } // We better have ended up with a parent to insert into, // or else the invariants of our IR have been violated. |
