https://github.com/nikic commented: Shouldn't this transform be part of SwitchToLookupTable()? I'm not sure it makes sense to do this independently, if we can't form a lookup table. https://github.com/llvm/llvm-project/pull/70977