Commit
ffdace4892bd1f43121d365c22eb9c3fe79aeb6c
by mingmingl[SROA] Add new test cases to cover existing SROA behavior that structs will be scalarized.
Add an IR in unit test directory, which demonstrate the scalarization for struct allocations. This is added to pave the way for an SROA change to skip scalarization for some cases.
Reviewed By: davidxl
Differential Revision: https://reviews.llvm.org/D114128
|
 | llvm/test/Transforms/SROA/alloca-struct.ll |
Commit
06dbb2856967a5497c6ddfad3d3fdfea20849f7e
by thomasraoux[mlir][vector] Remove usage of shapecast to remove unit dim
Instead of using shape_cast op in the pattern removing leading unit dimensions we use extract/broadcast ops. This is part of the effort to restrict ShapeCastOp fuirther in the future and only allow them to convert to or from 1D vector.
This also adds extra canonicalization to fill the gaps in simplifying broadcast/extract ops.
Differential Revision: https://reviews.llvm.org/D114205
|
 | mlir/lib/Dialect/Vector/VectorTransforms.cpp |
 | mlir/test/Dialect/Vector/vector-dim-one-shape-cast.mlir |
 | mlir/lib/Dialect/Vector/VectorOps.cpp |
 | mlir/test/Dialect/Vector/canonicalize.mlir |
 | mlir/test/Dialect/Vector/vector-transforms.mlir |
Commit
7cde5165131f1268a8506066275ef7938c58d156
by thomasraoux[mlir][vector] NFC, move some vector patterns in a separate file
Move patterns related to dropping lead unit dim into their own file.
Differential Revision: https://reviews.llvm.org/D114265
|
 | mlir/lib/Dialect/Vector/CMakeLists.txt |
 | mlir/lib/Dialect/Vector/VectorTransforms.cpp |
 | mlir/lib/Dialect/Vector/VectorDropLeadUnitDim.cpp |
Commit
9cdaf0b01b298dc05a213fca5943e23a2aec51a2
by jonathanchesterfield[openmp][amdgpu][nfc] Inline interop_hsa_get_kernel_info into only caller
|
 | openmp/libomptarget/plugins/amdgpu/impl/interop_hsa.cpp |
 | openmp/libomptarget/plugins/amdgpu/impl/system.cpp |
 | openmp/libomptarget/plugins/amdgpu/impl/interop_hsa.h |
 | openmp/libomptarget/plugins/amdgpu/src/rtl.cpp |
Commit
2997441b85c0ec94425e83316d7e63c32d8c5770
by i[ELF] Support discarding .got.plt
Fix a null pointer dereference when .got.plt is discarded.
This also adds a test for discarding `.plt`.
Reviewed By: ikudrin
Differential Revision: https://reviews.llvm.org/D114180
|
 | lld/test/ELF/linkerscript/discard-plt.s |
 | lld/ELF/SyntheticSections.cpp |
Commit
ff7f2cfa959bbc2effefb6f11f225b525e9029c8
by jay.foad[AMDGPU] Add an implicit use of M0 to all V_MOV_B32_indirect_read/write
NFCI. Previously the implicit use was added to V_MOV_B32_indirect_read when building the instruction. V_MOV_B32_indirect_write didn't have an implicit use of M0 at all, but apparently it did not cause any problems.
Differential Revision: https://reviews.llvm.org/D114239
|
 | llvm/lib/Target/AMDGPU/SIInstrInfo.cpp |
 | llvm/lib/Target/AMDGPU/VOP1Instructions.td |
 | llvm/test/CodeGen/AMDGPU/set-gpr-idx-peephole.mir |
