[FunctionAttrs] Fix SCC logic around operand bundles
authorSanjoy Das <sanjoy@playingwithpointers.com>
Tue, 9 Feb 2016 18:40:40 +0000 (18:40 +0000)
committerSanjoy Das <sanjoy@playingwithpointers.com>
Tue, 9 Feb 2016 18:40:40 +0000 (18:40 +0000)
commit10c8a04b80f904420ca803c638421068788c30fd
treec92ccd3cd00bf82bc43a35ae50c4594196780bb1
parent2058e9dff09d2ba750602429717aa16d22e24719
[FunctionAttrs] Fix SCC logic around operand bundles

FunctionAttrs does an "optimistic" analysis of SCCs as a unit, which
means normally it is able to disregard calls from an SCC into itself.
However, calls and invokes with operand bundles are allowed to have
memory effects not fully described by the memory effects on the call
target, so we can't be optimistic around operand-bundled calls from an
SCC into itself.

llvm-svn: 260244
llvm/lib/Transforms/IPO/FunctionAttrs.cpp
llvm/test/Transforms/FunctionAttrs/operand-bundles-scc.ll [new file with mode: 0644]