[PlaceSafepoints] Adjust enablement logic to default to off and be GC configurable...
authorPhilip Reames <listmail@philipreames.com>
Sat, 21 Feb 2015 00:09:09 +0000 (00:09 +0000)
committerPhilip Reames <listmail@philipreames.com>
Sat, 21 Feb 2015 00:09:09 +0000 (00:09 +0000)
commit7a62a2a5ae27093bc87b807457e766d74e7e0ecd
tree04653fde8bb9adf82e837fa56c4e1a39da07b8f2
parentefcb2663113f5a1b6089f3387d20943e2c11f73b
[PlaceSafepoints] Adjust enablement logic to default to off and be GC configurable per GC

Previously, this pass ran over every function in the Module if added to the pass order.  With this change, it runs only over those with a GC attribute where the GC explicitly opts in.  A GC can also choose which of entry safepoint polls, backedge safepoint polls, and call safepoints it wants.  I hope to get these exposed as checks on the GCStrategy at some point, but for now, the checks are manual string comparisons.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@230097 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/PlaceSafepoints.cpp
test/Transforms/PlaceSafepoints/basic.ll
test/Transforms/PlaceSafepoints/call-in-loop.ll
test/Transforms/PlaceSafepoints/finite-loops.ll
test/Transforms/PlaceSafepoints/invokes.ll
test/Transforms/PlaceSafepoints/split-backedge.ll