Commit
47555d73f6538cf2c092a7314e3c82c631ce4ccb
by thomasraoux[mlir][gpu] Extend shuffle op modes and add nvvm lowering
Add up, down and idx modes to gpu shuffle ops, also change the mode from string to enum
Differential Revision: https://reviews.llvm.org/D114188
|
 | mlir/include/mlir/Dialect/GPU/GPUOps.td |
 | mlir/test/Dialect/LLVMIR/invalid.mlir |
 | mlir/test/Dialect/GPU/ops.mlir |
 | mlir/include/mlir/Dialect/LLVMIR/NVVMOps.td |
 | mlir/test/Conversion/GPUToNVVM/gpu-to-nvvm.mlir |
 | mlir/lib/Conversion/GPUToNVVM/LowerGpuOpsToNVVMOps.cpp |
 | mlir/lib/Dialect/GPU/IR/GPUDialect.cpp |
 | mlir/lib/Target/LLVMIR/Dialect/NVVM/NVVMToLLVMIRTranslation.cpp |
 | mlir/lib/Dialect/LLVMIR/IR/NVVMDialect.cpp |
 | mlir/test/Target/LLVMIR/nvvmir.mlir |
 | mlir/test/Dialect/LLVMIR/nvvm.mlir |
Commit
bd22554af06e1f16dc9ff12eac8987f0ceebe8c1
by Krzysztof.Drewniak[MLIR][GPU] Run generic LLVM optimizations when serializing (on AMD)
- Adds hooks that allow SerializeTo* passes to arbitrarily transform the produced LLVM Module before it is passed to the code generation passes.
- Uses these hooks within the SerializeToHsaco pass in order to run LLVM optimizations and to set the optimization level on the TargetMachine.
- Adds an optLevel parameter to SerializeToHsaco
Future work may include moving much of what's been added to SerializeToHsaco to SerializeToBlob, but that would require confirmation from the NVVM backend maintainers that it would be appropriate to do so.
Depends on D114107
Reviewed By: mehdi_amini
Differential Revision: https://reviews.llvm.org/D114113
|
 | mlir/lib/Dialect/GPU/CMakeLists.txt |
 | mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp |
 | mlir/include/mlir/Dialect/GPU/Passes.h |
 | mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp |
Commit
1b4c0cb3918a9f2d12f8259407fc8bce053e78bf
by Louis Dionne[libc++] Avoid potential truncation warnings in std::abs test
One some platforms, -Wimplicit-int-conversion is enabled by default, which can lead to additional warnings being triggered in this test. Since we're only trying to test errors related to calling abs(), the assignment is superfluous.
As a fly-by fix, correct one instance of ::abs to std::abs and made the test a .verify.cpp test instead.
Differential Revision: https://reviews.llvm.org/D114244
|
 | libcxx/test/std/numerics/c.math/abs.fail.cpp |
 | libcxx/test/std/numerics/c.math/abs.verify.cpp |
Commit
e1ce3dabf0c70d30a24f0586ddf2a965d730d30a
by Louis Dionne[libc++] Fix some tests that were broken in the single-threaded configuration
We never noticed it because our CI doesn't actually build against a C library that doesn't have threading functionality, however building against a truly thread-free platform surfaces these issues.
Differential Revision: https://reviews.llvm.org/D114242
|
 | libcxx/test/std/thread/thread.mutex/thread.once/thread.once.onceflag/default.pass.cpp |
 | libcxx/test/std/concepts/concepts.object/movable.compile.pass.cpp |
 | libcxx/test/std/concepts/concepts.compare/concept.equalitycomparable/equality_comparable.compile.pass.cpp |
 | libcxx/test/std/concepts/concepts.lang/concept.assignable/assignable_from.compile.pass.cpp |
 | libcxx/utils/generate_feature_test_macro_components.py |
 | libcxx/test/std/thread/thread.mutex/thread.once/thread.once.callonce/call_once.pass.cpp |
 | libcxx/test/std/thread/thread.mutex/thread.once/thread.once.onceflag/copy.compile.fail.cpp |
 | libcxx/test/std/thread/thread.mutex/thread.once/thread.once.onceflag/assign.compile.fail.cpp |
 | libcxx/test/std/concepts/concepts.compare/concept.equalitycomparable/equality_comparable_with.compile.pass.cpp |
 | libcxx/test/std/language.support/support.limits/support.limits.general/mutex.version.pass.cpp |
 | libcxx/test/std/thread/thread.mutex/thread.once/thread.once.callonce/race.pass.cpp |
 | libcxx/test/libcxx/thread/thread.mutex/version.pass.cpp |
 | libcxx/utils/generate_header_inclusion_tests.py |
