SuccessChanges

Summary

  1. [llvm][NFC] refactor setBlockFrequency for clarity. (details)
  2. [lld][linkerscript] Fix handling of DEFINED. (details)
  3. Reland [Coverage] Add comment to skipped regions (details)
  4. PR46377: Fix dependence calculation for function types and typedef (details)
  5. Revert D83834 "Add test utility 'extract'" (details)
  6. Revert "[gn build] (manually) merge d054c7ee2e9" (details)
  7. [X86] Remove disabled miscompiling X86CondBrFolding pass (details)
  8. AMDGPU: Check for other defs when folding conditions into s_andn2_b64 (details)
  9. [NFC] Sema: use checkArgCount instead of custom checking (details)
  10. AMDGPU/GlobalISel: Add SReg_96 to SGPRRegBank (details)
  11. AMDGPU/GlobalISel: Add some missing tests for extract selection (details)
  12. GlobalISel: Add typeIsNot LegalityPredicate (details)
  13. GlobalISel: Don't assert on operations with no type indices (details)
  14. [globalisel][cse] Merge debug locations when CSE'ing (details)
  15. [docs] [lit] Add a more helpful description for lit.py's -s flag. (details)
  16. [SROA][Mem2Reg] Use efficient droppable use API (after D83976) (details)
  17. [MLIR] Add unit test for tblgen Op build methods (details)
  18. [DominatorTree] Simplify ChildrenGetter. (details)
  19. PR46637: Fix handling of placeholder types in trailing-return-types. (details)
  20. On Windows build, making the /bigobj flag global , instead of passing it per file. (details)
  21. [OpenMP][NFC] Consolidate `to` and `from` clause modifiers (details)
  22. [OpenMP] Implement TR8 `present` motion modifier in Clang (1/2) (details)
  23. [OpenMP] Implement TR8 `present` motion modifier in runtime (2/2) (details)
  24. [FileCheck] Extend -dump-input with substitutions (details)
  25. [FileCheck] Report captured variables (details)
  26. [lldb] Remove unused option '--platform-path' for 'target create' (details)
  27. [libc] Add scaffolding for ctype and implementation of isalpha (details)
  28. [libc] [Obvious] Delete ctype.h, since ctype.h.def is used. (details)
  29. [scudo][standalone] Add new mallopt options. (details)
  30. [libc][NFC] Move tablegen indexer class into a util library of its own. (details)
  31. [flang][NFC] Extract name resolution for OpenACC & OpenMP into new file (details)
  32. [libc][obvious] Add the new ctype.h target to the list of x86_64 headers. (details)
  33. [clangd] Use elog instead of llvm::errs, log instead of llvm::outs (details)
  34. AMDGPU: Serialize MFI spill fields (details)
  35. AMDGPU: Fix verifier error on spilling partially defined SGPRs (details)
  36. [libc][obvious] Add license headers to APIIndexer.[cpp|h]. (details)
  37. [NFC][OpenMP] Renamed all variable and function names in `target` to conform with LLVM code standard (details)
  38. AMDGPU: Don't assume there is only one terminator copy (details)
  39. AMDGPU: Handle a few missing cases in getAddrModeArguments (details)
  40. Revert "[OpenMP] Implement TR8 `present` motion modifier in runtime (2/2)" (details)
  41. Revert "[OpenMP] Implement TR8 `present` motion modifier in Clang (1/2)" (details)
  42. [OpenMP] Replaced mutex lock/unlock in `target` with `std::lock_guard` (details)
  43. AMDGPU: Don't assume call targets are registers (details)
  44. [WebAssembly] Implement truncating vector stores (details)
  45. [openmp][openacc][NFC] Add wrapper for records in DirectiveEmitter (details)
  46. AMDGPU: Don't assert in canInsertSelect (details)
  47. [X86] Add FeatureCMPXCHG8B and FeatureSlowUAMem16 to 'lakemont' in X86.td (details)
  48. [WebAssembly] Remove intrinsics for SIMD widening ops (details)
  49. [NFC] Add getArgumentTypes() to Region (details)
  50. AMDGPU/GlobalISel: Fix selecting llvm.amdgcn.s.getreg (details)
  51. AMDGPU: Optimize copies to exec with other insts after exec def (details)
  52. [PowerPC] Add Def CR1 for MTFSFI_rec and MTFSF_rec (details)
  53. [ADT][BitVector][NFC] Merge find_first_in() / find_first_unset_in() (details)
  54. [analyzer] FuchsiaHandleChecker: Suppress a non-deterministic test failure. (details)
  55. [llvm-readelf][test] Improve wording in the comments. NFC. (details)
  56. [NFC] Edit the comment in User::replaceUsesOfWith (details)
  57. [NFC] Edit the comment for the return type of await_suspend (details)
  58. [Hexagon] Correct the order of operands when lowering funnel shift-left (details)
Commit 1e027b77f056fb50e50d9f743e21eb41151c32da by mtrofin
[llvm][NFC] refactor setBlockFrequency for clarity.

The refactoring encapsulates frequency calculation in MachineBlockFrequencyInfo,
and renames the API to clarify its motivation. It should clarify
frequencies may not be reset 'freely' by users of the analysis, as the
API serves as a partial update to avoid a full analysis recomputation.

Differential Revision: https://reviews.llvm.org/D84427
The file was modifiedllvm/lib/CodeGen/MachineBlockFrequencyInfo.cpp
The file was modifiedllvm/include/llvm/CodeGen/MachineBlockFrequencyInfo.h
The file was modifiedllvm/lib/CodeGen/MachineSink.cpp
Commit 1f166edeb47ea3584f4f6a267a9054af994af45c by abidh
[lld][linkerscript] Fix handling of DEFINED.

Current implementation did not check that symbols is actually defined. Only checked for presence.  GNU ld documentation says,

"Return 1 if symbol is in the linker global symbol table and is defined before the statement using DEFINED in the script, otherwise return 0."

