diff --git a/clang/docs/LanguageExtensions.rst b/clang/docs/LanguageExtensions.rst --- a/clang/docs/LanguageExtensions.rst +++ b/clang/docs/LanguageExtensions.rst @@ -3998,7 +3998,7 @@ addition across statements regardless of any controlling pragmas. ``#pragma clang fp exceptions`` specifies floating point exception behavior. It -may take one the the values: ``ignore``, ``maytrap`` or ``strict``. Meaning of +may take one of the values: ``ignore``, ``maytrap`` or ``strict``. Meaning of these values is same as for `constrained floating point intrinsics `_. .. code-block:: c++ diff --git a/clang/docs/MatrixTypes.rst b/clang/docs/MatrixTypes.rst --- a/clang/docs/MatrixTypes.rst +++ b/clang/docs/MatrixTypes.rst @@ -208,7 +208,7 @@ ``M2 __builtin_matrix_transpose(M1 matrix)`` **Remarks**: The return type is a cv-unqualified matrix type that has the same -element type as ``M1`` and has the the same number of rows as ``M1`` has columns and +element type as ``M1`` and has the same number of rows as ``M1`` has columns and the same number of columns as ``M1`` has rows. **Returns**: A matrix ``Res`` equivalent to the code below, where ``col`` refers to the diff --git a/clang/docs/UndefinedBehaviorSanitizer.rst b/clang/docs/UndefinedBehaviorSanitizer.rst --- a/clang/docs/UndefinedBehaviorSanitizer.rst +++ b/clang/docs/UndefinedBehaviorSanitizer.rst @@ -114,7 +114,7 @@ Issues caught by these sanitizers are not undefined behavior, but are often unintentional. - ``-fsanitize=implicit-integer-sign-change``: Implicit conversion between - integer types, if that changes the sign of the value. That is, if the the + integer types, if that changes the sign of the value. That is, if the original value was negative and the new value is positive (or zero), or the original value was positive, and the new value is negative. Issues caught by this sanitizer are not undefined behavior, diff --git a/clang/docs/analyzer/checkers.rst b/clang/docs/analyzer/checkers.rst --- a/clang/docs/analyzer/checkers.rst +++ b/clang/docs/analyzer/checkers.rst @@ -2466,7 +2466,7 @@ // Below we receive a warning because the 3rd parameter should be the // number of elements to read, not the size in bytes. This case is a known - // vulnerability described by the the ARR38-C SEI-CERT rule. + // vulnerability described by the ARR38-C SEI-CERT rule. fread(wbuf, size, nitems, file); } diff --git a/clang/lib/StaticAnalyzer/Checkers/cert/InvalidPtrChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/cert/InvalidPtrChecker.cpp --- a/clang/lib/StaticAnalyzer/Checkers/cert/InvalidPtrChecker.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/cert/InvalidPtrChecker.cpp @@ -132,7 +132,7 @@ return; Out << '\''; FD->getNameForDiagnostic(Out, FD->getASTContext().getLangOpts(), true); - Out << "' call may invalidate the the result of the previous " << '\''; + Out << "' call may invalidate the result of the previous " << '\''; FD->getNameForDiagnostic(Out, FD->getASTContext().getLangOpts(), true); Out << '\''; }); diff --git a/clang/test/Analysis/cert/env34-c.c b/clang/test/Analysis/cert/env34-c.c --- a/clang/test/Analysis/cert/env34-c.c +++ b/clang/test/Analysis/cert/env34-c.c @@ -39,7 +39,7 @@ *p; // no-warning p2 = getenv("VAR2"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} *p; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -55,7 +55,7 @@ p = getenv("VAR2"); // expected-note@-1{{previous function call was here}} p2 = getenv("VAR2"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} p3 = getenv("VAR3"); @@ -70,7 +70,7 @@ p = getenv("VAR"); // expected-note@-1{{previous function call was here}} p2 = getenv("VAR2"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} p3 = getenv("VAR3"); *p; @@ -85,7 +85,7 @@ p2 = getenv("VAR2"); // expected-note@-1{{previous function call was here}} p3 = getenv("VAR3"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} *p2; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -103,7 +103,7 @@ p2 = getenv("VAR3"); // expected-note@-1{{previous function call was here}} - // expected-note@-2{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-2{{'getenv' call may invalidate the result of the previous 'getenv'}} *p; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -112,7 +112,7 @@ *p2; // no-warning p = getenv("VAR4"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} *p; // no-warning *p2; @@ -127,7 +127,7 @@ *p; // no-warning p2 = getenv("VAR2"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} foo(p); // expected-warning@-1{{use of invalidated pointer 'p' in a function call}} @@ -152,7 +152,7 @@ if( !array[1] ) // expected-note@-1{{Taking true branch}} array[1] = getenv("TMPDIR"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} *array[0]; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -169,7 +169,7 @@ void getenv_test10(void) { strcmp(getenv("VAR1"), getenv("VAR2")); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} // expected-note@-2{{previous function call was here}} // expected-warning@-3{{use of invalidated pointer 'getenv("VAR1")' in a function call}} // expected-note@-4{{use of invalidated pointer 'getenv("VAR1")' in a function call}} @@ -186,7 +186,7 @@ // expected-note@-1{{previous function call was here}} char *pp = getenv("VAR2"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} dereference_pointer(p); // expected-note@-1{{Calling 'dereference_pointer'}} @@ -200,7 +200,7 @@ // expected-note@-1{{Assuming 'flag1' is not equal to 0}} // expected-note@-2{{Taking true branch}} char *pp = getenv("VAR2"); - // expected-note@-1{{'getenv' call may invalidate the the result of the previous 'getenv'}} + // expected-note@-1{{'getenv' call may invalidate the result of the previous 'getenv'}} } if (flag2) { @@ -222,7 +222,7 @@ *p; // no-warning p2 = setlocale(0, "VAR3"); - // expected-note@-1{{'setlocale' call may invalidate the the result of the previous 'setlocale'}} + // expected-note@-1{{'setlocale' call may invalidate the result of the previous 'setlocale'}} *p; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -242,7 +242,7 @@ // expected-note@-1{{Assuming 'flag' is not equal to 0}} // expected-note@-2{{Taking true branch}} p2 = setlocale(0, "VAR3"); - // expected-note@-1{{'setlocale' call may invalidate the the result of the previous 'setlocale'}} + // expected-note@-1{{'setlocale' call may invalidate the result of the previous 'setlocale'}} } *p; @@ -261,7 +261,7 @@ *p; // no-warning p2 = strerror(2); - // expected-note@-1{{'strerror' call may invalidate the the result of the previous 'strerror'}} + // expected-note@-1{{'strerror' call may invalidate the result of the previous 'strerror'}} *p; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -290,7 +290,7 @@ // expected-note@-1{{Assuming 'errno' is not equal to 0}} // expected-note@-2{{Taking true branch}} p2 = strerror(errno); - // expected-note@-1{{'strerror' call may invalidate the the result of the previous 'strerror'}} + // expected-note@-1{{'strerror' call may invalidate the result of the previous 'strerror'}} } *p; @@ -305,7 +305,7 @@ char* p = asctime(t); // expected-note@-1{{previous function call was here}} char* pp = asctime(tt); - // expected-note@-1{{'asctime' call may invalidate the the result of the previous 'asctime'}} + // expected-note@-1{{'asctime' call may invalidate the result of the previous 'asctime'}} *p; // expected-warning@-1{{dereferencing an invalid pointer}} @@ -316,7 +316,7 @@ lconv *lc1 = localeconv(); // expected-note@-1{{previous function call was here}} lconv *lc2 = localeconv(); - // expected-note@-1{{'localeconv' call may invalidate the the result of the previous 'localeconv'}} + // expected-note@-1{{'localeconv' call may invalidate the result of the previous 'localeconv'}} *lc1; // expected-warning@-1{{dereferencing an invalid pointer}} diff --git a/libcxx/include/__iterator/advance.h b/libcxx/include/__iterator/advance.h --- a/libcxx/include/__iterator/advance.h +++ b/libcxx/include/__iterator/advance.h @@ -141,7 +141,7 @@ // * If `n > 0`, [i, bound) denotes a range. // * If `n == 0`, [i, bound) or [bound, i) denotes a range. // * If `n < 0`, [bound, i) denotes a range, `I` models `bidirectional_iterator`, and `I` and `S` model `same_as`. - // Returns: `n - M`, where `M` is the difference between the the ending and starting position. + // Returns: `n - M`, where `M` is the difference between the ending and starting position. template _Sp> _LIBCPP_HIDE_FROM_ABI constexpr iter_difference_t<_Ip> operator()(_Ip& __i, iter_difference_t<_Ip> __n, _Sp __bound) const { diff --git a/libcxx/src/filesystem/operations.cpp b/libcxx/src/filesystem/operations.cpp --- a/libcxx/src/filesystem/operations.cpp +++ b/libcxx/src/filesystem/operations.cpp @@ -1884,7 +1884,7 @@ if (ElemCount == 0 && (PP.atEnd() || *PP == PATHSTR(""))) return PATHSTR("."); - // return a path constructed with 'n' dot-dot elements, followed by the the + // return a path constructed with 'n' dot-dot elements, followed by the // elements of '*this' after the mismatch. path Result; // FIXME: Reserve enough room in Result that it won't have to re-allocate. diff --git a/llvm/docs/AMDGPUUsage.rst b/llvm/docs/AMDGPUUsage.rst --- a/llvm/docs/AMDGPUUsage.rst +++ b/llvm/docs/AMDGPUUsage.rst @@ -3627,17 +3627,17 @@ is 1 or 2, then must be 1. "hidden_remainder_x" - The grid dispatch work group size of the the partial work group + The grid dispatch work group size of the partial work group of the X dimension, if it exists. Must be zero if a partial work group does not exist in the X dimension. "hidden_remainder_y" - The grid dispatch work group size of the the partial work group + The grid dispatch work group size of the partial work group of the Y dimension, if it exists. Must be zero if a partial work group does not exist in the Y dimension. "hidden_remainder_z" - The grid dispatch work group size of the the partial work group + The grid dispatch work group size of the partial work group of the Z dimension, if it exists. Must be zero if a partial work group does not exist in the Z dimension. diff --git a/llvm/docs/BugLifeCycle.rst b/llvm/docs/BugLifeCycle.rst --- a/llvm/docs/BugLifeCycle.rst +++ b/llvm/docs/BugLifeCycle.rst @@ -99,7 +99,7 @@ Please remember to assign the bug to yourself if you're actively working on fixing it and to unassign it when you're no longer actively working on it. You -unassign a bug by removing the person from the the ``Assignees`` field. +unassign a bug by removing the person from the ``Assignees`` field. .. _Closing: diff --git a/llvm/docs/CodingStandards.rst b/llvm/docs/CodingStandards.rst --- a/llvm/docs/CodingStandards.rst +++ b/llvm/docs/CodingStandards.rst @@ -1312,7 +1312,7 @@ ... use I ... Usage of ``std::for_each()``/``llvm::for_each()`` functions is discouraged, -unless the the callable object already exists. +unless the callable object already exists. Don't evaluate ``end()`` every time through a loop ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/llvm/docs/CommandGuide/llvm-profdata.rst b/llvm/docs/CommandGuide/llvm-profdata.rst --- a/llvm/docs/CommandGuide/llvm-profdata.rst +++ b/llvm/docs/CommandGuide/llvm-profdata.rst @@ -170,7 +170,7 @@ .. option:: --zero-counter-threshold= For the function which is cold in instr profile but hot in sample profile, if - the ratio of the number of zero counters divided by the the total number of + the ratio of the number of zero counters divided by the total number of counters is above the threshold, the profile of the function will be regarded as being harmful for performance and will be dropped. diff --git a/llvm/include/llvm/Analysis/Loads.h b/llvm/include/llvm/Analysis/Loads.h --- a/llvm/include/llvm/Analysis/Loads.h +++ b/llvm/include/llvm/Analysis/Loads.h @@ -75,9 +75,9 @@ /// within the specified loop) would access only dereferenceable memory, and /// be properly aligned on every iteration of the specified loop regardless of /// its placement within the loop. (i.e. does not require predication beyond -/// that required by the the header itself and could be hoisted into the header +/// that required by the header itself and could be hoisted into the header /// if desired.) This is more powerful than the variants above when the -/// address loaded from is analyzeable by SCEV. +/// address loaded from is analyzeable by SCEV. bool isDereferenceableAndAlignedInLoop(LoadInst *LI, Loop *L, ScalarEvolution &SE, DominatorTree &DT); diff --git a/llvm/include/llvm/ExecutionEngine/Orc/Core.h b/llvm/include/llvm/ExecutionEngine/Orc/Core.h --- a/llvm/include/llvm/ExecutionEngine/Orc/Core.h +++ b/llvm/include/llvm/ExecutionEngine/Orc/Core.h @@ -1331,7 +1331,7 @@ lookupInitSymbols(ExecutionSession &ES, const DenseMap &InitSyms); - /// Performs an async lookup for the the given symbols in each of the given + /// Performs an async lookup for the given symbols in each of the given /// JITDylibs, calling the given handler once all lookups have completed. static void lookupInitSymbolsAsync(unique_function OnComplete, diff --git a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.h b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.h --- a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.h +++ b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.h @@ -196,7 +196,7 @@ }; /// Meta qualifiers for a value. Pair of whatever expression is used to qualify -/// the the value, and Boolean of whether or not it's indirect. +/// the value, and Boolean of whether or not it's indirect. class DbgValueProperties { public: DbgValueProperties(const DIExpression *DIExpr, bool Indirect) diff --git a/llvm/tools/llvm-profdata/llvm-profdata.cpp b/llvm/tools/llvm-profdata/llvm-profdata.cpp --- a/llvm/tools/llvm-profdata/llvm-profdata.cpp +++ b/llvm/tools/llvm-profdata/llvm-profdata.cpp @@ -995,7 +995,7 @@ "zero-counter-threshold", cl::init(0.7), cl::Hidden, cl::desc("For the function which is cold in instr profile but hot in " "sample profile, if the ratio of the number of zero counters " - "divided by the the total number of counters is above the " + "divided by the total number of counters is above the " "threshold, the profile of the function will be regarded as " "being harmful for performance and will be dropped.")); cl::opt SupplMinSizeThreshold(