[flang-commits] [flang] d3f58ce - [flang][openacc][NFC] remove useAccReductionCombine cl switch (#208756)
via flang-commits
flang-commits at lists.llvm.org
Wed Jul 15 04:49:00 PDT 2026
Author: jeanPerier
Date: 2026-07-15T13:48:55+02:00
New Revision: d3f58ce0cc1c3533a3085671978ded2e0e867e16
URL: https://github.com/llvm/llvm-project/commit/d3f58ce0cc1c3533a3085671978ded2e0e867e16
DIFF: https://github.com/llvm/llvm-project/commit/d3f58ce0cc1c3533a3085671978ded2e0e867e16.diff
LOG: [flang][openacc][NFC] remove useAccReductionCombine cl switch (#208756)
Follow-up of https://github.com/llvm/llvm-project/pull/208473 to remove
the switch altogether to simplify the compiler code.
Added:
Modified:
flang/lib/Optimizer/OpenACC/Support/FIROpenACCTypeInterfaces.cpp
Removed:
################################################################################
diff --git a/flang/lib/Optimizer/OpenACC/Support/FIROpenACCTypeInterfaces.cpp b/flang/lib/Optimizer/OpenACC/Support/FIROpenACCTypeInterfaces.cpp
index e0f0450ec119c..4c4d9d3879fef 100644
--- a/flang/lib/Optimizer/OpenACC/Support/FIROpenACCTypeInterfaces.cpp
+++ b/flang/lib/Optimizer/OpenACC/Support/FIROpenACCTypeInterfaces.cpp
@@ -35,12 +35,6 @@
#include "llvm/ADT/TypeSwitch.h"
#include "llvm/Support/CommandLine.h"
-static llvm::cl::opt<bool> useAccReductionCombine(
- "openacc-use-reduction-combine",
- llvm::cl::desc("Whether to generate acc.reduction_combine. Does not "
- "control reduction for MIN/MAX and logical reductions."),
- llvm::cl::init(true));
-
static llvm::cl::opt<bool> useAccReductionCombineAll(
"openacc-use-reduction-combine-all",
llvm::cl::desc("Whether to generate acc.reduction_combine for all types "
@@ -1160,8 +1154,6 @@ static bool useAccReductionCombineOp(mlir::Type elementType,
mlir::acc::ReductionOperator op) {
if (useAccReductionCombineAll)
return true;
- if (!useAccReductionCombine)
- return false;
// LOGICAL operators do not have mlir operators and requires FIR specific
// logic to interpret the TRUE and FALSE values from the storage (implemented
// in fir.convert to i1).
More information about the flang-commits
mailing list