https://sourceware.org/binutils/docs/ld/Builtin-Functions.html#Builtin-Functions

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D83758
The file was modifiedlld/test/ELF/linkerscript/define.test
The file was modifiedlld/test/ELF/linkerscript/Inputs/define.s
The file was modifiedlld/ELF/ScriptParser.cpp
Commit b46176bbb094610460667edad950a9c99f844118 by zequanwu
Reland [Coverage] Add comment to skipped regions

Bug filled here: https://bugs.llvm.org/show_bug.cgi?id=45757.
Add comment to skipped regions so we don't track execution count for lines containing only comments.

Differential Revision: https://reviews.llvm.org/D83592
The file was modifiedclang/test/CoverageMapping/preprocessor.c
The file was modifiedclang/test/CoverageMapping/switch.cpp
The file was modifiedclang/test/CoverageMapping/includehell.cpp
The file was modifiedclang/test/CoverageMapping/break.c
The file was modifiedclang/test/CoverageMapping/macroscopes.cpp
The file was modifiedclang/test/CoverageMapping/moremacros.c
The file was modifiedclang/test/CoverageMapping/logical.cpp
The file was modifiedclang/test/CoverageMapping/macros.c
The file was modifiedclang/test/CoverageMapping/while.c
The file was modifiedclang/test/CoverageMapping/deferred-region.cpp
The file was modifiedcompiler-rt/test/profile/Inputs/instrprof-comdat.h
The file was addedcompiler-rt/test/profile/coverage_comments.cpp
The file was modifiedclang/lib/CodeGen/CoverageMappingGen.cpp
The file was modifiedclang/test/CoverageMapping/classtemplate.cpp
The file was modifiedclang/test/CoverageMapping/return.c
The file was modifiedclang/test/CoverageMapping/comment-in-macro.c
The file was modifiedclang/test/CoverageMapping/coroutine.cpp
The file was modifiedclang/test/CoverageMapping/builtinmacro.c
The file was modifiedclang/test/CoverageMapping/objc.m
The file was modifiedclang/include/clang/Lex/Preprocessor.h
The file was modifiedclang/test/CoverageMapping/continue.c
The file was modifiedclang/test/CoverageMapping/label.cpp
The file was modifiedclang/test/CoverageMapping/trycatch.cpp
The file was modifiedcompiler-rt/test/profile/instrprof-set-file-object-merging.c
The file was modifiedclang/test/CoverageMapping/loops.cpp
The file was modifiedclang/test/CoverageMapping/unreachable-macro.c
The file was modifiedclang/lib/CodeGen/CoverageMappingGen.h
The file was modifiedclang/test/CoverageMapping/if.cpp
The file was modifiedclang/test/CoverageMapping/switchmacro.c
The file was modifiedclang/test/CoverageMapping/macroparams2.c
The file was modifiedclang/test/CoverageMapping/pr32679.cpp
The file was modifiedclang/lib/Lex/Preprocessor.cpp
The file was modifiedclang/test/CoverageMapping/macro-expressions.cpp
The file was modifiedclang/test/lit.cfg.py
The file was modifiedclang/lib/CodeGen/CodeGenAction.cpp
The file was modifiedclang/test/CoverageMapping/test.c
Commit 740a164dec483225cbd02ab6c82199e2747ffacb by richard
PR46377: Fix dependence calculation for function types and typedef
types.

We previously did not treat a function type as dependent if it had a
parameter pack with a non-dependent type -- such a function type depends
on the arity of the pack so is dependent even though none of the
parameter types is dependent. In order to properly handle this, we now
treat pack expansion types as always being dependent types (depending on
at least the pack arity), and always canonically being pack expansion
types, even in the unusual case when the pattern is not a dependent
type. This does mean that we can have canonical types that are pack
expansions that contain no unexpanded packs, which is unfortunate but
not inaccurate.

We also previously did not treat a typedef type as
instantiation-dependent if its canonical type was not
instantiation-dependent. That's wrong because instantiation-dependence
is a property of the type sugar, not of the type; an
instantiation-dependent type can have a non-instantiation-dependent
canonical type.
The file was modifiedclang/lib/Sema/SemaExpr.cpp
The file was modifiedclang/include/clang/AST/Type.h
The file was modifiedclang/lib/Sema/SemaType.cpp
The file was modifiedclang/lib/Sema/SemaTemplateVariadic.cpp
The file was modifiedclang/lib/Sema/SemaLambda.cpp
The file was modifiedclang/lib/AST/Type.cpp
The file was modifiedclang/include/clang/Basic/TypeNodes.td
The file was modifiedclang/lib/AST/ASTContext.cpp
The file was modifiedclang/lib/CodeGen/CodeGenFunction.cpp
The file was addedclang/test/SemaTemplate/alias-template-nondependent.cpp
The file was modifiedclang/include/clang/AST/ASTContext.h
The file was modifiedclang/lib/CodeGen/CGDebugInfo.cpp
Commit dd405f1a5397d3e7595458144ccb0bcec192a3bf by maskray
Revert D83834 "Add test utility 'extract'"

This reverts commit d054c7ee2e9f4f98af7f22a5b00a941eb919bd59.

There are discussions about the utility name, its functionality and user interface.
Revert before we reach consensus.
The file was modifiedllvm/test/lit.cfg.py
The file was removedllvm/tools/extract/extract.cpp
The file was modifiedllvm/test/tools/llvm-objcopy/ELF/strip-symbol.test
The file was modifiedlld/test/lit.cfg.py
The file was removedllvm/test/tools/extract/Inputs/basic-bb.txt
The file was modifiedllvm/docs/TestingGuide.rst
The file was modifiedlld/test/CMakeLists.txt
The file was removedllvm/test/tools/extract/no-leading-lines.test
The file was removedllvm/tools/extract/.clang-tidy
The file was removedllvm/tools/extract/CMakeLists.txt
The file was modifiedllvm/test/tools/gold/X86/multiple-sections.ll
The file was modifiedlld/test/ELF/linkerscript/noload.s
The file was removedllvm/test/tools/extract/basic.test
The file was removedllvm/test/tools/extract/Inputs/basic-aa.txt
The file was modifiedllvm/test/CMakeLists.txt
The file was modifiedllvm/test/tools/llvm-strings/radix.test
The file was removedllvm/test/tools/extract/help.test
Commit 26fc91eb5d26fb8bc3ab5328e698c9c1d9546b44 by maskray
Revert "[gn build] (manually) merge d054c7ee2e9"

