[Mlir-commits] [mlir] 53be2e0 - [MLIR] NFC. JitRunner - use range-based for
Uday Bondhugula
llvmlistbot at llvm.org
Sun May 28 13:26:19 PDT 2023
Author: Uday Bondhugula
Date: 2023-05-29T01:54:50+05:30
New Revision: 53be2e0f59730671eac24c9e9ce615d20250d917
URL: https://github.com/llvm/llvm-project/commit/53be2e0f59730671eac24c9e9ce615d20250d917
DIFF: https://github.com/llvm/llvm-project/commit/53be2e0f59730671eac24c9e9ce615d20250d917.diff
LOG: [MLIR] NFC. JitRunner - use range-based for
Address clang-tidy warning in JitRunner.cpp. Use range-based for.
Added:
Modified:
mlir/lib/ExecutionEngine/JitRunner.cpp
Removed:
################################################################################
diff --git a/mlir/lib/ExecutionEngine/JitRunner.cpp b/mlir/lib/ExecutionEngine/JitRunner.cpp
index 9464ce849b85..b4279af7642f 100644
--- a/mlir/lib/ExecutionEngine/JitRunner.cpp
+++ b/mlir/lib/ExecutionEngine/JitRunner.cpp
@@ -393,8 +393,8 @@ int mlir::JitRunnerMain(int argc, char **argv, const DialectRegistry ®istry,
// Configure TargetMachine builder based on the command line options
llvm::SubtargetFeatures features;
if (!options.mAttrs.empty()) {
- for (unsigned i = 0; i != options.mAttrs.size(); ++i)
- features.AddFeature(options.mAttrs[i]);
+ for (StringRef attr : options.mAttrs)
+ features.AddFeature(attr);
tmBuilderOrError->addFeatures(features.getFeatures());
}
More information about the Mlir-commits
mailing list