diff options
| author | Yong He <yonghe@outlook.com> | 2023-05-31 12:36:48 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-05-31 12:36:48 -0700 |
| commit | 5dd401e416e18fdfe904a66284b0cf56cf256ec7 (patch) | |
| tree | 78c18e41b683261138f1b6349a34057d145a3ae2 /source/slang/slang-lower-to-ir.cpp | |
| parent | 57f0ab410766374b155fa546c31812d593480048 (diff) | |
Fix div-by-zero error during sccp. (#2911)
* Diagnose on div-by-zero during sccp.
* fix
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-lower-to-ir.cpp')
| -rw-r--r-- | source/slang/slang-lower-to-ir.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/slang/slang-lower-to-ir.cpp b/source/slang/slang-lower-to-ir.cpp index 486c152d5..b36f0dc94 100644 --- a/source/slang/slang-lower-to-ir.cpp +++ b/source/slang/slang-lower-to-ir.cpp @@ -9657,7 +9657,7 @@ RefPtr<IRModule> generateIRForTranslationUnit( // constructSSA(module); simplifyCFG(module); - applySparseConditionalConstantPropagation(module); + applySparseConditionalConstantPropagation(module, compileRequest->getSink()); // Next, inline calls to any functions that have been // marked for mandatory "early" inlining. @@ -9677,7 +9677,7 @@ RefPtr<IRModule> generateIRForTranslationUnit( // constructSSA(module); simplifyCFG(module); - applySparseConditionalConstantPropagation(module); + applySparseConditionalConstantPropagation(module, compileRequest->getSink()); // Propagate `constexpr`-ness through the dataflow graph (and the // call graph) based on constraints imposed by different instructions. |