This reverts commit ab73b6da95750164daac4cfbd351ca96e1084117.
The file was modifiedllvm/utils/gn/secondary/llvm/test/BUILD.gn
The file was modifiedllvm/utils/gn/secondary/lld/test/BUILD.gn
The file was removedllvm/utils/gn/secondary/llvm/tools/extract/BUILD.gn
Commit e1dd212c874c2ff01b72e9e60db6dbded9e2e6d1 by lebedev.ri
[X86] Remove disabled miscompiling X86CondBrFolding pass

As briefly discussed in IRC with @craig.topper,
the pass is disabled basically since it's original introduction (nov 2018)
due to  known correctness issues (miscompilations),
and there hasn't been much work done to fix that.

While i won't promise that i will "fix" the pass,
i have looked at it previously, and i'm sure i won't try to fix it
if that requires actually fixing this existing code.

Reviewed By: craig.topper

Differential Revision: https://reviews.llvm.org/D84775
The file was modifiedllvm/lib/Target/X86/X86.td
The file was removedllvm/test/CodeGen/X86/condbr_if.ll
The file was removedllvm/lib/Target/X86/X86CondBrFolding.cpp
The file was modifiedllvm/lib/Target/X86/X86TargetMachine.cpp
The file was removedllvm/test/CodeGen/X86/test_x86condbr_globaladdr.mir
The file was modifiedllvm/lib/Target/X86/X86Subtarget.h
The file was removedllvm/test/CodeGen/X86/condbr_switch.ll
The file was modifiedllvm/lib/Target/X86/X86.h
The file was modifiedllvm/utils/gn/secondary/llvm/lib/Target/X86/BUILD.gn
The file was modifiedllvm/lib/Target/X86/CMakeLists.txt
The file was modifiedllvm/lib/Target/X86/X86TargetTransformInfo.h
Commit e9b236f411c5683d270a381bf810ba3c8f3ed12c by Matthew.Arsenault
AMDGPU: Check for other defs when folding conditions into s_andn2_b64

We can't fold the masked compare value through the select if the
select condition is re-defed after the and instruction. Fixes a
verifier error and trying to use the outgoing value defined in the
block.

I'm not sure why this pass is bothering to handle physregs. It's
making this more complex and forces extra liveness computation.
The file was modifiedllvm/lib/Target/AMDGPU/SIOptimizeExecMaskingPreRA.cpp
The file was addedllvm/test/CodeGen/AMDGPU/optimize-exec-mask-pre-ra-loop-phi.mir
Commit 389f009c5757cf09c0b2d77a15b3b541fb0f2a1c by JF Bastien
[NFC] Sema: use checkArgCount instead of custom checking

As requested in D79279.

Differential Revision: https://reviews.llvm.org/D84666
The file was modifiedclang/test/CodeGen/builtins-ppc-error.c
The file was modifiedclang/test/SemaOpenCL/to_addr_builtin.cl
The file was modifiedclang/include/clang/Basic/DiagnosticSemaKinds.td
The file was modifiedclang/lib/Sema/SemaChecking.cpp
Commit 9731ef3ec578a20be3d81d0ef340faf61bf797d4 by Matthew.Arsenault
AMDGPU/GlobalISel: Add SReg_96 to SGPRRegBank
The file was modifiedllvm/lib/Target/AMDGPU/AMDGPURegisterBanks.td
Commit ee713a2d2854c56886ebfee165fe2d32905c4ef7 by Matthew.Arsenault
AMDGPU/GlobalISel: Add some missing tests for extract selection
The file was modifiedllvm/test/CodeGen/AMDGPU/GlobalISel/inst-select-extract.mir
Commit 5174e7b443d815df6707addbd4fe172418d6f4a2 by Matthew.Arsenault
GlobalISel: Add typeIsNot LegalityPredicate

This allows sorting the legal/custom rules first as is recommended
The file was modifiedllvm/include/llvm/CodeGen/GlobalISel/LegalizerInfo.h
The file was modifiedllvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
Commit e87356b4981bb0b504c106fd70fbde31e84447e6 by Matthew.Arsenault
GlobalISel: Don't assert on operations with no type indices

Fix not marking G_FENCE as legal on AMDGPU This was apparently
defaulting to legal using the "legacy" rules, whatever those are.
The file was modifiedllvm/lib/CodeGen/GlobalISel/LegalizerInfo.cpp
The file was modifiedllvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
Commit abf1ed70d60f4e8dffc53c9bb2cdb1e4be9fe888 by daniel_l_sanders
[globalisel][cse] Merge debug locations when CSE'ing

Reviewed By: aditya_nandakumar

Differential Revision: https://reviews.llvm.org/D78388
The file was modifiedllvm/lib/CodeGen/GlobalISel/CSEMIRBuilder.cpp
Commit 417d3d495f1cfb0a2f7b60d00829925126fdcfd9 by julian.lettner
[docs] [lit] Add a more helpful description for lit.py's -s flag.

Reviewed By: yln

Differential Revision: https://reviews.llvm.org/D82808
The file was modifiedllvm/utils/lit/lit/cl_arguments.py
The file was modifiedllvm/docs/CommandGuide/lit.rst
Commit 450dc09d69df343386865d279983de9d51d1e984 by johannes
[SROA][Mem2Reg] Use efficient droppable use API (after D83976)

Reviewed By: efriedma

Differential Revision: https://reviews.llvm.org/D84804
The file was modifiedllvm/lib/IR/Value.cpp
The file was modifiedllvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp
The file was modifiedllvm/include/llvm/IR/Value.h
The file was modifiedllvm/lib/Transforms/Scalar/SROA.cpp
Commit 0b161def6cacff1a63d3cf1a1efe95b550814d7a by jurahul
[MLIR] Add unit test for tblgen Op build methods

