diff --git a/flang/include/flang/Lower/CallInterface.h b/flang/include/flang/Lower/CallInterface.h index 8586a056f180e..ec025e792349a 100644 --- a/flang/include/flang/Lower/CallInterface.h +++ b/flang/include/flang/Lower/CallInterface.h @@ -106,7 +106,7 @@ class CallInterface { /// Value means passed by value at the mlir level, it is not necessarily /// implied by Fortran Value attribute. Value, - /// ValueAttribute means dummy has the the Fortran VALUE attribute. + /// ValueAttribute means dummy has the Fortran VALUE attribute. BaseAddressValueAttribute, CharBoxValueAttribute, // BoxChar with VALUE // Passing a character procedure as a diff --git a/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h b/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h index b3fe52f4b7146..b2774263e7a31 100644 --- a/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h +++ b/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h @@ -380,7 +380,7 @@ struct RuntimeTableEntry, RuntimeIdentifier> { /// fir::runtime::RuntimeTableEntry, "_FortranASumReal4"))> /// ``` -/// These entries are then used to to generate the MLIR FunctionType that +/// These entries are then used to generate the MLIR FunctionType that /// correspond to the runtime function declaration in C++. #undef FirE #define FirE(L, I) (I < sizeof(L) / sizeof(*L) ? L[I] : 0) diff --git a/flang/include/flang/Optimizer/Builder/Runtime/Reduction.h b/flang/include/flang/Optimizer/Builder/Runtime/Reduction.h index 1e848e36fe7fc..667ea9081a893 100644 --- a/flang/include/flang/Optimizer/Builder/Runtime/Reduction.h +++ b/flang/include/flang/Optimizer/Builder/Runtime/Reduction.h @@ -136,7 +136,7 @@ mlir::Value genMinval(fir::FirOpBuilder &builder, mlir::Location loc, mlir::Value arrayBox, mlir::Value maskBox); /// Generate call to `MinvalCharacter` intrinsic runtime routine. This is the -/// version that that handles 1 dimensional character arrays with no DIM +/// version that handles 1 dimensional character arrays with no DIM /// argument. void genMinvalChar(fir::FirOpBuilder &builder, mlir::Location loc, mlir::Value resultBox, mlir::Value arrayBox, diff --git a/flang/lib/Decimal/big-radix-floating-point.h b/flang/lib/Decimal/big-radix-floating-point.h index d6b1ccd791fbb..7d5d31b7788d7 100644 --- a/flang/lib/Decimal/big-radix-floating-point.h +++ b/flang/lib/Decimal/big-radix-floating-point.h @@ -335,7 +335,7 @@ template class BigRadixFloatingPointNumber { // Adds another number and then divides by two. // Assumes same exponent and sign. - // Returns true when the the result has effectively been rounded down. + // Returns true when the result has effectively been rounded down. bool Mean(const BigRadixFloatingPointNumber &); // Parses a floating-point number; leaves the pointer reference diff --git a/flang/lib/Lower/ConvertExpr.cpp b/flang/lib/Lower/ConvertExpr.cpp index 5ca76f0f06168..191319c8ea3bb 100644 --- a/flang/lib/Lower/ConvertExpr.cpp +++ b/flang/lib/Lower/ConvertExpr.cpp @@ -4564,7 +4564,7 @@ class ArrayExprLowering { } /// If there were temporaries created for this element evaluation, finalize - /// and deallocate the resources now. This should be done just prior the the + /// and deallocate the resources now. This should be done just prior to the /// fir::ResultOp at the end of the innermost loop. void finalizeElementCtx() { if (elementCtx) { diff --git a/flang/lib/Lower/OpenMP.cpp b/flang/lib/Lower/OpenMP.cpp index 2469a7b4fd35f..9cb370e6130dc 100644 --- a/flang/lib/Lower/OpenMP.cpp +++ b/flang/lib/Lower/OpenMP.cpp @@ -1854,7 +1854,7 @@ static mlir::Operation *getCompareFromReductionOp(mlir::Operation *reductionOp, } /// The COMMON block is a global structure. \p commonValue is the base address -/// of the the COMMON block. As the offset from the symbol \p sym, generate the +/// of the COMMON block. As the offset from the symbol \p sym, generate the /// COMMON block member value (commonValue + offset) for the symbol. /// FIXME: Share the code with `instantiateCommon` in ConvertVariable.cpp. static mlir::Value diff --git a/flang/lib/Optimizer/CodeGen/CodeGen.cpp b/flang/lib/Optimizer/CodeGen/CodeGen.cpp index a05f019471dfe..e51050b5a594a 100644 --- a/flang/lib/Optimizer/CodeGen/CodeGen.cpp +++ b/flang/lib/Optimizer/CodeGen/CodeGen.cpp @@ -3150,12 +3150,12 @@ static void genCaseLadderStep(mlir::Location loc, mlir::Value cmp, /// Depending on the case condition type, one or several comparison and /// conditional branching can be generated. /// -/// A a point value case such as `case(4)`, a lower bound case such as +/// A point value case such as `case(4)`, a lower bound case such as /// `case(5:)` or an upper bound case such as `case(:3)` are converted to a /// simple comparison between the selector value and the constant value in the /// case. The block associated with the case condition is then executed if /// the comparison succeed otherwise it branch to the next block with the -/// comparison for the the next case conditon. +/// comparison for the next case conditon. /// /// A closed interval case condition such as `case(7:10)` is converted with a /// first comparison and conditional branching for the lower bound. If diff --git a/flang/lib/Semantics/expression.cpp b/flang/lib/Semantics/expression.cpp index 7d9b3188a6099..d690f3da6820d 100644 --- a/flang/lib/Semantics/expression.cpp +++ b/flang/lib/Semantics/expression.cpp @@ -2742,7 +2742,7 @@ const Symbol *AssumedTypeDummy(const parser::Name &name) { template static const Symbol *AssumedTypePointerOrAllocatableDummy(const A &object) { // It is illegal for allocatable of pointer objects to be TYPE(*), but at that - // point it is is not guaranteed that it has been checked the object has + // point it is not guaranteed that it has been checked the object has // POINTER or ALLOCATABLE attribute, so do not assume nullptr can be directly // returned. return common::visit( diff --git a/flang/lib/Semantics/resolve-names.cpp b/flang/lib/Semantics/resolve-names.cpp index 2a0f4ab9f4171..0b4b940fa1d1c 100644 --- a/flang/lib/Semantics/resolve-names.cpp +++ b/flang/lib/Semantics/resolve-names.cpp @@ -713,7 +713,7 @@ class ScopeHandler : public ImplicitRulesVisitor { std::vector *> equivalenceSets; // Names of all common block objects in the scope std::set commonBlockObjects; - // Info about about SAVE statements and attributes in current scope + // Info about SAVE statements and attributes in current scope struct { std::optional saveAll; // "SAVE" without entity list std::set entities; // names of entities with save attr