From d52376a65f37fcbbb67428b917fd3819436b6dfb Mon Sep 17 00:00:00 2001 From: Yong He Date: Tue, 2 May 2023 20:29:38 -0700 Subject: Various dxc/fxc compatibility fixes. (#2863) * Various dxc/fxc compatibility fixes. * Cleanup. * Fix test cases. * Fix comments. --------- Co-authored-by: Yong He --- source/slang/slang-ir-util.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source/slang/slang-ir-util.cpp') diff --git a/source/slang/slang-ir-util.cpp b/source/slang/slang-ir-util.cpp index 95240a26c..506e96c81 100644 --- a/source/slang/slang-ir-util.cpp +++ b/source/slang/slang-ir-util.cpp @@ -430,6 +430,11 @@ bool canInstHaveSideEffectAtAddress(IRGlobalValueWithCode* func, IRInst* inst, I if (canAddressesPotentiallyAlias(func, as(inst)->getPtr(), addr)) return true; break; + case kIROp_SwizzledStore: + // If the target of the swizzled store inst may overlap addr, return true. + if (canAddressesPotentiallyAlias(func, as(inst)->getDest(), addr)) + return true; + break; case kIROp_Call: { auto call = as(inst); -- cgit v1.2.3