- Initiate the unit test with a test that tests variants of build() methods
  generated for ops with variadic operands and results.
- The intent is to migrate unit .td tests in mlir/test/mlir-tblgen that check for
  generated C++ code to these unit tests which test both that the generated code
  compiles and also is functionally correct.

Differential Revision: https://reviews.llvm.org/D84074
The file was modifiedmlir/test/lib/Dialect/Test/TestOps.td
The file was modifiedmlir/unittests/TableGen/CMakeLists.txt
The file was addedmlir/unittests/TableGen/OpBuildGen.cpp
Commit e22de4e46d1dd1aacc3a7060d24bcbe89908ba6c by asbirlea
[DominatorTree] Simplify ChildrenGetter.

Summary:
Simplify ChildrenGetter to a simple wrapper around a GraphDiff call.
GraphDiff already handles nullptr in children, so the special casing in
clang can also be removed.

Reviewers: kuhar, dblaikie

Subscribers: llvm-commits, cfe-commits

Tags: #clang, #llvm

Differential Revision: https://reviews.llvm.org/D84713
The file was modifiedclang/include/clang/Analysis/Analyses/Dominators.h
The file was modifiedllvm/include/llvm/Support/GenericDomTreeConstruction.h
Commit 9cf98d26e7b1204478cc13ae3df44a6843965c11 by richard
PR46637: Fix handling of placeholder types in trailing-return-types.

Only permit a placeholder type in a trailing-return-type if it would
also have been permitted in the decl-specifier sequence of a
corresponding declaration with no trailing-return-type. The standard
doesn't actually say this, but this is the only thing that makes sense.

Also fix handling of an 'auto' in a trailing-return-type in a parameter
of a generic lambda. We used to crash if we saw such a thing.
The file was modifiedclang/test/SemaCXX/cxx1y-generic-lambdas.cpp
The file was modifiedclang/lib/Sema/SemaType.cpp
The file was modifiedclang/include/clang/Sema/DeclSpec.h
The file was modifiedclang/include/clang/Sema/Sema.h
The file was modifiedclang/lib/Sema/SemaTemplateDeduction.cpp
The file was modifiedclang/test/SemaCXX/trailing-return-0x.cpp
The file was modifiedclang/test/SemaCXX/auto-type-from-cxx.cpp
The file was modifiedclang/test/SemaCXX/cxx1y-deduced-return-type.cpp
The file was modifiedclang/test/SemaTemplate/temp_arg_nontype_cxx1z.cpp
Commit 80bd6ae13ea23d453a1f45d6ccdbfc7d0c877bb0 by llvm-project
On Windows build, making the /bigobj flag global , instead of passing it per file.

To avoid having this flag be passed in per/file manner, we are instead
passing it globally.

This fixes this bug: https://bugs.llvm.org/show_bug.cgi?id=46733

Reviewed-by: aaron.ballman, beanz, meinersbur

Differential Revision: https://reviews.llvm.org/D84038
The file was modifiedllvm/cmake/modules/HandleLLVMOptions.cmake
The file was modifiedclang/unittests/AST/CMakeLists.txt
The file was modifiedclang/lib/Sema/CMakeLists.txt
The file was modifiedclang/unittests/Tooling/CMakeLists.txt
The file was modifiedlldb/source/API/CMakeLists.txt
The file was modifiedclang/lib/CodeGen/CMakeLists.txt
The file was modifiedclang/lib/ASTMatchers/Dynamic/CMakeLists.txt
The file was modifiedllvm/lib/Passes/CMakeLists.txt
The file was modifiedclang/unittests/ASTMatchers/CMakeLists.txt
The file was modifiedmlir/lib/Dialect/SPIRV/CMakeLists.txt
Commit a3d1f88fa7da3dfc0b4319f2e4eb7374fa60b819 by jdenny.ornl
[OpenMP][NFC] Consolidate `to` and `from` clause modifiers

`to` and `from` clauses take the same modifiers, which are called
"motion modifiers" in TR8, so implement handling of their modifiers
once not twice.  This will make it easier to implement additional
motion modifiers in the future.

Reviewed By: ABataev

Differential Revision: https://reviews.llvm.org/D84710
The file was modifiedclang/include/clang/Basic/OpenMPKinds.def
The file was modifiedclang/include/clang/Basic/OpenMPKinds.h
The file was modifiedclang/lib/Parse/ParseOpenMP.cpp
The file was modifiedclang/lib/Basic/OpenMPKinds.cpp
Commit 3c3faae497046be706df29e16c9fbccb7e1fce09 by jdenny.ornl
[OpenMP] Implement TR8 `present` motion modifier in Clang (1/2)

This patch implements Clang front end support for the OpenMP TR8
`present` motion modifier for `omp target update` directives.  The
next patch in this series implements OpenMP runtime support.

Reviewed By: ABataev

Differential Revision: https://reviews.llvm.org/D84711
The file was modifiedclang/lib/Sema/SemaOpenMP.cpp
The file was modifiedclang/lib/Serialization/ASTReader.cpp
The file was modifiedclang/test/OpenMP/target_update_messages.cpp
The file was modifiedclang/lib/Sema/TreeTransform.h
The file was modifiedclang/include/clang/Basic/OpenMPKinds.h
The file was modifiedclang/test/OpenMP/target_update_ast_print.cpp
The file was modifiedclang/lib/Serialization/ASTWriter.cpp
The file was modifiedclang/include/clang/Basic/DiagnosticSemaKinds.td
The file was modifiedclang/lib/AST/OpenMPClause.cpp
The file was modifiedclang/include/clang/Sema/Sema.h
The file was modifiedclang/include/clang/Parse/Parser.h
The file was modifiedclang/test/OpenMP/declare_mapper_ast_print.c
The file was modifiedclang/lib/Basic/OpenMPKinds.cpp
The file was modifiedclang/test/OpenMP/declare_mapper_codegen.cpp
The file was modifiedclang/include/clang/AST/OpenMPClause.h
The file was modifiedclang/lib/Parse/ParseOpenMP.cpp
The file was modifiedclang/include/clang/Basic/OpenMPKinds.def
The file was modifiedclang/test/OpenMP/target_update_codegen.cpp
The file was modifiedclang/lib/CodeGen/CGOpenMPRuntime.cpp
Commit 2cb926a447d22166dac0d6e6dceaf5b3616ef6a1 by jdenny.ornl
[OpenMP] Implement TR8 `present` motion modifier in runtime (2/2)

