summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/CodeGenPrepare.cpp
diff options
context:
space:
mode:
authorAndrew Wilkins <axwalk@gmail.com>2015-01-08 07:49:28 +0000
committerAndrew Wilkins <axwalk@gmail.com>2015-01-08 07:49:28 +0000
commitf3718a9bf100596cce88f0d5ed27c16a204fe58f (patch)
tree8702828af209478f458747dae64ecb9f3bb7e23e /llvm/lib/CodeGen/CodeGenPrepare.cpp
parent7c1025294316aae2d4c8023d35c5d6991a59a676 (diff)
downloadbcm5719-llvm-f3718a9bf100596cce88f0d5ed27c16a204fe58f.tar.gz
bcm5719-llvm-f3718a9bf100596cce88f0d5ed27c16a204fe58f.zip
[llgo] irgen: generate switch instructions
Summary: With this patch, llgo uses ssautil.Switches to reconstitute (and synthesise) switches, which can then be lowered to lookup tables, trees, etc. We currently only handle integer const case switches. We erase the comparison blocks (other than the initial block), and generate a switch instruction at the end of the block starting the if-else-if chain. ssautil.Switches does not remove duplicate const cases (e.g. same operands for "||"), so we do this in llgo for now. Test Plan: lit test added Reviewers: pcc Reviewed By: pcc Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D6831 llvm-svn: 225433
Diffstat (limited to 'llvm/lib/CodeGen/CodeGenPrepare.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud