mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-19 02:52:53 +02:00
[NFC] Factor out hasForceAttributes
This is a preparation for https://reviews.llvm.org/D85586. Differential Revision: https://reviews.llvm.org/D85793
This commit is contained in:
parent
8755dd12ec
commit
2beab8ee7a
@ -88,9 +88,11 @@ static void addForcedAttributes(Function &F) {
|
||||
}
|
||||
}
|
||||
|
||||
static bool hasForceAttributes() { return !ForceAttributes.empty(); }
|
||||
|
||||
PreservedAnalyses ForceFunctionAttrsPass::run(Module &M,
|
||||
ModuleAnalysisManager &) {
|
||||
if (ForceAttributes.empty())
|
||||
if (!hasForceAttributes())
|
||||
return PreservedAnalyses::all();
|
||||
|
||||
for (Function &F : M.functions())
|
||||
|
Loading…
Reference in New Issue
Block a user