- Nov 14, 2023
-
-
Timm Baeder authored
`Function::getArgSize()` include both the instance and the RVO pointer, so we need to subtract here.
-
Utkarsh Saxena authored
Revert "[STLExtras] Remove incorrect hack to make indexed_accessor_range operator== compatible with C++20" (#72265) Reverts llvm/llvm-project#72220 This breaks C++20 build bot. Need to see if upgrading to clang-17 in the build bot would solve the issue.
-
Momchil Velikov authored
The CFIFixup pass assumes a function prologue is contained in a single basic block. This assumption is broken with upcoming support for stack probing (`-fstack-clash-protection`) in AArch64 - the emitted probing sequence in a prologue may contain loops, i.e. more than one basic block. The generated CFG is not arbitrary though: * CFI instructions are outside of any loops * for any two CFI instructions of the function prologue one dominates and is post-dominated by the other Thus, for the prologue CFI instructions, if one is executed then all are executed, there is a total order of executions, and the last instruction in that order can be considered the end of the prologoue for the purpose of inserting the initial `.cfi_remember_state` directive. That last instruction is found by finding the first block in the post-order traversal which contains prologue CFI instructions.
-
Alexey Bataev authored
trees with phis/buildvectors only.
-
David Truby authored
This patch fixes a small bug where the new flang runtime types for Windows (static, static_dbg, etc) are not built when the FortranRuntime is requested by adding the missing dependency.
-
David Spickett authored
This means that if we try to download a missing file, we do not get a document with the same file name, but containing only the http response code. ``` $ curl -O -L --fail https://raw.githubusercontent.com/llvm/llvm-project/main/.github/workflows/not-a-file.py % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 curl: (22) The requested URL returned error: 404 $ $? 22: command not found ``` Which will be less confusing than python complaining about the file contents.
-
elhewaty authored
- [InstCombine] Add test coverage for comparisons of operands including one-complemented oparands(NFC). - [InstCombine] Fold xored one-complemented operand comparisons. Alive2: https://alive2.llvm.org/ce/z/PZMJeB Fixes #69803.
-
Jeremy Morse authored
Our option to turn on the non-intrinsic form of debug-info (`--experimental-debuginfo-iterators`) currently requires that LLVM is built with the `LLVM_EXPERIMENTAL_DEBUGINFO_ITERATORS` cmake flag enabled, so that some (slight) performance regressions aren't on-by-default during the prototype/testing period. However, we still want to be able to _optionally_ run tests, if support is built into LLVM. To allow optionally exercising the non-intrinsic debug-info code, this patch adds `--try-experimental-debuginfo-iterators` to opt, which turns the `--experimental-debuginfo-iterators` flag on if support is built in, or leaves it off. This means we can run tests that: * Use normal dbg.value intrinsics if there's no support, or * Uses non-instruction DPValues if there is support. Which means we can start getting test coverage of DPValues/RemoveDIs behaviour, from in-tree tests, on our RemoveDIs buildbot. All the code to do with automagically converting from one form to the other landed in 10a9e744.
-
Utkarsh Saxena authored
[STLExtras] Remove incorrect hack to make indexed_accessor_range operator== compatible with C++20 (#72220) This partially reverts c312f025 The motivation behind this is unclear and the change predates the clang [implementation](https://github.com/llvm/llvm-project/commit/38b9d313e6945804fffc654f849cfa05ba2c713d) of [p2468r2](https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2022/p2468r2.html) so I am not sure if it was ever intended to work. Rewritten template operators were broken since the beginning. Moreover, moving away from `friend` would be beneficial as these would only accepted once clang revises its implementation for fixing https://github.com/llvm/llvm-project/issues/70210. It also helps in making sure that older compilers still compile LLVM (in C++20).
-
Leandro Lupori authored
Adjust some of the tests run by check-flang to make them pass on MacOS, either by skipping unsupported tests or by adapting the test for correct execution on MacOS. For now ctofortran.f90 test is marked as unsupported, but it can be adapted to run on MacOS once support for -isysroot flag is added to flang. Issues #70805 and #70807 are tracking the failing tests that remain, as these reveal real problems with flang.
-
David Sherwood authored
There are some workloads that are negatively impacted by using jump tables when the number of entries is small. The SPEC2017 perlbench benchmark is one example of this, where increasing the threshold to around 13 gives a ~1.5% improvement on neoverse-v1. I chose the minimum threshold based on empirical evidence rather than science, and just manually increased the threshold until I got the best performance without impacting other workloads. For neoverse-v1 I saw around ~0.2% improvement in the SPEC2017 integer geomean, and no overall change for neoverse-n1. If we find issues with this threshold later on we can always revisit this. The most significant SPEC2017 score changes on neoverse-v1 were: 500.perlbench_r: +1.6% 520.omnetpp_r: +0.6% and the rest saw changes < 0.5%. I updated CodeGen/AArch64/min-jump-table.ll to reflect the new threshold. For most of the affected tests I manually set the min number ...
-
Simon Pilgrim authored
[DAG] foldABSToABD - support abs(*ext(x) - *ext(y)) -> zext(abd*(x, y)) from different extension source types (#71670) We currently limit the fold to cases where we're extending from the same source type, but we can safely perform this using the wider of mismatching source types (we're really just interested in having extension bits on both sources), ensuring we don't create additional extensions/truncations.
-
Benjamin Maxwell authored
Previously, we were inserting za.enable/disable intrinsics for functions with the "arm_za" attribute (at the MLIR level), rather than using the backend attributes. This was done to avoid a dependency on the SME ABI functions from compiler-rt (which have only recently been implemented). Doing things this way did have correctness issues, for example, calling a streaming-mode function from another streaming-mode function (both with ZA enabled) would lead to ZA being disabled after returning to the caller (where it should still be enabled). Fixing issues like this would require re-doing the ABI work already done in the backend within MLIR. Instead, this patch switches to use the "arm_new_za" (backend) attribute for enabling ZA for an MLIR function. For the integration tests, this requires some way of linking the SME ABI functions. This is done via the `%arm_sme_abi_shlib` lit substitution. By default, this ...
-
Simon Pilgrim authored
Add missing X86 checks
-
Ivan Kosarev authored
Resolves AsmParser ambiguities, e.g., between BUFFER_WBINVL1_vi and BUFFER_WBINVL1_gfx6_gfx7. Part of <https://github.com/llvm/llvm-project/issues/69256>.
-
Akash Banerjee authored
Currently, when deleting the device functions in the second stage of filtering during MLIR to LLVM translation we can end up with invalid calls to these functions. This is because of the removal of the EarlyOutliningPass which would have otherwise gotten rid of any such calls. This patch aims to alter the function filtering pass in the following way: - Any host function is completely removed. - Call to the host function are also removed and their uses replaced with Undef values. - Any host function with target region code is marked to be removed during the the second stage. - Calls to such functions are still removed and their uses replaced with Undef values. Co-authored-by:Sergio Afonso <sergio.afonsofumero@amd.com>
-
Diana authored
Switch to using immediate offsets instead of the SP register to access objects on the current stack frame in chain functions. This means we no longer need to reserve a SP register just for accesing stack objects and it also allows us to set the SP (when one is actually needed) to the stack size from the very beginning. This only works if we use a FixedObject for the ScavengeFI, which is what we do for entry functions anyway (and we generally want to keep chain functions close to amdgpu_cs behaviour where we don't have a good reason to diverge).
-
Anatoly Trosinenko authored
Refactor Pointer Authentication pass in preparation for adding more PAUTH_* pseudo instructions: * dropped early return from runOnMachineFunction() as other PAUTH_* instructions need expansion even when pac-ret is disabled * refactored runOnMachineFunction() to first collect all the instructions of interest without modifying anything and then performing changes in the later loops. There are two types of relevant instructions: PAUTH_* pseudos that should definitely be replaced by this pass and tail call instructions that may require attention if pac-ret is enabled * made the loop iterating over all of the instructions handle instruction bundles by itself: even though this pass still does not support bundled TCRETURN* instructions (such as produced by KCFI) it does not crash anymore when no support is actually required
-
QuietMisdreavus authored
Other implementations of the symbol graph format use zero-based indices for source locations, which causes problems when combined with clang's current one-based indices. This commit sets ExtractAPI's symbol graph output to use zero-based indices to align with other implementations. rdar://107639783
-
Matthew Devereau authored
Adds the builtins: void svldr_zt(uint64_t zt, const void *rn) void svstr_zt(uint64_t zt, void *rn) And the intrinsics: call void @llvm.aarch64.sme.ldr.zt(i32, ptr) tail call void @llvm.aarch64.sme.str.zt(i32, ptr) Patch by: Kerry McLaughlin <kerry.mclaughlin@arm.com>
-
S. B. Tam authored
-
Momchil Velikov authored
Precommit test for https://github.com/llvm/llvm-project/pull/68984
-
Michael Buch authored
`638a8393` removed the `dsym` condition for older compiler versions which caused the `dwarf` variants tests to XPASS. This patch reverts to only XFAIL-ing the `dsym` variant. `15c80852` added `test_shadowed_static_inline_members` which isn't supported on older compiler versions.
-
Endre Fülöp authored
The given glob needed to be fixed; static analyzer-related PRs were also assigned this label erroneously.
-
Balázs Kéri authored
The functions 'readlink' and 'readlinkat' do return 0 only if the 'bufsize' argument is 0.
-
Jie Fu authored
/llvm-project/llvm/lib/IR/ConstantFold.cpp:137:12: error: unused variable 'CSize' [-Werror,-Wunused-variable] unsigned CSize = cast<IntegerType>(C->getType())->getBitWidth()/8; ^ 1 error generated. -
Fangrui Song authored
For -fno-pic, if an extern variable is defined in a DSO, a copy relocation will be needed. However, loongarch*-linux does not and will not support copy relocations. Change Driver to default to -fno-direct-access-external-data for LoongArch && non-PIC. Keep Frontend conditions unchanged (-fdirect-access-external-data || -fno-direct-access-external-data && PIC>0 => direct access). Fix #71645
-
Fangrui Song authored
Similar to https://reviews.llvm.org/D157550
-
Nikita Popov authored
Remove support for the lshr and ashr constant expressions. All places creating them have been removed beforehand, so this just removes the APIs and uses of these constant expressions in tests. This is part of https://discourse.llvm.org/t/rfc-remove-most-constant-expressions/63179.
-
David Spickett authored
This file and uses of it were removed in 64d5da60.
-
Mike Hommey authored
Cc: @kazutakahirata
-
Haojian Wu authored
See the discussion in #69309.
-
Nikita Popov authored
For `{{regex}}` we don't really need a capturing group, and only add it to properly handle cases like `{{foo|bar}}`. This is problematic, because the use of capturing groups makes our regex implementation slower (we have to go through the "dissect" stage, which can have quadratic complexity). Unfortunately, our regex implementation does not support non-capturing groups like `(?:regex)`. So instead, avoid adding the group entirely if the regex doesn't contain any alternations. This causes a slight difference in escaping behavior, where previously it was possible to write `{{{{}}` and get the same behavior as `{{\{\{}}`. This will no longer work. I don't think this is a problem, especially as we recently taught update_analyze_test_checks.py to emit `{{\{\{}}`, so this shouldn't get introduced in any new tests. For CodeGen/X86/vector-interleaved-store-i16-stride-7.ll (our slowest X86 test) this drops FileCheck time from 6s to 5s (the remainder is spent in a different regex issue). I expect similar speedups in other tests using a lot of `{{}}`. -
Nikita Popov authored
Fix the issue by not reusing the zext at all. The code already handles creation of new zexts if more than one is needed. Always use that code-path instead of trying to reuse the old zext in some case. (Alternatively we could also drop poison-generating flags on the old zext, but it seems cleaner to not reuse it at all, especially if it's not always possible anyway.) Fixes https://github.com/llvm/llvm-project/issues/72046.
-
Phoebe Wang authored
Fixes #72106
-
Phoebe Wang authored
This reverts commit 451c594b. Revert due to buildbot fails.
-
Phoebe Wang authored
#71318 failed to clear EVEX512 feature for intended intrinsics. Fixes #72106
-
pvanhout authored
-
Paulo Matos authored
Removed as part of 7b9d73c2 .
-
Craig Topper authored
These can be treated simlarly to PseudoCCADDW/SUBW.
-