From 169af994bcd66ff967441b036500b29d2cbef6c9 Mon Sep 17 00:00:00 2001 From: Johannes Doerfert Date: Tue, 20 Aug 2019 06:09:56 +0000 Subject: [PATCH] [Attributor][NFC] Cleanup statistics code llvm-svn: 369330 --- llvm/lib/Transforms/IPO/Attributor.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/llvm/lib/Transforms/IPO/Attributor.cpp b/llvm/lib/Transforms/IPO/Attributor.cpp index 984501f..1ae658d 100644 --- a/llvm/lib/Transforms/IPO/Attributor.cpp +++ b/llvm/lib/Transforms/IPO/Attributor.cpp @@ -73,8 +73,10 @@ STATISTIC(NumAttributesManifested, #define STATS_DECL(NAME, TYPE, MSG) STATISTIC(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) \ @@ -2099,7 +2101,8 @@ struct AADereferenceableArgument final /// See AbstractAttribute::trackStatistics() void trackStatistics() const override{ - STATS_DECLTRACK_ARG_ATTR(dereferenceable)}; + STATS_DECLTRACK_ARG_ATTR(dereferenceable) + } }; /// Dereferenceable attribute for a call site argument. @@ -2208,7 +2211,7 @@ struct AAAlignArgument final : AAArgumentFromCallSiteArguments { : AAArgumentFromCallSiteArguments(IRP) {} /// See AbstractAttribute::trackStatistics() - void trackStatistics() const override{STATS_DECLTRACK_ARG_ATTR(aligned)}; + void trackStatistics() const override { STATS_DECLTRACK_ARG_ATTR(aligned) } }; struct AAAlignCallSiteArgument final : AAAlignFloating { -- 2.7.4