Commit
e0f58444e126e80a0d43eb5b88622799910195e6
by Louis Dionne[libc++] Fix feature test macro for __cpp_lib_to_chars
We would have been defining it in <utility> instead of <charconv>. For the time being, this doesn't change anything since we don't implement the feature test macro anyways.
Also, as a fly-by, this removes obsolete feature test macro tests. There was a brief time back in the days when we wrote feature test macro tests manually. In particular, we had test files for __cpp_lib_to_chars and __cpp_lib_memory_resource. Since we now have a principled way of generating these tests with scripts, this commit removes the obsolete (and empty) tests for these two feature test macros.
Differential Revision: https://reviews.llvm.org/D114243
|
 | libcxx/test/std/language.support/support.limits/support.limits.general/utility.version.pass.cpp |
 | libcxx/include/version |
 | libcxx/test/std/language.support/support.limits/support.limits.general/charconv.pass.cpp |
 | libcxx/test/std/language.support/support.limits/support.limits.general/memory_resource.version.pass.cpp |
 | libcxx/test/std/language.support/support.limits/support.limits.general/charconv.version.pass.cpp |
 | libcxx/utils/generate_feature_test_macro_components.py |
Commit
d8e5a0c42bd8796cce9caa53aacab88c7cb2a3eb
by zarko[clang][NFC] Inclusive terms: replace some uses of sanity in clang
Rewording of comments to avoid using `sanity test, sanity check`.
Reviewed By: aaron.ballman, Quuxplusone
Differential Revision: https://reviews.llvm.org/D114025
|
 | clang/lib/Basic/DiagnosticIDs.cpp |
 | clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp |
 | clang/lib/Analysis/RetainSummaryManager.cpp |
 | clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp |
 | clang/lib/Sema/SemaExprCXX.cpp |
 | clang/lib/StaticAnalyzer/Checkers/MIGChecker.cpp |
 | clang/include/clang/AST/Redeclarable.h |
 | clang/lib/Sema/SemaDeclCXX.cpp |
 | clang/lib/Sema/SemaChecking.cpp |
 | clang/lib/Format/Format.cpp |
 | clang/lib/StaticAnalyzer/Checkers/UnixAPIChecker.cpp |
 | clang/lib/Driver/ToolChains/Clang.cpp |
 | clang/lib/Tooling/Syntax/Tree.cpp |
 | clang/include/clang/Sema/Lookup.h |
 | clang/lib/Analysis/BodyFarm.cpp |
 | clang/lib/Basic/SourceManager.cpp |
 | clang/lib/Frontend/FrontendActions.cpp |
 | clang/lib/Sema/SemaExpr.cpp |
 | clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp |
 | clang/include/clang/CodeGen/CGFunctionInfo.h |
 | clang/lib/Sema/SemaDecl.cpp |
 | clang/lib/StaticAnalyzer/Core/ExprEngine.cpp |
 | clang/lib/StaticAnalyzer/Core/Store.cpp |
 | clang/include/clang/Analysis/CFG.h |
 | clang/lib/Sema/SemaLookup.cpp |
