diff options
| author | Yong He <yonghe@outlook.com> | 2022-08-24 10:56:53 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-08-24 10:56:53 -0700 |
| commit | d245c72f2a92a74ccda83f41758c1948ae5132d3 (patch) | |
| tree | f036e1f2afb7febe2de9b09990bcde6c04f3bad1 /source/slang/slang-ir-ssa-simplification.cpp | |
| parent | 0b808453407f8feef8574cae99afd90771712185 (diff) | |
Compiler time evaluation of all int and bool operators. (#2376)
* Compiler time evaluation of all int and bool operators.
* Fix linux compile error.
* Fix.
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-ir-ssa-simplification.cpp')
| -rw-r--r-- | source/slang/slang-ir-ssa-simplification.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/slang/slang-ir-ssa-simplification.cpp b/source/slang/slang-ir-ssa-simplification.cpp index 22aea8d36..f723325c4 100644 --- a/source/slang/slang-ir-ssa-simplification.cpp +++ b/source/slang/slang-ir-ssa-simplification.cpp @@ -6,6 +6,7 @@ #include "slang-ir-dce.h" #include "slang-ir-simplify-cfg.h" #include "slang-ir-peephole.h" +#include "slang-ir-hoist-constants.h" namespace Slang { @@ -21,6 +22,7 @@ namespace Slang while (changed && iterationCounter < kMaxIterations) { changed = false; + changed |= hoistConstants(module); changed |= applySparseConditionalConstantPropagation(module); changed |= peepholeOptimize(module); changed |= simplifyCFG(module); |
