- Sep 12, 2023
-
-
Scott Linder authored
Differential Revision: https://reviews.llvm.org/D158676
-
Scott Linder authored
Only a subset of the fields of DbgVariable are meaningful at any time, and some fields are re-used for multiple purposes (for example FrameIndexExprs is used with a throw-away frame-index of 0 to hold a single DIExpression without needing to add another member). The exact invariants must be reverse-engineered by inspecting the actual use of the class, its imprecise/outdated doc-comment, and some asserts. Refactor DbgVariable into a sum type by inheriting from std::variant. This makes the active fields for any given state explicit and removes the need to re-use fields in disparate contexts. As a bonus, it seems to reduce the size on my x86_64 linux box from 144 bytes to 96 bytes. There is some potential cost to `std::get` as it must check the active alternative even when context or an assert obviates it. To try to help ensure the compiler can optimize out the checks the patch also adds a helper `get` method which uses the noexcept `std::get_if`. Some of the extra cost would also be avoided more cleanly with a refactor that exposes the alternative types in the public interface, which will come in another patch. Differential Revision: https://reviews.llvm.org/D158675
-
Stanislav Mekhanoshin authored
-
David Spickett authored
* Assert no completions for tests that should not find completions. * Remove regex mode from complete_from_to, which was unused. This exposed bugs in 2 of the tests, target stop-hook and process unload. These were fixed in previous commits but couldn't be tested properly until this patch.
-
kadir çetinkaya authored
-
Fangrui Song authored
On a macOS host the version may be different. Fix: 9f77facf
-
Matt Arsenault authored
Currently assumes only do anything for fcmps that perform an exact class test.
-
Jeremy Morse authored
As per the stack of patches this is attached to, allow users of BasicBlock::splitBasicBlock to provide an iterator for a position, instead of just an instruction pointer. This is to fit with my proposal for how to get rid of debug intrinsics [0]. There are other call-sites that would need to change, but this is sufficient for a stage2clang self host and some other C++ projects to build identical binaries, in the context of the whole remove-DIs project. [0] https://discourse.llvm.org/t/rfc-instruction-api-changes-needed-to-eliminate-debug-intrinsics-from-ir/68939 Differential Revision: https://reviews.llvm.org/D152545
-
Benjamin Maxwell authored
This is a follow-on to D158753, and allows the lowering of a transfer read/write of n-D vectors with a single trailing scalable dimension to primitive vector ops. The final conversion to LLVM depends on D158517 and D158752, without these patches type conversion will fail (or an assert is hit in the LLVM backend) if the final IR contains an array of scalable vectors. This patch adds `transform.apply_patterns.vector.lower_create_mask` which allows the lowering of vector.create_mask/constant_mask to be tested independently of --convert-vector-to-llvm. Reviewed By: c-rhodes, awarzynski, dcaballe Differential Revision: https://reviews.llvm.org/D159482
-
David Spickett authored
These are all recent additions I think, including a few of mine for AArch64. Going forward the CI checks should help us fix these earlier.
-
Alex Brachet authored
It's important that the arch directory be included first so that its header files which interpose on the default include dir be included instead of the default ones. The clang driver [1] does this when not building with -nostdinc, the libcxx build should do the same. We found this after https://reviews.llvm.org/D154282 when cross compiling from non Linux to Linux. If the host machine was not Linux, _LIBCPP_HAS_NO_TIME_ZONE_DATABASE would be defined in the default include dir __config_site, while it was undefined in the arch specific one causing build failures.
-
bipmis authored
-
Nick Desaulniers authored
I would like to steal one of these bits to denote whether a kind may be spilled by the register allocator or not, but I'm afraid to touch of any this code using bitwise operands. Make flags a first class type using bitfields, rather than launder data around via `unsigned`.
-
Luke Lau authored
As noted in https://github.com/llvm/llvm-project/pull/65392#discussion_r1316259471, when lowering an extract of a fixed length vector from another vector, we don't need to perform the vslidedown on the full vector type. Instead we can extract the smallest subregister that contains the subvector to be extracted and perform the vslidedown with a smaller LMUL. E.g, with +Zvl128b: v2i64 = extract_subvector nxv4i64, 2 is currently lowered as vsetivli zero, 2, e64, m4, ta, ma vslidedown.vi v8, v8, 2 This patch shrinks the vslidedown to LMUL=2: vsetivli zero, 2, e64, m2, ta, ma vslidedown.vi v8, v8, 2 Because we know that there's at least 128*2=256 bits in v8 at LMUL=2, and we only need the first 256 bits to extract a v2i64 at index 2. lowerEXTRACT_VECTOR_ELT already has this logic, so this extracts it out and reuses it. I've split this out into a separate PR rather than include it in #65392, with the hope that we'll be able to generalize it later. This patch refactors extract_subvector lowering to lower to extract_subreg directly, and to shortcut whenever the index is 0 when extracting a scalable vector. This doesn't change any of the existing behaviour, but makes an upcoming patch that extends the scalable path slightly easier to read.
-
Ellis Hoag authored
In #65397 I attempted to fix these docs by adding a "." but that didn't seem to work. This tries to use two newlines to divide paragraphs.
-
Jakub Kuderski authored
Extend SPIR-V target serialization and deserialization to handle coop matrix types. Add a roundtrip test. In addition to `FileCheck` checks, the resulting spirv binary also passes `spir-val` (external tool). Also fix a type attribute bug surfaced by the `CooperativeMatrixLength` op. Multiple matrix operand attributes will be handled in a future patch to reduce the scope.
-
Ellis Hoag authored
Both ELF and COFF support `--no-lto-pgo-warn-mismatch` in https://reviews.llvm.org/D104431 to suppress warnings due to mismatching profile hashes. As profiles go stale, it becomes likely that some function's CFGs will change so that their profiles can no longer be used. This commit adds the linker option `--no-pgo-warn-mismatch` to suppress these warnings. Note that we do have the LLVM backend flag `no-pgo-warn-mismatch` https://github.com/llvm/llvm-project/blob/3df1a64ebad8f31231ba05cf6ff43a985fea9235/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp#L210 but that is set to true by default during LTO https://github.com/llvm/llvm-project/blob/3df1a64ebad8f31231ba05cf6ff43a985fea9235/llvm/include/llvm/LTO/Config.h#L76-L77
-
David Spickett authored
Some functions in Process were using LLDB_INVALID_ADDRESS instead of LLDB_INVALID_TOKEN. The only visible effect of this appears to be that "process unload <tab>" would complete to 0 even after the image was unloaded. Since the command is checking for LLDB_INVALID_TOKEN. Everything else worked somehow. I've added a check to the existing load unload tests anyway. The tab completion cannot be checked as is, but when I make them more strict in a later patch it will be tested.
-
- Sep 11, 2023
-
-
Luke Lau authored
This patch refactors extract_subvector lowering to lower to extract_subreg directly, and to shortcut whenever the index is 0 when extracting a scalable vector. This doesn't change any of the existing behaviour, but makes an upcoming patch that extends the scalable path slightly easier to read.
-
Nick Desaulniers authored
After commit 610ec954 ("[clang] allow const structs/unions/arrays to be constant expressions for C"), attempts to evaluate structs/unions/arrays as constants are also performed for C++98 and C++03. An assertion was getting tripped up since the potentially-partially evaluated value was not being reset for those 2 language modes. Make sure to reset it now for all C++ modes. Fixes: #65784
-
Luke Lau authored
This is partly a precommit for an upcoming patch, and partly to remove the fixed length LMUL restriction similarly to what was done in https://reviews.llvm.org/D158270, since it's no longer that relevant.
-
stefankoncarevic authored
Handle pointer attributes (noalias, nonnull, readonly, writeonly, dereferencable, dereferencable_or_null). "noalias" attribute is ignore for non-bare pointer. Reviewed By: krzysz00 Differential Revision: https://reviews.llvm.org/D157082
-
Maciej Gabka authored
[Driver] Do not generate error about unsupported target specific options when there is no compiler jobs The upstream commit: https://reviews.llvm.org/D151590 added a new flag to mark target specific compiler options. The side effect of it was that in cases when -### or -v is used without any input file, clang started emitting an error. It happened like that becasue there is no compilation actions created which could consume/verify these target specific options. This patch changes that error to a warning about unused option in situations when there is no actions and still generates error when there are actions. Fix for https://github.com/llvm/llvm-project/issues/64958 Differential Revision: https://reviews.llvm.org/D159361
-
Simon Pilgrim authored
[X86] matchIndexRecursively - add zext(add/addlike(x,c)) -> index: zext(x), disp + zext(c) pattern handling More restricted alternative to a8cef6b5
-
erichkeane authored
-
Guillaume Chatelet authored
This is not exhaustive for now but it provides a placeholder for `invoke_result` test mentioned in #65750.
-
Guillaume Chatelet authored
-
Jeremy Morse authored
As per my proposal for how to eliminate debug intrinsics [0], for various places in InstCombine prefer to insert using an instruction iterator rather than an instruction pointer. This is so that we can eventually pass more information in the iterator class. These call-sites where I've changed the spelling are those that necessary to build a stage2clang to produce an identical binary in the coming no-debug-intrinsics mode. [0] https://discourse.llvm.org/t/rfc-instruction-api-changes-needed-to-eliminate-debug-intrinsics-from-ir/68939 Differential Revision: https://reviews.llvm.org/D152543
-
Sergio Afonso authored
Re-land commit 3787fd94 This patch adds support for storing OpenMP REQUIRES information in the semantics symbols for programs/subprograms and modules/submodules, and populates them during directive resolution. A pass is added to name resolution that makes sure this information is also propagated across top-level programs, functions and subprograms. Storing REQUIRES information inside of semantics symbols will also allow supporting the propagation of this information across Fortran modules. This will come as a separate patch. The `bool DirectiveAttributeVisitor::Pre(const parser::SpecificationPart &x)` method is removed since it resulted in specification parts being visited twice. This is patch 3/5 of a series splitting D149337 to simplify review. Differential Revision: https://reviews.llvm.org/D157983
-
Felipe de Azevedo Piovezan authored
Querying the debug_str_offsets section requires parsing the top level DIE of the CU (as well as the section itself); the current getter, however, assumes this is done elsewhere. This patch changes the getter behavior to match what is done in other getter methods (e.g. `getCompilationDir` or `getVariableForAddress`), in other words, `extractDIEsIfNeeded` is now called prior to returning the debug_str_offsets contributions for the Unit. One way in which this bug manifested is when `dwarfdump --debug-str-offsets` is invoked: because the DIEs are never parsed, we incorrectly print an empty section (with no warnings or errors). Differential Revision: https://reviews.llvm.org/D159484
-
Ying Chen authored
Fix index typos, s.t. indexes in comments be same with riscv-v-spec v1.0 doc.
-
Giuliano Belinassi authored
Currently there is no PrintOnLeft attribute set, which results in an empty switch-case. When compiling this, MSVC issues a warning saying that the switch-case is empty. Fix this by using a macro and checking if this macro is defined or not. Links to D157394
-
Michael Halkenhäuser authored
Extend CMake variable `all_amdgpu_architectures` by `gfx941` and `gfx942`.
-
liqin.weng authored
Add basic handling for VP ops that can expand to Cast intrinsics Reviewed By: RKSimon Differential Revision: https://reviews.llvm.org/D159491
-
liqin.weng authored
Reviewed By: RKSimon Differential Revision: https://reviews.llvm.org/D159495
-
Balazs Benics authored
0954dc3f broke a build bot: https://lab.llvm.org/buildbot/#/builders/245/builds/13891 clang/test/Analysis/string.c Line 74: incompatible redeclaration of library function 'memcpy' Line 74: 'memcpy' is a builtin with type 'void *(void *, const void *, unsigned int)' Differential Revision: https://reviews.llvm.org/D159109
-
Matthias Springer authored
Mention that sizes of dynamic dims of tied OpResults/operands match at runtime.
-
Martin Lücke authored
Differential Revision: https://reviews.llvm.org/D153878
-
Sameer Sahasrabuddhe authored
The only real requirement is that entry and loop intrinsics should not be preceded by convergent operations in the same basic block. They do not need to be the first in the block. Relaxing the constraint on the entry and loop intrinsics avoids having to make changes in the construction of LLVM IR, such as getFirstInsertionPt(). It also avoids added complexity in the lowering to Machine IR, where COPY instructions may be added to the start of the basic block.
-
Guray Ozen authored
The 'TargetAttr' workflow was recently introduced to serialization for 'MLIR->LLVM->PTX'. #65857 removes previous passes (gpu::Serialization* passes) because they are duplicates. This PR removes the use of gpu::Serialization* passes in SM_90 integration tests, and enables the 'TargetAttr' workflow. It also moves the transform dialect specific test to a new folder.
-