This patch implements OpenMP runtime support for the OpenMP TR8
`present` motion modifier for `omp target update` directives.  The
previous patch in this series implements Clang front end support.

Reviewed By: grokos

Differential Revision: https://reviews.llvm.org/D84712
The file was modifiedopenmp/libomptarget/src/omptarget.cpp
The file was addedopenmp/libomptarget/test/mapping/present/target_update.c
Commit d680711b94e94e9387076a0daf2a329e304e6751 by jdenny.ornl
[FileCheck] Extend -dump-input with substitutions

Substitutions are already reported in the diagnostics appearing before
the input dump in the case of failed directives, and they're reported
in traces (produced by `-vv -dump-input=never`) in the case of
successful directives.  However, those reports are not always
convenient to view while investigating the input dump, so this patch
adds the substitution report to the input dump too.  For example:

```
$ cat check
CHECK: hello [[WHAT:[a-z]+]]
CHECK: [[VERB]] [[WHAT]]

$ FileCheck -vv -DVERB=goodbye check < input |& tail -8
<<<<<<
           1: hello world
check:1       ^~~~~~~~~~~
           2: goodbye word
check:2'0     X~~~~~~~~~~~ error: no match found
check:2'1                  with "VERB" equal to "goodbye"
check:2'2                  with "WHAT" equal to "world"
>>>>>>
```

Without this patch, the location reported for a substitution for a
directive match is the directive's full match range.  This location is
misleading as it implies the substitution itself matches that range.
This patch changes the reported location to just the match range start
to suggest the substitution is known at the start of the match.  (As
in the above example, input dumps don't mark any range for
substitutions.  The location info in that case simply identifies the
right line for the annotation.)

Reviewed By: mehdi_amini, thopre

Differential Revision: https://reviews.llvm.org/D83650
The file was modifiedllvm/lib/Support/FileCheck.cpp
The file was modifiedllvm/test/FileCheck/verbose.txt
The file was modifiedllvm/lib/Support/FileCheckImpl.h
The file was modifiedllvm/include/llvm/Support/FileCheck.h
The file was modifiedllvm/test/FileCheck/dump-input-annotations.txt
The file was modifiedllvm/utils/FileCheck/FileCheck.cpp
Commit 9f86b8ec41f04fa6f087264008317515a612a922 by jdenny.ornl
[FileCheck] Report captured variables

Report captured variables in input dumps and traces.  For example:

```
$ cat check
CHECK: hello [[WHAT:[a-z]+]]
CHECK: goodbye [[WHAT]]

$ FileCheck -dump-input=always -vv check < input |& tail -8
<<<<<<
           1: hello world
check:1'0     ^~~~~~~~~~~
check:1'1           ^~~~~ captured var "WHAT"
           2: goodbye world
check:2'0     ^~~~~~~~~~~~~
check:2'1                   with "WHAT" equal to "world"
>>>>>>

$ FileCheck -dump-input=never -vv check < input
check2:1:8: remark: CHECK: expected string found in input
CHECK: hello [[WHAT:[a-z]+]]
       ^
<stdin>:1:1: note: found here
hello world
^~~~~~~~~~~
<stdin>:1:7: note: captured var "WHAT"
hello world
      ^~~~~
check2:2:8: remark: CHECK: expected string found in input
CHECK: goodbye [[WHAT]]
       ^
<stdin>:2:1: note: found here
goodbye world
^~~~~~~~~~~~~
<stdin>:2:1: note: with "WHAT" equal to "world"
goodbye world
^
```

Reviewed By: thopre

Differential Revision: https://reviews.llvm.org/D83651
The file was modifiedllvm/test/FileCheck/verbose.txt
The file was modifiedllvm/test/FileCheck/dump-input-annotations.txt
The file was modifiedllvm/unittests/Support/FileCheckTest.cpp
The file was modifiedllvm/lib/Support/FileCheckImpl.h
The file was modifiedllvm/lib/Support/FileCheck.cpp
Commit 2fa3da7dcdd021e05899770c02e08a20c19a98b3 by Jonas Devlieghere
[lldb] Remove unused option '--platform-path' for 'target create'

Differential revision: https://reviews.llvm.org/D84800
The file was modifiedlldb/source/Commands/CommandObjectTarget.cpp
Commit 686c82b9745b207227a83aa87000a6cbfe32fc20 by gyurgyikcp
[libc] Add scaffolding for ctype and implementation of isalpha

Reviewed By: sivachandra

Differential Revision: https://reviews.llvm.org/D84575
The file was modifiedlibc/src/CMakeLists.txt
The file was modifiedlibc/test/src/CMakeLists.txt
The file was addedlibc/include/ctype.h.def
The file was modifiedlibc/config/linux/api.td
The file was addedlibc/test/src/ctype/isalpha_test.cpp
The file was addedlibc/test/src/ctype/CMakeLists.txt
The file was modifiedlibc/config/linux/aarch64/entrypoints.txt
The file was addedlibc/src/ctype/isalpha.cpp
The file was addedlibc/src/ctype/isalpha.h
The file was addedlibc/src/ctype/CMakeLists.txt
The file was modifiedlibc/include/CMakeLists.txt
The file was modifiedlibc/spec/stdc.td
The file was modifiedlibc/config/linux/x86_64/entrypoints.txt
Commit 75f222b4762a660506325850bfbd3e4241a7e347 by gyurgyikcp
[libc] [Obvious] Delete ctype.h, since ctype.h.def is used.
The file was removedlibc/include/ctype.h
Commit f14472a2e327a393d4795a141b901be1dd397505 by kostyak
[scudo][standalone] Add new mallopt options.