Commit
b07b5bd72716625e0976a84d23652d94d8d0165a
by arthur.j.odwyer[libc++] Test that our algorithms never copy a user-provided comparator.
This is not mandated by the standard, so it goes in libcxx/test/libcxx/. It's certainly arguable that the algorithms changed here (`is_heap`, `is_sorted`, `min`, `max`) are harmless and we should just let them copy their comparators once. But at the same time, it's nice to have all our algorithms be 100% consistent and never copy a comparator, not even once.
Differential Revision: https://reviews.llvm.org/D114136
|
 | libcxx/include/__algorithm/binary_search.h |
 | libcxx/include/__algorithm/min_element.h |
 | libcxx/test/std/algorithms/robust_re_difference_type.compile.pass.cpp |
 | libcxx/include/__algorithm/is_heap.h |
 | libcxx/include/__algorithm/is_sorted_until.h |
 | libcxx/include/__algorithm/is_sorted.h |
 | libcxx/include/__algorithm/min.h |
 | libcxx/test/libcxx/algorithms/robust_against_copying_comparators.pass.cpp |
 | libcxx/include/__algorithm/max_element.h |
 | libcxx/include/__algorithm/max.h |
 | libcxx/include/__algorithm/is_heap_until.h |
 | libcxx/test/std/algorithms/robust_against_adl.compile.pass.cpp |
Commit
04954824ee158fffe6653c7eb51c07347b36ff21
by jonathanchesterfield[openmp][amdgpu][nfc] Simplify implicit args handling
Removes a +x/-x pair on the only store/load of a variable and deletes some nearby dead code. Also reduces the size of the implicit struct to reflect the code currently emitted by clang.
Differential Revision: https://reviews.llvm.org/D114270
|
 | openmp/libomptarget/plugins/amdgpu/impl/internal.h |
 | openmp/libomptarget/plugins/amdgpu/src/rtl.cpp |
 | openmp/libomptarget/plugins/amdgpu/impl/system.cpp |
Commit
3f3680dff3e72881bd89241fe512ec8138edbc70
by dblaikieDWARFVerifier: Simplify name lookups
No need to use the dynamic fallback query when the name type is known statically at the call site.
|
 | llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp |
Commit
3fcdd182e9784cb9c2d7ff54b44ec00bd6c91a87
by stellaraccidentNFC: Callout restriction on folding 0-result ops in documentation.
Differential Revision: https://reviews.llvm.org/D114271
|
 | mlir/docs/Canonicalization.md |
Commit
20f79f8caa3a333a34021f0028e828f97d79c2a1
by Krzysztof.Drewniak[MLIR][GPU] Make the path to ROCm a runtime option
Our current build assumes that the path to ROCm we find at build time will be the path at which ROCm is located when the built code is executed. This commit adds a --rocm-path option to SerializeToHsaco, and removes the HIP dependency that the SerializeToHsaco previously had.
Depends on D114113
(though the dependency is to ensure the diffs apply cleanly and to capture the dependency on D114107)
Reviewed By: mehdi_amini
Differential Revision: https://reviews.llvm.org/D114114
|
 | mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp |
 | mlir/lib/Dialect/GPU/CMakeLists.txt |
Commit
290cddcd139d668251821f11426f37481faf6d7f
by Alex LorenzAllow __attribute__((swift_attr)) in attribute push pragmas
This change allows SwiftAttr to be used with #pragma clang attribute push to add Swift attributes to large regions of header files. We plan to use this to annotate headers with concurrency information.
Patch by: Becca Royal-Gordon
Differential Revision: https://reviews.llvm.org/D112773
|
 | clang/include/clang/Basic/Attr.td |
 | clang/test/Misc/pragma-attribute-supported-attributes-list.test |
 | clang/test/AST/attr-swift_attr.m |
Commit
e059329b835aac1b93d764811b23c3cfd8b856c7
by Louis Dionne[libc++][NFC] Add missing include in test
|
 | libcxx/test/support/uses_alloc_types.h |
