[llvm] Add a pass to convert jump tables to switches. (PR #77709)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 11 00:45:44 PST 2024
================
@@ -557,6 +558,7 @@ PassBuilder::buildFunctionSimplificationPipeline(OptimizationLevel Level,
// Optimize based on known information about branches, and cleanup afterward.
FPM.addPass(JumpThreadingPass());
+ FPM.addPass(JumpTableToSwitchPass());
----------------
nikic wrote:
The JumpThreading and CVP passes must be directly next to each other. You are going to invalidate LVI if JumpTableToSwitch does a transform.
https://github.com/llvm/llvm-project/pull/77709
More information about the llvm-commits
mailing list