This adds the code to support calling mallopt and converting the
options to the internal Option enum.

Reviewed By: cryptoad

Differential Revision: https://reviews.llvm.org/D84806
The file was modifiedcompiler-rt/lib/scudo/standalone/wrappers_c.inc
The file was modifiedcompiler-rt/lib/scudo/standalone/tests/wrappers_c_test.cpp
Commit 59f17a7d4f42fa330557e36d18f8b5f82a2c5e30 by sivachandra
[libc][NFC] Move tablegen indexer class into a util library of its own.

This class is currently used by two tools: HdrGen and PrototypeTestGen.
We will be adding more tools based on this class so it is convenient to
keep it in a util library of its own.
The file was modifiedlibc/utils/HdrGen/PublicAPICommand.h
The file was modifiedlibc/utils/HdrGen/PrototypeTestGen/CMakeLists.txt
The file was modifiedlibc/utils/HdrGen/CMakeLists.txt
The file was addedlibc/utils/LibcTableGenUtil/APIIndexer.cpp
The file was modifiedlibc/utils/HdrGen/PrototypeTestGen/PrototypeTestGen.cpp
The file was addedlibc/utils/LibcTableGenUtil/APIIndexer.h
The file was modifiedlibc/utils/HdrGen/PublicAPICommand.cpp
The file was modifiedlibc/utils/CMakeLists.txt
The file was addedlibc/utils/LibcTableGenUtil/CMakeLists.txt
Commit 9500d48de367d969dc944445297ae5bdfaa14079 by tkeith
[flang][NFC] Extract name resolution for OpenACC & OpenMP into new file

Move `ResolveAccParts` and `ResolveOmpParts` from resolve-names.cpp to
resolve-directives.{h,cpp}. Move the implementation in the classes
`DirectiveAttributeVisitor`, `AccAttributeVisitor`, and
`OmpAttributeVisitor` to resolve-directives.cpp as well.

To allow this to happen, move `EvaluateIntExpr` and introduce
`EvaluateInt64` to resolve-names-utils.h. The latter is also useful
elsewhere in resolve-names.cpp for converting an Expr to std::int64_t.

The other problem was that `ResolveDesignator` was called from the code
that was moved. At the moment it doesn't seem to be doing anything so I
removed the calls (and no tests failed). If it proves to be needed, we
can either resolve those designators in resolve-names.cpp or pass the
`ResolveDesignator` function in to the code that needs to call it.

Differential Revision: https://reviews.llvm.org/D84768
The file was modifiedflang/test/Semantics/acc-resolve01.f90
The file was modifiedflang/lib/Semantics/resolve-names-utils.h
The file was modifiedflang/lib/Semantics/CMakeLists.txt
The file was addedflang/lib/Semantics/resolve-directives.h
The file was modifiedflang/lib/Semantics/resolve-names.cpp
The file was addedflang/lib/Semantics/resolve-directives.cpp
Commit 462b3564f1bd103b43ccaa2ddd9211badcf0f68d by sivachandra
[libc][obvious] Add the new ctype.h target to the list of x86_64 headers.

This will fix the integration test which is failing currently.
The file was modifiedlibc/config/linux/x86_64/headers.txt
Commit fb22678cd67801e41af4917acceb4014ab5d007e by kbobyrev
[clangd] Use elog instead of llvm::errs, log instead of llvm::outs

Reviewed By: sammccall

Differential Revision: https://reviews.llvm.org/D84697
The file was modifiedclang-tools-extra/clangd/index/remote/server/Server.cpp
The file was modifiedclang-tools-extra/clangd/indexer/IndexerMain.cpp
The file was modifiedclang-tools-extra/clangd/tool/ClangdMain.cpp
Commit 66d60e06cbc51b453f9e38ad69795f9487213fe5 by Matthew.Arsenault
AMDGPU: Serialize MFI spill fields

These should probably be inferred from the function on parse, but the
target specific infrastructure currently does not give you a way to do
this. SILowerSGPRSpills early exits without this reporting spills,
which makes it difficult to write a MIR test for.
The file was modifiedllvm/test/CodeGen/MIR/AMDGPU/machine-function-info-no-ir.mir
The file was modifiedllvm/lib/Target/AMDGPU/SIMachineFunctionInfo.cpp
The file was modifiedllvm/test/CodeGen/MIR/AMDGPU/machine-function-info.ll
The file was modifiedllvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h
Commit 592f2e8d1ceb8ecec6f8b54eeb9fd7e0a099c0fe by Matthew.Arsenault
AMDGPU: Fix verifier error on spilling partially defined SGPRs

This needs an implicit def of the super-register in case one of the
lanes isn't defined, similar to copyPhysReg (or the not-VGPR spill
case below). This showed up in GlobalISel testing since it currently
doesn't fold out many undef instructions.
The file was modifiedllvm/lib/Target/AMDGPU/SIRegisterInfo.cpp
The file was addedllvm/test/CodeGen/AMDGPU/sgpr-spill-partially-undef.mir
Commit cd7a5c3cd9a4891654b1b36f743a250135eb5c5a by sivachandra
[libc][obvious] Add license headers to APIIndexer.[cpp|h].
The file was modifiedlibc/utils/LibcTableGenUtil/APIIndexer.h
The file was modifiedlibc/utils/LibcTableGenUtil/APIIndexer.cpp
Commit 3ce69d4d50a24394eff15f92e3f4a609acc963e7 by tianshilei1992
[NFC][OpenMP] Renamed all variable and function names in `target` to conform with LLVM code standard

This patch only touched variables and functions in `target`.

Reviewed By: ye-luo

