[PATCH] Improving LowerSwitch behavior for contiguous ranges
Eric Christopher
echristo at gmail.com
Tue Jun 10 11:52:18 PDT 2014
On Tue, Jun 10, 2014 at 11:48 AM, Owen Anderson <resistor at mac.com> wrote:
>
> On Jun 10, 2014, at 11:37 AM, Hal Finkel <hfinkel at anl.gov> wrote:
>
>
> Yep. Though I have to admit that it'd be nice if we had a range
> propagation pass that would clean this up rather than special casing.
> :\
>
>
> Doesn't LVI do range propagation?
>
>
>
> Sort of.
>
> That said, range propagation isn’t a good solution to this problem.
> SwitchLowering generally happens towards the end of a compilation pipeline,
> and you don’t want to run any significant set of CFG optimizations after it
> because they might re-introduce switches.
>
Fair enough. I figured range propagation would just prove dead blocks
without doing significant CFG optimizations.
-eric
More information about the llvm-commits
mailing list