From ae1e353a258a396022b8eff763cb0a168f05314c Mon Sep 17 00:00:00 2001 From: Florian Hahn Date: Sun, 12 Apr 2020 10:51:17 +0100 Subject: [PATCH] [VPlan] Turn classes with all public members into structs (NFC). struct should be used when all members are public: https://llvm.org/docs/CodingStandards.html#use-of-class-and-struct-keywords Reviewers: gilr, rengolin, Ayal, hsaito Reviewed By: Ayal Differential Revision: https://reviews.llvm.org/D77865 --- llvm/lib/Transforms/Vectorize/VPlanTransforms.h | 4 +--- llvm/lib/Transforms/Vectorize/VPlanValue.h | 2 +- llvm/lib/Transforms/Vectorize/VPlanVerifier.h | 5 ++--- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/llvm/lib/Transforms/Vectorize/VPlanTransforms.h b/llvm/lib/Transforms/Vectorize/VPlanTransforms.h index 4e6885f..4b20e8b 100644 --- a/llvm/lib/Transforms/Vectorize/VPlanTransforms.h +++ b/llvm/lib/Transforms/Vectorize/VPlanTransforms.h @@ -19,9 +19,7 @@ namespace llvm { -class VPlanTransforms { - -public: +struct VPlanTransforms { /// Replaces the VPInstructions in \p Plan with corresponding /// widen recipes. static void VPInstructionsToVPRecipes( diff --git a/llvm/lib/Transforms/Vectorize/VPlanValue.h b/llvm/lib/Transforms/Vectorize/VPlanValue.h index 465c47d..efad124 100644 --- a/llvm/lib/Transforms/Vectorize/VPlanValue.h +++ b/llvm/lib/Transforms/Vectorize/VPlanValue.h @@ -40,7 +40,7 @@ class VPSlotTracker; // and live-outs which the VPlan will need to fix accordingly. class VPValue { friend class VPBuilder; - friend class VPlanTransforms; + friend struct VPlanTransforms; friend class VPBasicBlock; friend class VPInterleavedAccessInfo; friend class VPSlotTracker; diff --git a/llvm/lib/Transforms/Vectorize/VPlanVerifier.h b/llvm/lib/Transforms/Vectorize/VPlanVerifier.h index 7d2b262..1c8fc89 100644 --- a/llvm/lib/Transforms/Vectorize/VPlanVerifier.h +++ b/llvm/lib/Transforms/Vectorize/VPlanVerifier.h @@ -28,10 +28,9 @@ namespace llvm { -/// Class with utility functions that can be used to check the consistency and +/// Struct with utility functions that can be used to check the consistency and /// invariants of a VPlan, including the components of its H-CFG. -class VPlanVerifier { -public: +struct VPlanVerifier { /// Verify the invariants of the H-CFG starting from \p TopRegion. The /// verification process comprises the following steps: /// 1. Region/Block verification: Check the Region/Block verification -- 2.7.4