Differential Revision: https://reviews.llvm.org/D84797
The file was modifiedopenmp/libomptarget/src/device.h
The file was modifiedopenmp/libomptarget/src/interface.cpp
The file was modifiedopenmp/libomptarget/src/private.h
The file was modifiedopenmp/libomptarget/src/device.cpp
The file was modifiedopenmp/libomptarget/src/omptarget.cpp
The file was modifiedopenmp/libomptarget/src/api.cpp
Commit b3e63aa8a47078e8ac24ceffa7160cc1af657dcb by Matthew.Arsenault
AMDGPU: Don't assume there is only one terminator copy

This would stop on the first in reverse order, failing the verifier if
there were more earlier in the block.
The file was addedllvm/test/CodeGen/AMDGPU/optimize-exec-masking-strip-terminator-bits.mir
The file was modifiedllvm/lib/Target/AMDGPU/SIOptimizeExecMasking.cpp
Commit 8860daf0ed248960c3bc26208b7a38b3e1aadb1d by Matthew.Arsenault
AMDGPU: Handle a few missing cases in getAddrModeArguments
The file was modifiedllvm/lib/Target/AMDGPU/SIISelLowering.cpp
The file was modifiedllvm/test/CodeGen/AMDGPU/cgp-addressing-modes.ll
The file was addedllvm/test/CodeGen/AMDGPU/cgp-addressing-modes-gfx1030.ll
The file was addedllvm/test/CodeGen/AMDGPU/cgp-addressing-modes-gfx908.ll
Commit 65564e5eaf143cb3c43907cc546d76e2b20e59f3 by jdenny.ornl
Revert "[OpenMP] Implement TR8 `present` motion modifier in runtime (2/2)"

This reverts commit 2cb926a447d22166dac0d6e6dceaf5b3616ef6a1.

It depends on 3c3faae497046be706df29e16c9fbccb7e1fce09, which is being
reverted.
The file was modifiedopenmp/libomptarget/src/omptarget.cpp
The file was removedopenmp/libomptarget/test/mapping/present/target_update.c
Commit 69fc33f0cd130b02a38d2fc582afc7b0fcd6458a by jdenny.ornl
Revert "[OpenMP] Implement TR8 `present` motion modifier in Clang (1/2)"

This reverts commit 3c3faae497046be706df29e16c9fbccb7e1fce09.

It breaks a number of bots.
The file was modifiedclang/test/OpenMP/declare_mapper_ast_print.c
The file was modifiedclang/include/clang/Sema/Sema.h
The file was modifiedclang/include/clang/Basic/OpenMPKinds.h
The file was modifiedclang/lib/Serialization/ASTReader.cpp
The file was modifiedclang/test/OpenMP/target_update_codegen.cpp
The file was modifiedclang/lib/Basic/OpenMPKinds.cpp
The file was modifiedclang/include/clang/AST/OpenMPClause.h
The file was modifiedclang/include/clang/Parse/Parser.h
The file was modifiedclang/lib/AST/OpenMPClause.cpp
The file was modifiedclang/test/OpenMP/target_update_ast_print.cpp
The file was modifiedclang/lib/Sema/TreeTransform.h
The file was modifiedclang/lib/Serialization/ASTWriter.cpp
The file was modifiedclang/lib/CodeGen/CGOpenMPRuntime.cpp
The file was modifiedclang/test/OpenMP/declare_mapper_codegen.cpp
The file was modifiedclang/lib/Sema/SemaOpenMP.cpp
The file was modifiedclang/include/clang/Basic/OpenMPKinds.def
The file was modifiedclang/include/clang/Basic/DiagnosticSemaKinds.td
The file was modifiedclang/lib/Parse/ParseOpenMP.cpp
The file was modifiedclang/test/OpenMP/target_update_messages.cpp
Commit 30440924d48cdcbdef1dd7b2791171d821a859ae by tianshilei1992
[OpenMP] Replaced mutex lock/unlock in `target` with `std::lock_guard`

Reviewed By: ye-luo

Differential Revision: https://reviews.llvm.org/D84799
The file was modifiedopenmp/libomptarget/src/omptarget.cpp
Commit 068808d102846d551e683241d0b3b9607b3bdf8d by Matthew.Arsenault
AMDGPU: Don't assume call targets are registers

GlobalISel let through a call to null, which would then fold into the
source operand like any other inline immediate. The SelectionDAG
lowering deletes calls to null and undef as a workaround from before
calls were supported. We should probably drop the special handling
case in the DAG lowering now, since the middle end optimizers delete
null calls anyway.
The file was modifiedllvm/test/CodeGen/AMDGPU/call-constant.ll
The file was modifiedllvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp
Commit ffd8c23ccb74bbd19ba16e3706a0c5e1e472cca6 by tlively
[WebAssembly] Implement truncating vector stores

Rather than expanding truncating stores so that vectors are stored one
lane at a time, lower them to a sequence of instructions using
narrowing operations instead, when possible. Since the narrowing
operations have saturating semantics, but truncating stores require
truncation, mask the stored value to manually truncate it before
narrowing. Also, since narrowing is a binary operation, pass in the
original vector as the unused second argument.

Differential Revision: https://reviews.llvm.org/D84377
The file was modifiedllvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td
The file was modifiedllvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
The file was modifiedllvm/test/CodeGen/WebAssembly/simd-offset.ll
Commit e8d4038efb181f886e997ba28da1572e41aa16bd by clementval
[openmp][openacc][NFC] Add wrapper for records in DirectiveEmitter

Add wrapper classes to to access record's fields. This makes it easier to
pass record information to the diverse functions for code generation.

Reviewed By: jdenny

Differential Revision: https://reviews.llvm.org/D84612
The file was modifiedllvm/utils/TableGen/DirectiveEmitter.cpp
Commit 6a7b6dd54b207945ba4b3750496036c6280ab522 by Matthew.Arsenault
AMDGPU: Don't assert in canInsertSelect

Currently GlobalISel doesn't force all VGPR phi operands to VGPRs, so
this hit a case where it was queried with a VGPR and SGPR. This could
arguably be a verifier error, but it's currently not.
The file was modifiedllvm/lib/Target/AMDGPU/SIInstrInfo.cpp
Commit 06cf6f770d649ed241314881054b7b8d9eee765d by craig.topper
[X86] Add FeatureCMPXCHG8B and FeatureSlowUAMem16 to 'lakemont' in X86.td

