diff options
| author | Yong He <yonghe@outlook.com> | 2024-03-08 18:08:24 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-08 18:08:24 -0800 |
| commit | 0629b22bf09ae6b3c3689c5f98492df7577bf0d2 (patch) | |
| tree | 286eaf6268986b1ecb3cc19e8f3b72495e881d78 /source/slang/slang-emit.cpp | |
| parent | 21502874666c282a3c5fa1f802deff27fab4e93b (diff) | |
Enhance link-time type test. (#3724)
* Enhance link-time type test.
* Fix.
* Fix.
Diffstat (limited to 'source/slang/slang-emit.cpp')
| -rw-r--r-- | source/slang/slang-emit.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/slang/slang-emit.cpp b/source/slang/slang-emit.cpp index 1d72fd233..5ec6fa62a 100644 --- a/source/slang/slang-emit.cpp +++ b/source/slang/slang-emit.cpp @@ -491,6 +491,11 @@ Result linkAndOptimizeIR( validateIRModuleIfEnabled(codeGenContext, irModule); + // If we have any witness tables that are marked as `KeepAlive`, + // but are not used for dynamic dispatch, unpin them so we don't + // do unnecessary work to lower them. + unpinWitnessTables(irModule); + simplifyIR(targetProgram, irModule, IRSimplificationOptions::getFast(), sink); if (!ArtifactDescUtil::isCpuLikeTarget(artifactDesc)) |
