[llvm] [Attributor][NFC] Clang format (PR #129163)
Johannes Doerfert via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 27 16:50:43 PST 2025
https://github.com/jdoerfert created https://github.com/llvm/llvm-project/pull/129163
None
>From 969a0924cae2ea0ffa4692a49f2bc85768de4cac Mon Sep 17 00:00:00 2001
From: Johannes Doerfert <johannes at jdoerfert.de>
Date: Thu, 27 Feb 2025 16:27:28 -0800
Subject: [PATCH] [Attributor][NFC] Clang format
---
llvm/include/llvm/Transforms/IPO/Attributor.h | 3 ++-
llvm/lib/Transforms/IPO/Attributor.cpp | 3 ++-
llvm/lib/Transforms/IPO/AttributorAttributes.cpp | 11 +++++------
3 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/llvm/include/llvm/Transforms/IPO/Attributor.h b/llvm/include/llvm/Transforms/IPO/Attributor.h
index 995ee54a73ce4..05951f87b5062 100644
--- a/llvm/include/llvm/Transforms/IPO/Attributor.h
+++ b/llvm/include/llvm/Transforms/IPO/Attributor.h
@@ -1208,7 +1208,8 @@ struct InformationCache {
TargetTriple(M.getTargetTriple()) {
if (UseExplorer)
Explorer = new (Allocator) MustBeExecutedContextExplorer(
- /* ExploreInterBlock */ true, /* ExploreCFGForward */ true,
+ /* ExploreInterBlock */
+ true, /* ExploreCFGForward */ true,
/* ExploreCFGBackward */ true,
/* LIGetter */
[&](const Function &F) { return AG.getAnalysis<LoopAnalysis>(F); },
diff --git a/llvm/lib/Transforms/IPO/Attributor.cpp b/llvm/lib/Transforms/IPO/Attributor.cpp
index a1e1a51b201b0..48725a5505514 100644
--- a/llvm/lib/Transforms/IPO/Attributor.cpp
+++ b/llvm/lib/Transforms/IPO/Attributor.cpp
@@ -1478,7 +1478,8 @@ bool Attributor::getAssumedSimplifiedValues(
// AAPotentialValues.
const auto *PotentialValuesAA =
getOrCreateAAFor<AAPotentialValues>(IRP, AA, DepClassTy::OPTIONAL);
- if (PotentialValuesAA && PotentialValuesAA->getAssumedSimplifiedValues(*this, Values, S)) {
+ if (PotentialValuesAA &&
+ PotentialValuesAA->getAssumedSimplifiedValues(*this, Values, S)) {
UsedAssumedInformation |= !PotentialValuesAA->isAtFixpoint();
} else if (IRP.getPositionKind() != IRPosition::IRP_RETURNED) {
Values.push_back({IRP.getAssociatedValue(), IRP.getCtxI()});
diff --git a/llvm/lib/Transforms/IPO/AttributorAttributes.cpp b/llvm/lib/Transforms/IPO/AttributorAttributes.cpp
index c1dd8bc393f33..60aa758917b0b 100644
--- a/llvm/lib/Transforms/IPO/AttributorAttributes.cpp
+++ b/llvm/lib/Transforms/IPO/AttributorAttributes.cpp
@@ -129,10 +129,7 @@ STATISTIC(NumIndirectCallsPromoted, "Number of indirect calls promoted");
STATS_DECL_(BUILD_STAT_NAME(NAME, TYPE), MSG);
#define STATS_TRACK(NAME, TYPE) ++(BUILD_STAT_NAME(NAME, TYPE));
#define STATS_DECLTRACK(NAME, TYPE, MSG) \
- { \
- STATS_DECL(NAME, TYPE, MSG) \
- STATS_TRACK(NAME, TYPE) \
- }
+ {STATS_DECL(NAME, TYPE, MSG) STATS_TRACK(NAME, TYPE)}
#define STATS_DECLTRACK_ARG_ATTR(NAME) \
STATS_DECLTRACK(NAME, Arguments, BUILD_STAT_MSG_IR_ATTR(arguments, NAME))
#define STATS_DECLTRACK_CSARG_ATTR(NAME) \
@@ -2420,7 +2417,7 @@ struct AANoFreeCallSiteArgument final : AANoFreeFloating {
}
/// See AbstractAttribute::trackStatistics()
- void trackStatistics() const override{STATS_DECLTRACK_CSARG_ATTR(nofree)};
+ void trackStatistics() const override { STATS_DECLTRACK_CSARG_ATTR(nofree) };
};
/// NoFree attribute for function return value.
@@ -6078,7 +6075,9 @@ struct AANoCaptureCallSiteArgument final : AANoCaptureImpl {
}
/// See AbstractAttribute::trackStatistics()
- void trackStatistics() const override{STATS_DECLTRACK_CSARG_ATTR(nocapture)};
+ void trackStatistics() const override {
+ STATS_DECLTRACK_CSARG_ATTR(nocapture)
+ };
};
/// NoCapture attribute for floating values.
More information about the llvm-commits
mailing list