From: Mel Chen Date: Tue, 31 May 2022 12:38:44 +0000 (-0700) Subject: [NFC] Change LoopVectorizationCostModel::useOrderedReductions() to be a const function. X-Git-Tag: upstream/15.0.7~6335 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b0fc765350fe8f7f857985718a50463d22758ef1;p=platform%2Fupstream%2Fllvm.git [NFC] Change LoopVectorizationCostModel::useOrderedReductions() to be a const function. Reviewed By: fhahn Differential Revision: https://reviews.llvm.org/D126200 --- diff --git a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp index 579d2df..268a90c 100644 --- a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp +++ b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp @@ -1310,7 +1310,7 @@ public: /// RdxDesc. This is true if the -enable-strict-reductions flag is passed, /// the IsOrdered flag of RdxDesc is set and we do not allow reordering /// of FP operations. - bool useOrderedReductions(const RecurrenceDescriptor &RdxDesc) { + bool useOrderedReductions(const RecurrenceDescriptor &RdxDesc) const { return !Hints->allowReordering() && RdxDesc.isOrdered(); }