diff --git a/llvm/lib/Transforms/IPO/FunctionAttrs.cpp b/llvm/lib/Transforms/IPO/FunctionAttrs.cpp index 011e95e9eab10..293c73a01480c 100644 --- a/llvm/lib/Transforms/IPO/FunctionAttrs.cpp +++ b/llvm/lib/Transforms/IPO/FunctionAttrs.cpp @@ -1346,8 +1346,6 @@ static bool inferAttrsFromFunctionBodies(const SCCNodeSet &SCCNodes) { } static bool setDoesNotRecurse(Function &F) { - if (F.doesNotRecurse()) - return false; F.setDoesNotRecurse(); ++NumNoRecurse; return true;