- Jul 30, 2023
-
-
Piotr Zegar authored
Detects when a variable is both incremented/decremented and referenced inside a complex condition and suggests moving them outside to avoid ambiguity in the variable's value. Reviewed By: xgupta Differential Revision: https://reviews.llvm.org/D149015
-
Simon Pilgrim authored
[X86] X86DAGToDAGISel::matchAddressRecursively - use SelectionDAG::MaxRecursionDepth instead of hard coded constant. NFCI. SelectionDAG::MaxRecursionDepth has the same max depth (with adjusted comparison).
-
Carlos Galvez authored
[clang-tidy] Do not warn on macros starting with underscore and lowercase letter in bugprone-reserved-identifier Fixes #64130 Differential Revision: https://reviews.llvm.org/D156608
-
Jay Foad authored
This is to help catch problems in D156552 that only showed up in an expensive checks build.
-
DianQK authored
Remove the following warning. ``` WARNING: Change IR value name 'tmp4' or use --prefix-filecheck-ir-name to prevent possible conflict with scripted FileCheck name. ```
-
Aleksandr Popov authored
Fix incorrect setting NSW flag to non-overflowing indvar base (D154954) Reviewed By: danilaml Differential Revision: https://reviews.llvm.org/D156577
-
Jonas Devlieghere authored
Support recursive record types in CTF, for example a struct that contains a pointer to itself: struct S { struct S *n; }; We are now more lazy when creating LLDB types. When encountering a record type (struct or union) we create a forward declaration and only complete it when requested. Differential revision: https://reviews.llvm.org/D156498 -
Fangrui Song authored
similar to 2a1edebd
-
Fangrui Song authored
AIX prefers rejecting certain unimplemented features like -fprofile-sample-use, making clang_f_opts.c (legacy test file testing many miscellaneous features) not suitable. We could specify --target=, but this style change is probably not the best for this legacy file.
-
Fangrui Song authored
Some targets (e.g. AIX) report an error for certain unimplemented features, making Clang exit with 1.
-
Fangrui Song authored
-
Fangrui Song authored
and remove a -### -fno-integrated-as test that would fail with --target=x86_64-windows-msvc.
-
Fangrui Song authored
-
Fangrui Song authored
-
Fangrui Song authored
The exit code for -### is inconsistent. Unrecognized options lead to exit code 1, as expected. However, most others errors (including invalid option value) lead to exit code 0, differing from GCC and most utilities. This is a longstanding quirk of -###, and we didn't fix it because many driver tests need adjustment. Change -### to be similar to -fdriver-only -v and exit with code 1. This requires fixing many driver tests, but the end result gives us stronger tests. * Existing `RUN: %clang -### ...` tests usually don't use `CHECK-NOT: error:` or `--implicit-check-not=error:`. If a change introduces an error, such a change usually cannot be detected. * Many folks contributing new tests don't know `-fdriver-only -v`. To test no driver error/warning for new tests, they can use the familiar `-### -Werror` instead of `-fdriver-only -v -Werror`. An incomplete list of prerequisite test improvement: * 2f79bb10: add -nogpulib to some AMDGPU tests * 9155e517: add --cuda-path= (test w/ and w/o /usr/local/cuda) * 80765ede: -mcpu=native may return either 0 or 1, depending on whether `--target=` specifies a native target * abae53f4: fix -fuse-ld=lld misuses (test w/o and w/o /usr/local/bin/ld.lld) Reviewed By: jhuber6, yaxunl, dblaikie Differential Revision: https://reviews.llvm.org/D156363
-
Fangrui Song authored
Similar to abae53f4 for lld by using -B.
-
Fangrui Song authored
-
Jonas Devlieghere authored
Fix parsing of large structs. If the size of a struct exceeds a certain threshold, the offset is encoded using two 32-bit integers instead of one. Differential revision: https://reviews.llvm.org/D156490
-
Fangrui Song authored
If program paths (GCC installation, --sysroot, -B, etc) don't contain ld.lld, whether -fuse-ld=lld succeeds depends on whether a PATH directory contains ld.lld. > error: invalid linker name in argument '-fuse-ld=lld' This behavior is not suitable when we adopt the new strict behavior of -### in D156363. For some tests, append -B%S/Inputs/lld similar to D92028. For others, use -fuse-ld=ld so that getDefaultLinker (instead of CLANG_DEFAULT_LINKER) is used. The complexity stems from CLANG_DEFAULT_LINKER.
-
Anton Rydahl authored
This command adds an OpenMP offloading specific command line reference. The OpenMP FAQ links to the .rst new file. Reviewed By: jhuber6 Differential Revision: https://reviews.llvm.org/D156387
-
Jacques Pienaar authored
A literal constant is not emitted as a variable but rather printed inline. The form used is same as the Attribute emission form. Differential Revision: https://reviews.llvm.org/D150356
-
- Jul 29, 2023
-
-
Nuno Lopes authored
It's used to create a vector where only 1 element is used While at it, change OOB extractelement to yield poison per LangRef
-
Jay Foad authored
Change the scheduler's physical register dependency tracking from registers-and-their-aliases to regunits. This has a couple of advantages when subregisters are used: - The dependency tracking is more accurate and creates fewer useless edges in the dependency graph. An AMDGPU example, edited for clarity: SU(0): $vgpr1 = V_MOV_B32 $sgpr0 SU(1): $vgpr1 = V_ADDC_U32 0, $vgpr1 SU(2): $vgpr0_vgpr1 = FLAT_LOAD_DWORDX2 $vgpr0_vgpr1, 0, 0 There is a data dependency on $vgpr1 from SU(0) to SU(1) and from SU(1) to SU(2). But the old dependency tracking code also added a useless edge from SU(0) to SU(2) because it thought that SU(0)'s def of $vgpr1 aliased with SU(2)'s use of $vgpr0_vgpr1. - On targets like AMDGPU that make heavy use of subregisters, each register can have a huge number of aliases - it can be quadratic in the size of the largest defined register tuple. There is a much lower bound on the number of regunits per register, so iterating over regunits is faster than iterating over aliases. The LLVM compile-time tracker shows a tiny overall improvement of 0.03% on X86. I expect a larger compile-time improvement on targets like AMDGPU. Differential Revision: https://reviews.llvm.org/D156552 -
Jay Foad authored
Differential Revision: https://reviews.llvm.org/D156551
-
Ian Anderson authored
I'm getting a few -Wundefined-inline warnings, and a -Wnon-modular-include-in-module too. Fix all of those. Reviewed By: Mordante, #libc Differential Revision: https://reviews.llvm.org/D156508
-
LLVM GN Syncbot authored
-
Kishan Parmar authored
After clang release/16.x there is a regression that -mabi=elfv1 or -mabi=elfv2 are being unused and throws warning. But clang-trunk throws error for -mabi=elfv2 or elfv1. Intent of this patch to accept elfv1 or elfv2 for -mabi. Reviewed By : nemanjai Differential Revision: https://reviews.llvm.org/D156351
-
Piotr Zegar authored
Detects code where a temporary object is directly constructed by calling a constructor or using an initializer list and immediately assigned to a reference variable. Reviewed By: xgupta Differential Revision: https://reviews.llvm.org/D146368
-
Anatoly Trosinenko authored
Using implicit CHECK prefix in one FileCheck invocation and explicit CHECK-V83A in the other one seems to misguide to use CHECK: lines as a common matching prefix at various places. Also note that ; CHECK, CHECK-V83A: ... line only matches the "CHECK-V83A" prefix. This commit explicitly splits the checks into common ones (CHECK) and invocation-specific ones (COMPAT and V83A) and updates the assertions with the update_llc_test_checks.py script. Reviewed By: efriedma, MaskRay Differential Revision: https://reviews.llvm.org/D156327
-
Nikita Popov authored
Currently, m_Mul() style matchers also match constant expressions. This is a regular source of assertion failures (usually by trying to do a match and then cast to Instruction or BinaryOperator) and infinite combine loops. At the same time, I don't think this provides useful optimization capabilities (all of the tests affected here are regression tests for crashes / infinite loops). Long term, all of these constant expressions (apart from possibly add/sub) are slated for removal per https://discourse.llvm.org/t/rfc-remove-most-constant-expressions/63179 -- but doing those removals can itself expose new crashes and infinite loops due to the current PatternMatch behavior. Differential Revision: https://reviews.llvm.org/D156401
-
Timm Bäder authored
The previous version was using llvm::reverse(CallExpr::arguments()), which causes problems when clang is compiled with GCC. Differential Revision: https://reviews.llvm.org/D155369
-
Justin Bogner authored
-
Justin Bogner authored
This doesn't really do anything but should simplify updating these APIs in the near future.
-
Job Noorman authored
The RISC-V psABI [1] defines them similarly to AArch64. [1] https://github.com/riscv-non-isa/riscv-elf-psabi-doc/blob/master/riscv-elf.adoc#mapping-symbol Reviewed By: yota9, Amir Differential Revision: https://reviews.llvm.org/D153277
-
Srishti Srivastava authored
Earlier, in the sparse backward dataflow analysis, data from the results of an op implementing `RegionBranchOpInterface` was considered to flow into the operands of every op that did not implement the `RegionBranchTerminatorOpInterface` but was return-like and present in a region of the former. It was thus also expected that the number of results of the former be equal to the number of operands in the latter. This understanding of dataflow is incorrect and thus this expectation is also not justified. This commit fixes this incorrect understanding. This commit ensures that these return-like ops are handled just like the ops implementing the `RegionBranchTerminatorOpInterface`, which means that, if this op has a region `A` whose successors are regions `B`, `C`, and `D`, then data flows from the arguments (successor inputs) of `B`, `C`, and `D` to the corresponding successor operands of this op. This fix is also propagated to liveness analysis that earlier relied on this incorrect implementation of the sparse backward dataflow analysis framework and corrects some incorrect assumptions made in it. Also cleaned up some unnecessary comments from the test file. Issue: https://github.com/llvm/llvm-project/issues/64139 . Signed-off-by:
Srishti Srivastava <srishtisrivastava.ai@gmail.com> Reviewed By: jcai19, matthiaskramm, Mogball Differential Revision: https://reviews.llvm.org/D156376
-
Craig Topper authored
Instead of hacking around RVInst4, we can use RVInstIUnary to fill in all 12 bits of the immediate.
-
Fangrui Song authored
Their exit code is otherwise dependent on whether /usr/local/cuda exists or the default target triple.
-
Fangrui Song authored
Otherwise %clang may fail if the default target triple isn't x86.
-
Fangrui Song authored
This reverts commit e39bf32b. Some tests have different behaviors depent on whether certain directories/files are present on the host. An incomplete list from https://lab.llvm.org/buildbot/#/builders/109/builds/70149 csky-toolchain.c riscv*-toolchain.c fuchsia.* hip-* ohos.c
-