[PATCH] Switch to Select range optimization

Marcello Maggioni hayarms at gmail.com
Fri Nov 14 09:45:34 PST 2014


Hi hans,

This is a follow up for http://reviews.llvm.org/D5620 .

This optimization tries one step further trying to detect cases where we can use a pivot to distinguish between the two case groups.

At the moment if the optimization detects that a default target is present in the switch it bails out, but it tries to see if that default can trigger or not.

http://reviews.llvm.org/D6269

Files:
  lib/Transforms/Utils/SimplifyCFG.cpp
  test/Transforms/SimplifyCFG/switch-to-select-range.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6269.16222.patch
Type: text/x-patch
Size: 8060 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141114/cfa31e8a/attachment.bin>


More information about the llvm-commits mailing list