Fix logic to determine whether to turn a switch into a lookup table. When
authorEvan Cheng <evan.cheng@apple.com>
Fri, 30 Nov 2012 02:02:42 +0000 (02:02 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Fri, 30 Nov 2012 02:02:42 +0000 (02:02 +0000)
commit65df808f6254617b9eee931d00e95d900610b660
tree53c7752f63fd5feeccf55314a78e89e2f28612b1
parent317962381a2bd6ca929bff1e8fd42271dbe85b7a
Fix logic to determine whether to turn a switch into a lookup table. When
the tables cannot fit in registers (i.e. bitmap), do not emit the table
if it's using an illegal type.

rdar://12779436

llvm-svn: 168970
llvm/lib/Transforms/Utils/SimplifyCFG.cpp
llvm/test/Transforms/SimplifyCFG/X86/switch_to_lookup_table.ll