Commit
e9d12c248013b2d2b9880436727857e0ec8a7085
by stefanp[PowerPC][NFC] Add a series of codegen tests for vector reductions.
This patch only adds tests for PowerPC. The purpose of these tests is to track what code is generated for various vector reductions.
Reviewed By: nemanjai, #powerpc
Differential Revision: https://reviews.llvm.org/D113801
|
 | llvm/test/CodeGen/PowerPC/vector-reduce-mul.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-umin.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-fadd.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-or.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-fmin.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-fmax.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-fmul.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-xor.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-umax.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-smin.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-add.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-and.ll |
 | llvm/test/CodeGen/PowerPC/vector-reduce-smax.ll |
Commit
491efa7f31cbc39fe0aaad261a840cc5311346fb
by spatel[InstCombine] add/adjust tests for mask of sext i1; NFC
These are sibling transforms, but the test coverage was uneven and incomplete.
|
 | llvm/test/Transforms/InstCombine/or.ll |
 | llvm/test/Transforms/InstCombine/and.ll |
Commit
a075d67222832c234296ffd605f19e33023e6060
by apollo.mobility[Sema] fix nondeterminism in ASTContext::getDeducedTemplateSpecializationType
`DeducedTemplateSpecializationTypes` is a `llvm::FoldingSet<DeducedTemplateSpecializationType>` [1], where `FoldingSetNodeID` is based on the values: {`TemplateName`, `QualType`, `IsDeducedAsDependent`}, those values are also used as `DeducedTemplateSpecializationType` constructor arguments.
A `FoldingSetNodeID` created by the static `DeducedTemplateSpecializationType::Profile` may not be equal to`FoldingSetNodeID` created by a member `DeducedTemplateSpecializationType::Profile` of an instance created with the same {`TemplateName`, `QualType`, `IsDeducedAsDependent`}, which makes `DeducedTemplateSpecializationTypes` lookups nondeterministic.
Specifically, while `IsDeducedAsDependent` value is passes to the constructor, `IsDependent()` method on the created instance may return a different value, because `IsDependent` is not saved as is: ```name=clang/include/clang/AST/Type.h DeducedTemplateSpecializationType(TemplateName Template, QualType DeducedAsType, bool IsDeducedAsDependent) : DeducedType(DeducedTemplateSpecialization, DeducedAsType, toTypeDependence(Template.getDependence()) | // <~ also considers `TemplateName` parameter (IsDeducedAsDependent ? TypeDependence::DependentInstantiation : TypeDependence::None)), ``` For example, if an instance A with key `FoldingSetNodeID {A, B, false}` is inserted. Then a key `FoldingSetNodeID {A, B, true}` is probed: If it happens to correspond to the same bucket in `FoldingSet` as the first key, and `A.Profile()` returns `FoldingSetNodeID {A, B, true}`, then it's a hit. If the bucket for the second key is different from the first key, instance A is not considered at all, and it's a no hit, even if `A.Profile()` returns `FoldingSetNodeID {A, B, true}`.
Since `TemplateName`, `QualType` parameter values involve memory pointers, the lookup result depend on allocator, and may differ from run to run. When this is used as part of modules compilation, it may result in "module out of date" errors, if imported modules are built on different machines.
This makes `ASTContext::getDeducedTemplateSpecializationType` consider `Template.isDependent()` similar `DeducedTemplateSpecializationType` constructor.
Tested on a very big codebase, by running modules compilations from directories with varied path length (seem to affect allocator seed).
1. https://llvm.org/docs/ProgrammersManual.html#llvm-adt-foldingset-h
Patch by Wei Wang and Igor Sugak!
Reviewed By: bruno
Differential Revision: https://reviews.llvm.org/D112481
|
 | clang/include/clang/AST/Type.h |
 | clang/lib/AST/ASTContext.cpp |
Commit
d729f4c38fca91736ef1008660baccbd9d3552f6
by rdzhabarov[mlir] Bug fix. Stream must outlive the pass manager.
Bug fix. Stream must outlive the pass manager.
Reviewed By: Chia-hungDuan
Differential Revision: https://reviews.llvm.org/D114277
|
 | mlir/lib/Dialect/GPU/Transforms/SerializeToBlob.cpp |
