summaryrefslogtreecommitdiffstats
path: root/source/slang/slang-ir.cpp
diff options
context:
space:
mode:
authorJay Kwak <82421531+jkwak-work@users.noreply.github.com>2025-02-19 20:43:00 -0800
committerGitHub <noreply@github.com>2025-02-19 20:43:00 -0800
commit0460eb6a0b9e62c3145ab9c43d03751e19a49d8e (patch)
tree7a136d30a6f0a82ecdcf91b4da606e98b98fb148 /source/slang/slang-ir.cpp
parenta02379208f8906272d3fd773d4b5cfe8eec3be3b (diff)
Force inline functions that takes InputPatch and OutputPatch (#6407)
This commit inlines functions that takes InputPatch and OutputPatch as the function parameter. Co-authored-by: Yong He <yonghe@outlook.com>
Diffstat (limited to 'source/slang/slang-ir.cpp')
-rw-r--r--source/slang/slang-ir.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/slang/slang-ir.cpp b/source/slang/slang-ir.cpp
index 07e8b2742..cdabb1ac2 100644
--- a/source/slang/slang-ir.cpp
+++ b/source/slang/slang-ir.cpp
@@ -5259,6 +5259,11 @@ IRInst* IRBuilder::emitElementAddress(IRInst* basePtr, IRInst* index)
SLANG_ASSERT(as<IRIntLit>(index));
type = (IRType*)tupleType->getOperand(getIntVal(index));
}
+ else if (auto hlslInputPatchType = as<IRHLSLInputPatchType>(valueType))
+ {
+ type = hlslInputPatchType->getElementType();
+ }
+
SLANG_RELEASE_ASSERT(type);
auto inst = createInst<IRGetElementPtr>(
this,