Bugfix for 229954
authorPhilip Reames <listmail@philipreames.com>
Fri, 20 Feb 2015 18:56:14 +0000 (18:56 +0000)
committerPhilip Reames <listmail@philipreames.com>
Fri, 20 Feb 2015 18:56:14 +0000 (18:56 +0000)
commitef6e26ea1f5004ddc1daa7d2a207abe73f6b3377
treed85f64ca7cc2719e39276cd0c5678c07e2d2d3cc
parentdd38f4e94d750edebb33af72aac597de6696bbb9
Bugfix for 229954

Before calling Function::getGC to test for enablement, we need to make sure there's actually a GC at all via Function::hasGC.  Otherwise, we'd crash on functions without a GC.  Thankfully, this only mattered if you manually scheduled the pass, but still, oops. :(

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@230040 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/RewriteStatepointsForGC.cpp
test/Transforms/RewriteStatepointsForGC/basics.ll