We already had CMPXCH8B feature on this CPU for the frontend so
this doesn't have much effect.

The FeatureSlowUAMem16 only matters if someone compiles with
-march=lakemont -msse which doesn't make sense, but is consistent
with all our pre-sse4.2 CPUs. Maybe the feature flag should be
FeatureFastUAMem16 and set on the newer CPUs instead.
The file was modifiedllvm/lib/Target/X86/X86.td
The file was modifiedllvm/test/CodeGen/X86/cmpxchg8b.ll
Commit 11bb7eef4152cab895983f19e638f0cfdf8a580f by tlively
[WebAssembly] Remove intrinsics for SIMD widening ops

Instead, pattern match extends of extract_subvectors to generate
widening operations. Since extract_subvector is not a legal node, this
is implemented via a custom combine that recognizes extract_subvector
nodes before they are legalized. The combine produces custom ISD nodes
that are later pattern matched directly, just like the intrinsic was.

Also removes the clang builtins for these operations since the
instructions can now be generated from portable code sequences.

Differential Revision: https://reviews.llvm.org/D84556
The file was modifiedllvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
The file was modifiedllvm/lib/Target/WebAssembly/WebAssemblyISD.def
The file was modifiedllvm/test/CodeGen/WebAssembly/simd-intrinsics.ll
The file was modifiedclang/include/clang/Basic/BuiltinsWebAssembly.def
The file was modifiedllvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td
The file was modifiedclang/lib/CodeGen/CGBuiltin.cpp
The file was addedllvm/test/CodeGen/WebAssembly/simd-widening.ll
The file was modifiedclang/lib/Headers/wasm_simd128.h
The file was modifiedclang/test/CodeGen/builtins-wasm.c
The file was modifiedllvm/include/llvm/IR/IntrinsicsWebAssembly.td
Commit 706d992cedaf2ca3190e4445015da62faf2db544 by jurahul
[NFC] Add getArgumentTypes() to Region

- Add getArgumentTypes() to Region (missed from before)
- Adopt Region argument API in `hasMultiplyAddBody`
- Fix 2 typos in comments

Differential Revision: https://reviews.llvm.org/D84807
The file was modifiedmlir/lib/IR/Region.cpp
The file was modifiedmlir/include/mlir/IR/Visitors.h
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/Vectorization.cpp
The file was modifiedmlir/include/mlir/IR/Region.h
The file was modifiedmlir/lib/Transforms/Utils/InliningUtils.cpp
Commit b6ebc77326843deeb34006bf278329bcf5e530b9 by Matthew.Arsenault
AMDGPU/GlobalISel: Fix selecting llvm.amdgcn.s.getreg

This introduces the same bug llvm.amdgcn.s.setreg has where if the
user specified an immediate outside of the valid 16-bit range, it will
select into a verifier error.
The file was modifiedllvm/test/CodeGen/AMDGPU/llvm.amdgcn.s.getreg.ll
The file was modifiedllvm/lib/Target/AMDGPU/SOPInstructions.td
The file was modifiedllvm/lib/Target/AMDGPU/SIInstrInfo.td
Commit 44211f20a82418b20a69df9de6291d923dcbf709 by Matthew.Arsenault
AMDGPU: Optimize copies to exec with other insts after exec def

It's possible to have terminator instructions after a write to exec,
so skip over them to find it.
The file was addedllvm/test/CodeGen/AMDGPU/optimize-exec-copies-extra-insts-after-copy.mir
The file was modifiedllvm/lib/Target/AMDGPU/SIOptimizeExecMasking.cpp
Commit 00046d789c9db444efa952e4b6e8df86990bfdda by shkzhang
[PowerPC] Add Def CR1 for MTFSFI_rec and MTFSF_rec
The file was modifiedllvm/lib/Target/PowerPC/PPCInstrInfo.td
Commit db0d636e52c163196bc8abeb62b649b7de700569 by sdi1600105
[ADT][BitVector][NFC] Merge find_first_in() / find_first_unset_in()

We can implement find_first_unset_in() in the same function
if every BitWord we use is first flipped.

Differential Revision: https://reviews.llvm.org/D84717
The file was modifiedllvm/include/llvm/ADT/BitVector.h
Commit c26f237cef1b33277f072c609c19192c5213f348 by Artem Dergachev
[analyzer] FuchsiaHandleChecker: Suppress a non-deterministic test failure.

Noticed by Jon Roelofs in https://reviews.llvm.org/D73151#2180499
The file was modifiedclang/test/Analysis/fuchsia_handle.cpp
Commit c12394fef3edc74207801adc6f778a0fb422f195 by Xing
[llvm-readelf][test] Improve wording in the comments. NFC.

This patch addresses comments in D84640 (https://reviews.llvm.org/D84640#2178475).
The file was modifiedllvm/test/tools/llvm-readobj/ELF/hex-dump.test
Commit dd4106d22ef6ce51bfac666584b76dd43e98acf6 by yedeng.yd
[NFC] Edit the comment in User::replaceUsesOfWith
The file was modifiedllvm/unittests/IR/UserTest.cpp
The file was modifiedllvm/lib/IR/User.cpp
Commit d3527052fc2a952d752f82ffbe39220bad33fc8d by yedeng.yd
[NFC] Edit the comment for the return type of await_suspend
The file was modifiedclang/lib/Sema/SemaCoroutine.cpp
Commit d50d4c3d440c1d5a5a2003b782f8fbb7cc7b1441 by iajbar
[Hexagon] Correct the order of operands when lowering funnel shift-left

This patch corrects the order of operands in the pattern that lowers fshl
in Hexagon.
The file was modifiedllvm/lib/Target/Hexagon/HexagonPatterns.td
The file was addedllvm/test/CodeGen/Hexagon/funnel-shift2.ll
The file was modifiedllvm/test/CodeGen/Hexagon/funnel-shift.ll