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)
commit2ef029c7ae2d3ef31d71b179035a3f59f6b77386
tree9bdc8d4513d78f31cbf50a85cf1be9b087423354
parent9cda4b7ed941750dde35d9a289a5c00aa1f6c872
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. :(

llvm-svn: 230040
llvm/lib/Transforms/Scalar/RewriteStatepointsForGC.cpp
llvm/test/Transforms/RewriteStatepointsForGC/basics.ll