Commit
3f3bee42d22988d018834c58af244dee08a52d9c
by quinn.pham[NFC][llvm] Inclusive language: remove instance of master from Thumb2SizeReduction.cpp
[NFC] As part of using inclusive language within the llvm project, this patch replaces master with main in `Thumb2SizeReduction.cpp`.
Reviewed By: dmgreen
Differential Revision: https://reviews.llvm.org/D114196
|
 | llvm/lib/Target/ARM/Thumb2SizeReduction.cpp |
Commit
a6f53afbcb4d995139064276b5ad971ad7ced5e2
by Krzysztof.Drewniak[MLIR][GPU] Link in device libraries during HSA compilation if needed
To perform some operations, such as sin() or printf(), code compiled for AMD GPUs must be linked to a series of device libraries. This commit adds support for linking in these libraries.
However, since these device libraries are delivered as LLVM bitcode, raising the possibility of version incompatibilities, this commit only links in libraries when the functions from those libraries are called by the code being compiled.
This code also sets the math flags to their most conservative values, as MLIR doesn't have a `-ffast-math` equivalent.
Depends on D114114
Reviewed By: mehdi_amini
Differential Revision: https://reviews.llvm.org/D114117
|
 | mlir/lib/Dialect/GPU/CMakeLists.txt |
 | mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp |
Commit
de11de308b6480fc35d901c7104f46918674418c
by kyulee[InstrProf] Use i32 for GEP index from lowering llvm.instrprof.increment
The `llvm.instrprof.increment` intrinsic uses `i32` for the index. We should use this same type for the index into the GEP instructions.
Reviewed By: MaskRay
Differential Revision: https://reviews.llvm.org/D114268
|
 | llvm/test/Transforms/PGOProfile/instr_entry_bb.ll |
 | clang/test/Profile/c-ternary.c |
 | clang/test/Profile/objc-general.m |
 | llvm/test/Instrumentation/InstrProfiling/runtime-counter-relocation.ll |
 | llvm/test/Transforms/PGOProfile/counter_promo_exit_catchswitch.ll |
 | clang/test/Profile/cxx-throws.cpp |
 | llvm/test/Instrumentation/InstrProfiling/atomic-updates.ll |
 | clang/test/Profile/cxx-class.cpp |
 | clang/test/Profile/c-captured.c |
 | clang/test/Profile/cxx-templates.cpp |
 | clang/test/Profile/cxx-lambda.cpp |
 | clang/test/Profile/cxx-rangefor.cpp |
 | llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp |
 | clang/test/CodeGen/profile-filter.c |
 | clang/test/Profile/cxx-stmt-initializers.cpp |
 | clang/test/Profile/c-general.c |
 | clang/test/Profile/branch-logical-mixed.cpp |
Commit
f764a1a5bd7c281d3d7cc3c6d7f1430711176762
by sam.mccall[clangd] Avoid possible crash: apply configuration after binding methods
The configuration may kick off indexing, which may involve sending LSP messages. The crash is fiddly to reproduce in a hermetic test (we need background indexing on without disk storage, and to handle server->client messages in LSPClient...)
Fixes https://github.com/clangd/clangd/issues/926
|
 | clang-tools-extra/clangd/ClangdLSPServer.cpp |
Commit
241df03ce5f0949501454b9ac796ccc90d52ddfb
by j-nagurne[NFC] Test commit, add whitespace to end-of-line
|
 | llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp |
Commit
1bd4dc4f2854edf3035732416ec7e4adbddaf982
by nathan[hmaptool] Port to python3
This is just a few trivial changes -- change the interpreter and fix a few byte-vs-string issues.
Differential Revision: https://reviews.llvm.org/D107944
|
 | clang/utils/hmaptool/hmaptool |