LLVM/project 81e51e0openmp/tools/omptest/src OmptAssertEvent.cpp

[openmp][omptest] Include cstdlib for malloc() (#202021)

This is to address the error appearing when building this code with
somewhat more recent compilers:

```
Use of undeclared identifier 'malloc'
```

Such inclusion has already been added to the OmptTester.cpp file.
DeltaFile
+2-0openmp/tools/omptest/src/OmptAssertEvent.cpp
+2-01 files

LLVM/project 3fed38fllvm/lib/Target/AMDGPU AMDGPUCallLowering.cpp, llvm/test/CodeGen/AMDGPU isel-amdgcn-cs-chain-intrinsic-w64.ll isel-amdgcn-cs-chain-intrinsic-w32.ll

AMDGPU/GlobalISel: Fix tail call target in vgprs (#201873)

Insert readfirstlane, similar to SDAG version from #110984.
DeltaFile
+86-62llvm/test/CodeGen/AMDGPU/isel-amdgcn-cs-chain-intrinsic-w64.ll
+84-60llvm/test/CodeGen/AMDGPU/isel-amdgcn-cs-chain-intrinsic-w32.ll
+59-51llvm/test/CodeGen/AMDGPU/isel-amdgpu-cs-chain-intrinsic-dyn-vgpr-w32.ll
+7-1llvm/lib/Target/AMDGPU/AMDGPUCallLowering.cpp
+236-1744 files

LLVM/project d81a62amlir/include/mlir/Interfaces ControlFlowInterfaces.td

[mlir][Interfaces] Document completeness requirement of `RegionBranchOpInterface`
DeltaFile
+12-4mlir/include/mlir/Interfaces/ControlFlowInterfaces.td
+12-41 files

LLVM/project 570e532llvm/tools/llubi/lib Value.h

[llubi] explain Byte.TagValue encoding trick (#201863)

This took me a while to understand in #185977 so let's make it more
explicit why `TagValue` can be so small.
DeltaFile
+11-1llvm/tools/llubi/lib/Value.h
+11-11 files

LLVM/project 12e5a0fllvm/lib/Target/X86 X86ISelLowering.cpp X86ISelLowering.h, llvm/test/Transforms/AtomicExpand/X86 expand-atomic-non-integer.ll

[X86] Remove shouldCastAtomicLoadInIR; use DAG combine instead

Remove X86's shouldCastAtomicLoadInIR override that cast FP atomic
loads to integer at the IR level. Instead, handle this in a pre-legalize
DAG combine (combineAtomicLoad) that rewrites FP/FP-vector atomic loads
to integer atomic loads plus a bitcast.

This depends on #199310 which adds the necessary cmpxchg support for
non-integer atomic loads in AtomicExpand.
DeltaFile
+25-7llvm/lib/Target/X86/X86ISelLowering.cpp
+2-4llvm/test/Transforms/AtomicExpand/X86/expand-atomic-non-integer.ll
+0-2llvm/lib/Target/X86/X86ISelLowering.h
+27-133 files

LLVM/project 86fc55ellvm/lib/Transforms/Scalar LoopFuse.cpp

[LoopFusion] Remove unused DataLayout parameter (NFC) (#202009)

The LoopFuser constructor took a DataLayout reference that was never
stored or used, and run() computed it solely to pass it in. Drop both.
DeltaFile
+3-4llvm/lib/Transforms/Scalar/LoopFuse.cpp
+3-41 files

LLVM/project f8ee61bllvm/lib/Target/X86/GISel X86LegalizerInfo.cpp, llvm/test/CodeGen/X86/GlobalISel legalize-freeze.mir legalize-ctpop.mir

[X86][GlobalISel] Remove dependency on legal ruleset (#197374)

This fills in always legal rules, to remove the dependency on the legacy
ruleset. I'm not sure about the truncate rule but all tests pass. This
is not guaranteed to be all the rules, just the ones that appear in
tests.
DeltaFile
+7-5llvm/test/CodeGen/X86/GlobalISel/legalize-freeze.mir
+5-5llvm/test/CodeGen/X86/GlobalISel/legalize-ctpop.mir
+8-0llvm/lib/Target/X86/GISel/X86LegalizerInfo.cpp
+20-103 files

LLVM/project cff8815clang/include/clang/AST FormatString.h, clang/lib/AST FormatString.cpp PrintfFormatString.cpp

[Clang] support C23 printf width length modifiers (#199991)

This patch adds `-Wformat` support for the C23 `wN` and `wfN` length
modifiers in `printf`/`scanf` format strings. #116962
DeltaFile
+115-3clang/lib/AST/FormatString.cpp
+103-0clang/test/Sema/format-strings-c23.c
+29-4clang/include/clang/AST/FormatString.h
+7-7clang/lib/Sema/SemaChecking.cpp
+12-0clang/lib/AST/PrintfFormatString.cpp
+9-0clang/lib/AST/ScanfFormatString.cpp
+275-144 files not shown
+290-1410 files

LLVM/project 43df645llvm/lib/CodeGen/SelectionDAG SelectionDAGISel.cpp, llvm/lib/Target TargetMachine.cpp

[Target] Remove `Target::resetTargetOptions` (#201825)

This function shouldn't exist, now it is an empty function, remove it.
DeltaFile
+0-15llvm/lib/Target/TargetMachine.cpp
+0-12llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
+1-6llvm/lib/Target/Xtensa/XtensaTargetMachine.cpp
+1-6llvm/lib/Target/Sparc/SparcTargetMachine.cpp
+1-6llvm/lib/Target/M68k/M68kTargetMachine.cpp
+1-6llvm/lib/Target/Hexagon/HexagonTargetMachine.cpp
+4-5114 files not shown
+6-10920 files

LLVM/project 18b3f1fclang/include/clang/Basic DarwinSDKInfo.h, clang/lib/Basic DarwinSDKInfo.cpp

Revert "[clang][driver][darwin] Hold onto full triples in Darwin SDKPlatformInfo (#200896)" (#202010)

This doesn't work for 32 bit arm because that usually gets converted to
thumb-apple-os, and that doesn't match arm-apple-os from
SDKSettings.json.

This reverts commit b89bb06afd069aa1b5e9f05ab692b3e6b41318c0.
DeltaFile
+25-109clang/lib/Basic/DarwinSDKInfo.cpp
+33-35clang/include/clang/Basic/DarwinSDKInfo.h
+12-6clang/lib/Driver/ToolChains/Darwin.cpp
+2-2clang/unittests/Basic/DarwinSDKInfoTest.cpp
+1-1clang/lib/Driver/ToolChains/Darwin.h
+73-1535 files

LLVM/project ee1ba2dclang/lib/Headers __clang_hip_libdevice_declares.h, clang/test/Headers openmp-device-functions-bool.c __clang_hip_libdevice_declares.cpp

Revert "clang/HIP: Remove __ockl_fdot2 declaration (#201878)"

This reverts commit b16873b218bd3f387adb33d796e0775a57a2490e.
DeltaFile
+67-20clang/test/Headers/openmp-device-functions-bool.c
+49-0clang/test/Headers/__clang_hip_libdevice_declares.cpp
+9-0clang/lib/Headers/__clang_hip_libdevice_declares.h
+125-203 files

LLVM/project f126756offload/test/offloading multiple_reductions.cpp

[OpenMP][offload] use per-type checks for multiple_reductions.cpp (#201045)
DeltaFile
+24-6offload/test/offloading/multiple_reductions.cpp
+24-61 files

LLVM/project 26ffc71clang/lib/Format TokenAnnotator.cpp, clang/unittests/Format FormatTest.cpp

[clang-format] Disallow breaking before/after ## (#200721)

Fixes #199775
DeltaFile
+17-6clang/unittests/Format/FormatTest.cpp
+2-0clang/lib/Format/TokenAnnotator.cpp
+19-62 files

LLVM/project 11d7939clang/lib/Format UnwrappedLineParser.cpp TokenAnnotator.cpp, clang/unittests/Format FormatTest.cpp

[clang-format] Keep C++20 module/import decls on a single line (#199459)

This patch fixes #193676.

- Added `UnwrappedLineParser::parseModuleDecl()` to parse C++20 module
declarations.
- Adapted `parseCppModuleImport()` from #193834 and renamed it to
`parseImportDecl()`.
- Used the test cases from the same PR.
- Removed the invalid test cases and fixed an incorrect one in
`FormatTest.cpp`.

---------

Co-authored-by: Björn Schäpers <github at hazardy.de>
DeltaFile
+78-50clang/lib/Format/UnwrappedLineParser.cpp
+24-13clang/unittests/Format/FormatTest.cpp
+3-6clang/lib/Format/TokenAnnotator.cpp
+4-1clang/lib/Format/UnwrappedLineParser.h
+2-0clang/lib/Format/TokenAnnotator.h
+111-705 files

LLVM/project 6afe164libcxx/test/libcxx/transitive_includes cxx03.csv cxx11.csv

regenerate transitive include
DeltaFile
+5-0libcxx/test/libcxx/transitive_includes/cxx03.csv
+5-0libcxx/test/libcxx/transitive_includes/cxx11.csv
+5-0libcxx/test/libcxx/transitive_includes/cxx14.csv
+5-0libcxx/test/libcxx/transitive_includes/cxx17.csv
+20-04 files

LLVM/project 9781918clang/lib/CIR/CodeGen CIRGenBuilder.h CIRGenAtomic.cpp, clang/test/CIR/CodeGen atomic.c

[CIR] Initialization of atomic aggregates with padding (#200668)

This patch adds support for the initialization of atomic aggregates with
padding. The changes include:

- During CIRGen, the type `_Atomic(T)` is represented by a CIR struct
`{T, sint8[padding_size]}` if the size of `_Atomic(T)` does not match
the size of `T`. `padding_size` is the difference between the size of
`_Atomic(T)` and `T`.
- CIRGen for the initialization process is updated to handle the
initialization of such CIR struct values.
DeltaFile
+47-0clang/test/CIR/CodeGen/atomic.c
+23-0clang/lib/CIR/CodeGen/CIRGenBuilder.h
+11-6clang/lib/CIR/CodeGen/CIRGenAtomic.cpp
+7-1clang/lib/CIR/CodeGen/CIRGenTypes.cpp
+88-74 files

LLVM/project 54ed469clang/include/clang/Basic AtomicLineLogger.h, clang/lib/Basic AtomicLineLogger.cpp CMakeLists.txt

Revert "[clang] Adding an Atomic Line Logger" (#201984)

Reverts llvm/llvm-project#195885

This is causing a build failure on a Windows bot running VS2019:
https://lab.llvm.org/buildbot/#/builders/46/builds/36187
DeltaFile
+0-213clang/unittests/Basic/AtomicLineLoggerTest.cpp
+0-77clang/lib/Basic/AtomicLineLogger.cpp
+0-67clang/include/clang/Basic/AtomicLineLogger.h
+0-1clang/unittests/Basic/CMakeLists.txt
+0-1clang/lib/Basic/CMakeLists.txt
+0-3595 files

LLVM/project d08a2a4clang/lib/StaticAnalyzer/Checkers/WebKit RawPtrRefCallArgsChecker.cpp RawPtrRefLocalVarsChecker.cpp, clang/test/Analysis/Checkers/WebKit unretained-call-args.mm retain-ptr-ctor-adopt-use.mm

[WebKit checkers] Treat the return value of an instance method as an unsafe pointer origin (#160569)
DeltaFile
+23-0clang/test/Analysis/Checkers/WebKit/unretained-call-args.mm
+11-0clang/test/Analysis/Checkers/WebKit/retain-ptr-ctor-adopt-use.mm
+8-0clang/test/Analysis/Checkers/WebKit/retain-ptr-ctor-adopt-use-arc.mm
+3-5clang/lib/StaticAnalyzer/Checkers/WebKit/RawPtrRefCallArgsChecker.cpp
+4-0clang/test/Analysis/Checkers/WebKit/objc-mock-types.h
+0-4clang/lib/StaticAnalyzer/Checkers/WebKit/RawPtrRefLocalVarsChecker.cpp
+49-92 files not shown
+54-98 files

LLVM/project 3e2ccf5libcxx/include __config, libcxx/include/__atomic atomic_flag.h

[libc++] Assume that <atomic> is available (#199674)

We always define either `_LIBCPP_HAS_C_ATOMIC_IMP` or
`_LIBCPP_HAS_GCC_ATOMIC_IMP`, so we can remove any special handling of
not having an `<atomic>` header.
DeltaFile
+1-34libcxx/src/memory_resource.cpp
+14-16libcxx/include/__atomic/atomic_flag.h
+0-19libcxx/include/__config
+1-11libcxx/utils/generate_libcxx_cppm_in.py
+1-10libcxx/utils/libcxx/test/modules.py
+0-6libcxx/utils/libcxx/header_information.py
+17-964 files not shown
+21-10810 files

LLVM/project d0e32e4clang/include/clang/Basic AtomicLineLogger.h, clang/lib/Basic AtomicLineLogger.cpp CMakeLists.txt

Revert "[clang] Adding an Atomic Line Logger (#195885)"

This reverts commit d0397a6d7d78888e278823c4d32749f8c896ef9c.
DeltaFile
+0-213clang/unittests/Basic/AtomicLineLoggerTest.cpp
+0-77clang/lib/Basic/AtomicLineLogger.cpp
+0-67clang/include/clang/Basic/AtomicLineLogger.h
+0-1clang/lib/Basic/CMakeLists.txt
+0-1clang/unittests/Basic/CMakeLists.txt
+0-3595 files

LLVM/project 7389aa2llvm/lib/Frontend/Offloading ArchiveLinker.cpp

[Frontend][Offloading] Fix GCC 7 build error in ArchiveLinker (#201978)

GCC 7 cannot perform implicit move construction when converting
`ResolvedInputs` to `Expected<ResolvedInputs>`.
DeltaFile
+1-1llvm/lib/Frontend/Offloading/ArchiveLinker.cpp
+1-11 files

LLVM/project ea6943cllvm/lib/Target/X86 X86SpeculativeLoadHardening.cpp

[X86] Remove stray :w from a comment. NFC (#201982)
DeltaFile
+0-1llvm/lib/Target/X86/X86SpeculativeLoadHardening.cpp
+0-11 files

LLVM/project 4113577llvm/utils/TableGen/Common CodeGenRegisters.cpp

[TableGen] Recompute only the affected UberSet when inheriting reg units (#200962)

CodeGenRegBank::computeRegUnitWeights() runs a fixpoint over all registers;
normalizeWeight() calls the global computeUberWeights() -- which rescans
every UberRegSet, every register, and all of their register units -- each time
a register inherits register units from its subregisters.

Most of the time, we do better by just recomputing one register's
UberSet.

On AMDGPU (21266 registers) with this change, the "Compute reg unit
weights" phase drops from 3.19s to 0.70s (4.5x speedup) and
-gen-register-info improves overall from ~16.4s to ~14.0s.
DeltaFile
+41-36llvm/utils/TableGen/Common/CodeGenRegisters.cpp
+41-361 files

LLVM/project f53c19eclang/docs ReleaseNotes.rst, clang/include/clang/Options Options.td

Revert "[clang-cl] Add new option `/pathmap:<from>=<to>` to replace the path prefix <from> with <to>." (#201981)

Reverts llvm/llvm-project#198664

Causes test failures on
[llvm-clang-aarch64-darwin](https://lab.llvm.org/buildbot/#/builders/190)
bot.
DeltaFile
+0-18clang/test/CodeGenCXX/cl-pathmap.cpp
+0-11clang/docs/ReleaseNotes.rst
+0-9clang/test/Preprocessor/cl-pathmap.c
+0-4clang/test/Driver/cl-pathmap.c
+0-2clang/include/clang/Options/Options.td
+0-445 files

LLVM/project 01ab573clang/unittests/ScalableStaticAnalysisFramework TUSummaryBuilderTest.cpp

Add tests for function return and fields to ensure their linkages are not affected.
DeltaFile
+21-0clang/unittests/ScalableStaticAnalysisFramework/TUSummaryBuilderTest.cpp
+21-01 files

LLVM/project 0cbd451clang/docs ReleaseNotes.rst, clang/include/clang/Options Options.td

Revert "[clang-cl] Add new option `/pathmap:<from>=<to>` to replace the path …"

This reverts commit 832f4c41ae172950bbb5797803d6ec1a94edd146.
DeltaFile
+0-18clang/test/CodeGenCXX/cl-pathmap.cpp
+0-11clang/docs/ReleaseNotes.rst
+0-9clang/test/Preprocessor/cl-pathmap.c
+0-4clang/test/Driver/cl-pathmap.c
+0-2clang/include/clang/Options/Options.td
+0-445 files

LLVM/project ee5e682clang/include/clang/CIR InitAllDialects.h, clang/lib/CIR RegisterAllDialects.cpp CMakeLists.txt

[CIR] Centralize dialect registration across CIR tools (#200266)
DeltaFile
+37-0clang/include/clang/CIR/InitAllDialects.h
+37-0clang/lib/CIR/RegisterAllDialects.cpp
+24-0clang/test/CIR/IR/openacc.cir
+5-12clang/lib/CIR/CodeGen/CIRGenerator.cpp
+3-10clang/tools/cir-opt/cir-opt.cpp
+10-0clang/lib/CIR/CMakeLists.txt
+116-226 files not shown
+126-3112 files

LLVM/project 1a89340clang/lib/ScalableStaticAnalysisFramework/Analyses/PointerFlow PointerFlowExtractor.cpp, clang/unittests/ScalableStaticAnalysisFramework/Analyses/PointerFlow PointerFlowTest.cpp

Enforce an EdgeSet (implemented as a map) invariant: each map entry
represents at least one edge.  That is, a map key should not exist if
the corresponding value is empty.
DeltaFile
+17-0clang/unittests/ScalableStaticAnalysisFramework/Analyses/PointerFlow/PointerFlowTest.cpp
+2-0clang/lib/ScalableStaticAnalysisFramework/Analyses/PointerFlow/PointerFlowExtractor.cpp
+19-02 files

LLVM/project 7ef07bccompiler-rt/test/hwasan/TestCases try-catch.cpp

[compiler-rt] Add missing test stdlib.h include (#201972)

Fixes test after libc++ PR #195509 which drops transitive includes.
DeltaFile
+1-0compiler-rt/test/hwasan/TestCases/try-catch.cpp
+1-01 files

LLVM/project 832f4c4clang/docs ReleaseNotes.rst, clang/include/clang/Options Options.td

[clang-cl] Add new option `/pathmap:<from>=<to>` to replace the path prefix <from> with <to>. (#198664)

This option matches MSVC options and does the path substitution for the
file references in the preprocessor macros, debug and coverage information.

This option acts as a clang's ``-ffile-prefix-map=value`` and with some
known differences in behaviour with original CL's option that do not affect 
the functionality:
* nomalizes the macro prefix map pathes -- removes `./` and uses the target's
platform-specific path separator character when exanding the preprocessor
macros -- ``-ffile-reproducible`` (but not the debug and coverage prefix maps).
* does not require ``/experimental:deterministic`` as by MSVC. It needed for 
removing a hostname from a mangling hash gen, but clang-cl does not use
a hostname  when generates the hashes.

Known issues:
  * does not remap the pathes within PCH/PCM files.
DeltaFile
+18-0clang/test/CodeGenCXX/cl-pathmap.cpp
+11-0clang/docs/ReleaseNotes.rst
+9-0clang/test/Preprocessor/cl-pathmap.c
+4-0clang/test/Driver/cl-pathmap.c
+2-0clang/include/clang/Options/Options.td
+44-05 files