diff options
| author | Yong He <yonghe@outlook.com> | 2023-05-10 19:27:47 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-05-10 19:27:47 -0700 |
| commit | 952e04466a18e9d03fcb018ce9213f34b93ca74a (patch) | |
| tree | ce0597052bc90c7335c76ad2be73844878a8c9f7 /source/slang/slang-ir-peephole.cpp | |
| parent | 99bc31fdd6fd9a6cbce6afd5fa9b52fb47873f61 (diff) | |
Fix intellisense and autodiff crashes. (#2879)
* Fix intellisense crash.
* Fix a bug in updateElement simplification.
* cleanup.
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-ir-peephole.cpp')
| -rw-r--r-- | source/slang/slang-ir-peephole.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/slang/slang-ir-peephole.cpp b/source/slang/slang-ir-peephole.cpp index e07d1f9c4..376795855 100644 --- a/source/slang/slang-ir-peephole.cpp +++ b/source/slang/slang-ir-peephole.cpp @@ -50,7 +50,7 @@ struct PeepholeContext : InstPassBase return false; isAccessChainEqual = true; - for (UInt i = 0; i < (UInt)chainKey.getCount(); i++) + for (UInt i = 0; i < updateInst->getAccessKeyCount(); i++) { if (updateInst->getAccessKey(i) != chainKey[i]) { |
