@@ -2559,7 +2559,7 @@ convertOmpWsloop(Operation &opInst, llvm::IRBuilderBase &builder,
2559
2559
2560
2560
// Initialize linear variables and linear step
2561
2561
LinearClauseProcessor linearClauseProcessor;
2562
- if (wsloopOp.getLinearVars ().size ()) {
2562
+ if (! wsloopOp.getLinearVars ().empty ()) {
2563
2563
for (mlir::Value linearVar : wsloopOp.getLinearVars ())
2564
2564
linearClauseProcessor.createLinearVar (builder, moduleTranslation,
2565
2565
linearVar);
@@ -2576,7 +2576,7 @@ convertOmpWsloop(Operation &opInst, llvm::IRBuilderBase &builder,
2576
2576
llvm::CanonicalLoopInfo *loopInfo = findCurrentLoopInfo (moduleTranslation);
2577
2577
2578
2578
// Emit Initialization and Update IR for linear variables
2579
- if (wsloopOp.getLinearVars ().size ()) {
2579
+ if (! wsloopOp.getLinearVars ().empty ()) {
2580
2580
llvm::OpenMPIRBuilder::InsertPointOrErrorTy afterBarrierIP =
2581
2581
linearClauseProcessor.initLinearVar (builder, moduleTranslation,
2582
2582
loopInfo->getPreheader ());
@@ -2602,7 +2602,7 @@ convertOmpWsloop(Operation &opInst, llvm::IRBuilderBase &builder,
2602
2602
return failure ();
2603
2603
2604
2604
// Emit finalization and in-place rewrites for linear vars.
2605
- if (wsloopOp.getLinearVars ().size ()) {
2605
+ if (! wsloopOp.getLinearVars ().empty ()) {
2606
2606
llvm::OpenMPIRBuilder::InsertPointTy oldIP = builder.saveIP ();
2607
2607
assert (loopInfo->getLastIter () &&
2608
2608
" `lastiter` in CanonicalLoopInfo is nullptr" );
0 commit comments