llvm-6502/lib/Transforms/Scalar
Hans Wennborg 93ba133906 CodeGenPrep: turn lookup tables into switches for some targets.
This is a follow-up from r163302, which added a transformation to
SimplifyCFG that turns some switches into loads from lookup tables.

It was pointed out that some targets, such as GPUs and deeply embedded
targets, might not find this appropriate, but SimplifyCFG doesn't have
enough information about the target to decide this.

This patch adds the reverse transformation to CodeGenPrep: it turns
loads from lookup tables back into switches for targets where we do not
build jump tables (assuming these are also the targets where lookup
tables are inappropriate).

Hopefully we will eventually get to have target information in
SimplifyCFG, and then this CodeGenPrep transformation can be removed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@164206 91177308-0d34-0410-b5e6-96231b3b80d8
2012-09-19 07:48:16 +00:00
..
ADCE.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
BasicBlockPlacement.cpp Get rid of static constructors for pass registration. Instead, every pass exposes an initializeMyPassFunction(), which 2010-10-19 17:21:58 +00:00
CMakeLists.txt Introduce a new SROA implementation. 2012-09-14 09:22:59 +00:00
CodeGenPrepare.cpp CodeGenPrep: turn lookup tables into switches for some targets. 2012-09-19 07:48:16 +00:00
ConstantProp.cpp Last bit of TargetLibraryInfo propagation. Also fixed a case for TargetData 2011-12-01 21:29:16 +00:00
CorrelatedValuePropagation.cpp llvm::SwitchInst 2012-03-11 06:09:17 +00:00
DCE.cpp Make MemoryBuiltins aware of TargetLibraryInfo. 2012-08-29 15:32:21 +00:00
DeadStoreElimination.cpp DSE: Poking holes into a SetVector is expensive, avoid it if possible. 2012-09-09 16:44:05 +00:00
EarlyCSE.cpp Use LLVM_DELETED_FUNCTION in place of 'DO NOT IMPLEMENT' comments. 2012-09-15 17:09:36 +00:00
GlobalMerge.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
GVN.cpp Release build: guard dump functions with 2012-09-12 05:06:18 +00:00
IndVarSimplify.cpp Make MemoryBuiltins aware of TargetLibraryInfo. 2012-08-29 15:32:21 +00:00
JumpThreading.cpp Make MemoryBuiltins aware of TargetLibraryInfo. 2012-08-29 15:32:21 +00:00
LICM.cpp LICM may hoist an instruction with undefined behavior above a trap. 2012-09-04 10:25:04 +00:00
LLVMBuild.txt LLVMBuild: Remove trailing newline, which irked me. 2011-12-12 19:48:00 +00:00
LoopDeletion.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
LoopIdiomRecognize.cpp Make MemoryBuiltins aware of TargetLibraryInfo. 2012-08-29 15:32:21 +00:00
LoopInstSimplify.cpp Make MemoryBuiltins aware of TargetLibraryInfo. 2012-08-29 15:32:21 +00:00
LoopRotation.cpp LoopRotation: Make the brute force DomTree update more brute force. 2012-09-02 11:57:22 +00:00
LoopStrengthReduce.cpp LSR critical edge splitting fix for PR13756. 2012-09-18 17:51:33 +00:00
LoopUnrollPass.cpp LoopUnrollPass: Use variable "Threshold" instead of "CurrentThreshold" when 2012-04-04 11:44:08 +00:00
LoopUnswitch.cpp Do not pass an invalid domtree to SimplifyInstruction from 2012-05-20 01:32:09 +00:00
LowerAtomic.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
Makefile
MemCpyOptimizer.cpp MemCpyOpt: When forming a memset from stores also take GEP constexprs into account. 2012-09-13 16:29:49 +00:00
ObjCARC.cpp Mark unimplemented copy constructors and copy assignment operators as LLVM_DELETED_FUNCTION. 2012-09-18 02:01:41 +00:00
Reassociate.cpp Stop reassociate from looking through expressions of arbitrary complexity. This 2012-07-26 09:26:40 +00:00
Reg2Mem.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
Scalar.cpp Introduce a new SROA implementation. 2012-09-14 09:22:59 +00:00
ScalarReplAggregates.cpp Port the global copy optimization from the SROA pass to InstCombine. 2012-08-21 08:39:44 +00:00
SCCP.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
SimplifyCFGPass.cpp Update function names to conform to guidelines. 2012-09-06 00:59:08 +00:00
SimplifyLibCalls.cpp SimplifyLibCalls: Give all safely-shrinkable libcalls the same treatment. 2012-08-22 19:39:15 +00:00
Sink.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00
SROA.cpp Fix the last crasher I've gotten a reproduction for in SROA. This one 2012-09-18 22:37:19 +00:00
TailRecursionElimination.cpp Clean whitespaces. 2012-07-24 10:51:42 +00:00