- May 17, 2022
-
-
Thomas Lively authored
to reflect the latest state of the proposal: https://github.com/WebAssembly/relaxed-simd/blob/main/proposals/relaxed-simd/Overview.md#binary-format. Moves code around to match the instruction order from the proposal, but the only functional changes are to the names and opcodes. Reviewed By: aheejin Differential Revision: https://reviews.llvm.org/D125726
-
https://reviews.llvm.org/D125732Vy Nguyen authored
Details: The test was incorrectly expecting the error messages for the export symbols to have a particular order. It shouldn't because the export symbol list is processed concurrently.
-
Vy Nguyen authored
The metadata seems to be demangled differently
-
Philip Reames authored
Our current implementation of the InsertVSETVLI dataflow allows phase 3 to arrive at a different block end state than the data flow in phase 1/2 computed. This arises because a block which contains instructions (e.g. load or stores) which don't consume all the incoming bits of the VL/VTYPE can be compatible with multiple incoming states. The algorithm effectively changes the SEW on such instructions, and propagates the prior state forward. As phase 3 uses the block input state for this propagation, but phase 1/2 doesn't, this can result in different block end states. If we don't correct for it, this discrepancy can result in miscompiles. This was the source of multiple recent bugs. However, by now we have fixes for all known correctness issues. The basic strategy we use is to insert a compensation vsetvli to bring the block state leaving the block back into consistency with the one computed. This is correct, but results in extra vsetvlis being placed at the end of blocks. This change adjusts the phase 1/2 algorithm to propagate the incoming block state through the block, allowing the compatibility rules to modify the end state. The algorithm may need to run slightly more iterations, but the end result is consistent with what phase 3 does. The benefit of doing this is two fold. First, we reverse some of the code quality introductions introduced in the functional fixes. Second, we simplify the invariants, and allow the strict assertions to be enabled. Several humans, myself included, have found it quite surprising that invariant didn't hold already, and arguably that confusion is the cause of several of our recent miscompiles in this code. The downside to this patch is that the dataflow may require additional iterations to stabilize. In the worse case, we go from O(Edges) to O(E + UniquePaths) as the incoming state (and thus the outgoing one) can now change once for each path from the entry block. Differential Revision: https://reviews.llvm.org/D125232
-
Philip Reames authored
We've got a lurking problem with our data flow implementation where different phases disagree, resulting in possible miscompiles. D119518 introduced a workaround, but failed to consider blocks which only contain load/stores compatible with their incoming state. When I went to rebase and simplify D125232, it turned out that not all of the correctness issues had been fixed yet after all. This is the correctness fix accidentally embedded in the original more complicated version. Note that the test changes here are mostly regressions. It's worth noting that the simplified version of D125232 exactly reverses all the non-functional diffs in the test caused here. D125232 should be the immediate following commit. Differential Revision: https://reviews.llvm.org/D125703
-
Grace Jennings authored
This patch sorts unit test targets into directories corresponding to the test source file directories to improve target navigation. Reviewed By: smeenai Differential Revision: https://reviews.llvm.org/D124810
-
Mitch Phillips authored
An upcoming patch will extend llvm-symbolizer to provide the source line information for global variables. The goal is to move AddressSanitizer off of internal debug info for symbolization onto the DWARF standard (and doing a clean-up in the process). Currently, ASan reports the line information for constant strings if a memory safety bug happens around them. We want to keep this behaviour, so we need to emit debuginfo for these variables as well. Reviewed By: dblaikie, rnk, aprantl Differential Revision: https://reviews.llvm.org/D123534
-
Vy Nguyen authored
PR/55512 Reviewed By: keith Differential Revision: https://reviews.llvm.org/D125732
-
River Riddle authored
-
River Riddle authored
This commit enables proper highlighting when inner statements are outside of a constraint/pattern/etc. This shouldn't really happen in actual code, but can happen in documentation (which uses the same syntax grammar).
-
wren romano authored
In addition to reducing code repetition, this also helps ensure that the various API functions follow the naming convention of mlir::sparse_tensor::primaryTypeFunctionSuffix (e.g., due to typos in the repetitious code). Depends On D125428 Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D125431
-
Philip Reames authored
The existing redundant copy elimination required a virtual register source, but the same logic works for any physreg where we don't have to worry about clobbers. On RISCV, this helps eliminate redundant CSR reads from VLENB. Differential Revision: https://reviews.llvm.org/D125564
-
Ben Dunbobbin authored
Remove errant whitespace. AIX uses big archive format so check for both !<arch> and <bigaf>. Only the "gnu" format has thin archives; specify --format=gnu for thin archive test-cases.
-
River Riddle authored
-
Keith Smiley authored
All of the other tests here either check that the copy fails, or that the resulting binary is the same, it seems like this check was omitted for the universal object case. Differential Revision: https://reviews.llvm.org/D125478
-
River Riddle authored
This follows the same general structure of the MLIR and PDLL language servers. This commits adds the basic functionality for setting up the server, and initially only supports providing diagnostics. Followon commits will build out more comprehensive behavior. Realistically this should eventually live in llvm/, but building in MLIR is an easier initial step given that: * All of the necessary LSP functionality is already here * It allows for proving out useful language features (e.g. compilation databases) without affecting wider scale tablegen users * MLIR has a vscode extension that can immediately take advantage of it Differential Revision: https://reviews.llvm.org/D125440
-
Ken Matsui authored
This patch is itended to avoid suggesting typoed directives in `.S` files to support the cases of `#` directives treated as comments or various pseudo-ops. The feature is implemented in https://reviews.llvm.org/D124726. Fixes: https://reviews.llvm.org/D124726#3516346. Reviewed By: nickdesaulniers Differential Revision: https://reviews.llvm.org/D125727
-
wren romano authored
This enables the compiler to perform devirtualization. And benchmarks indicate devirtualization can sometimes give considerable speedup. Depends On D122061 Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D125428
-
wren romano authored
Fixes: https://github.com/llvm/llvm-project/issues/51652 Depends On D122060 Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D122061
-
River Riddle authored
In the overwhelmingly majority of cases only one dialect is generated at a time anyways, and this restriction more easily catches user error when multiple dialects might be generated. We hit this semi-recently with the PDL dialect, and circt+other downstream users are also actively hitting this as well. Differential Revision: https://reviews.llvm.org/D125651
-
Jason Molenda authored
This patch addresses two perf issues when we find a dSYM on macOS after calling into the DebugSymbols framework. First, when we have a local (probably stripped) binaary, we find the dSYM and we may be told about the location of the symbol rich binary (probably unstripped) which may be on a remote filesystem. We don't need the unstripped binary, use the local binary we already have. Second, after we've found the path to the dSYM, save that in the Module so we don't call into DebugSymbols a second time later on to rediscover it. If the user has a DBGShellCommands set, we need to exec that process twice, serially, which can add up. Differential Revision: https://reviews.llvm.org/D125616 rdar://84576917
-
Joseph Huber authored
The Clang driver additional stages to build a complete offloading program for applications using CUDA or OpenMP offloading. This normally requires either a source file input or a valid object file to be handled. This would cause problems when trying to compile an assembly or LLVM IR file through clang with flags that would enable offloading. This patch simply adds a check to prevent the offloading toolchain from being used if we don't have a valid source file. Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D125705
-
Joseph Huber authored
The OpenMP device offloading library is a bitcode library and thus only expect to build and linked with the same version of clang that was used to create it. This somewhat copmlicates the building process as we require the Clang that was just built to be used to create the library. This is either done with a two-step build, where OpenMP is built with the Clang that was just installed, or through the `-DLLLVM_ENABLE_RUNTIMES=openmp` option. This has always been the case, but recent changes have caused this to make it difficult to build the rest of OpenMP. This patchs adds a check to not build the OpenMP device runtime if the current compiler is not Clang with the same version as the LLVM installation. This should allow users to build OpenMP as a project using any compiler without it erroring out due to the bitcode library, but if users require it they will need to use the above methods to compile it. Reviewed By: jdoerfert, tianshilei1992, ye-luo Differential Revision: https://reviews.llvm.org/D125698
-
Alex Zinenko authored
Op registration mechanism does not allow for ops with the same name to be re-registered. This is okay to avoid name conflicts and debug double-registration, but may be problematic for dialect extensions that may get registered several times (unlike dialects that are deduplicated in the registry). When registering ops through the Transform dialect extension mechanism, check first if the ops are already registered and only complain in the case of repeated registration with the same name but different TypeID. Differential Revision: https://reviews.llvm.org/D125554
-
Jonas Devlieghere authored
Avoid a OverflowError (an underflow really) when the pc is zero. This can happen for "unknown frames" where the crashlog generator reports a zero pc. We could omit them altogether, but if they're part of the crashlog it seems fair to display them in lldb as well. rdar://92686666 Differential revision: https://reviews.llvm.org/D125716
-
Sanjay Patel authored
This reverts commit 3794cc0e. This change is suspected of causing bots to hang at stage 2 compiles, so reverting to confirm and investigate.
-
Martin Storsjö authored
This allows sharing opcodes between prolog and epilog even when there is more than one epilog. I didn't make any handcrafted special MC level testcases for this (yet at least), but it does seem to have the expected effect on two existing CodeGen level testcases. Differential Revision: https://reviews.llvm.org/D125619
-
Martin Storsjö authored
[MC] [Win64EH] Try writing an ARM64 "packed epilog" even if the epilog doesn't share opcodes with the prolog The "packed epilog" form only implies that the epilog is located exactly at the end of the function (so the location of the epilog is implicit from the epilog opcodes), but it doesn't have to share opcodes with the prolog - as long as the total number of opcode bytes and the offset to the epilog fit within the bitfields. This avoids writing a 4 byte epilog scope in many cases. (I haven't measured how much this shrinks actual xdata sections in practice though.) Differential Revision: https://reviews.llvm.org/D125536
-
Martin Storsjö authored
In f8b0a7af in 2016, this parameter was generalized on the caller side (previously passing STI.isTargetMachO(), now passing STI.splitFramePushPop()). Rename the parameter on the receiver side to match the generalization. Differential Revision: https://reviews.llvm.org/D125681
-
Eli Friedman authored
The spinlock requires that lock-free operations are available; otherwise, the implementation just calls itself. As discussed in D120026. Differential Revision: https://reviews.llvm.org/D123080
-
Paul Walker authored
NEON does not have native support for xor reductions. However, when reducing predicate vectors the operation is synonymous with an add reduction that is supported. Differential Revision: https://reviews.llvm.org/D125605
-
Ellis Hoag authored
When using counter relocations, two instructions are emitted to compute the address of the counter variable. ``` %BiasAdd = add i64 ptrtoint <__profc_>, <__llvm_profile_counter_bias> %Addr = inttoptr i64 %BiasAdd to i64* ``` When promoting a counter, these instructions might not be available in the block, so we need to copy these instructions. This fixes https://github.com/llvm/llvm-project/issues/55125 Reviewed By: phosek Differential Revision: https://reviews.llvm.org/D125710
-
Matthias Springer authored
Return immediately when an op bufferization patterns fails. Differential Revision: https://reviews.llvm.org/D125087
-
Mogball authored
An attribute without a type builder followed by a colon in an assembly format is potentially ambiguous because the parser will read ahead to parse the colon-type and pass this as the type argument to the attribute's constructor. However, the previous verifier that checks for this ambiguity erroneously produces an error in the case of ``` let assemblyFormat = "( `(` $attr `)` )? `:`"; ``` This patch fixes the bug by implementing a checker that correctly handles all edge cases, including very strange assembly formats like: ``` let assemblyFormat = "( `(` $attr ) : (`>`)? attr-dict (`>` $a^) : (`<`)? `:`"; ``` Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D125445
-
River Riddle authored
This was carry over from LLVM IR where the alias definition can be ambiguous, but MLIR type aliases have no such problems. Having the `type` keyword is superfluous and doesn't add anything. This commit drops it, which also nicely aligns with the syntax for attribute aliases (which doesn't have a keyword). Differential Revision: https://reviews.llvm.org/D125501
-
Mogball authored
This patch adds a topological sort utility and pass. A topological sort reorders the operations in a block without SSA dominance such that, as much as possible, users of values come after their producers. The utility function sorts topologically the operation range in a given block with an optional user-provided callback that can be used to virtually break cycles. The toposort pass itself recursively sorts graph regions under the target op. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D125063
-
zhijian authored
Summary: Use object::Archive::create so that the returned archive object has a dynamic type of either Archive or BigArchive. Reviewers: James Henderson,Fangrui Song Differential Revision: https://reviews.llvm.org/D124940
-
Mogball authored
The attribute self type parameter is currently treated like any other attribute parameter in the assembly format. The self type parameter should be handled by the operation parser and printer and play no role in the generated parsers and printers of attributes. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D125724
-
Aart Bik authored
This is the first implementation of complex (f64 and f32) support in the sparse compiler, with complex add/mul as first operations. Note that various features are still TBD, such as other ops, and reading in complex values from file. Also, note that the std::complex<float> had a bit of an ABI issue when passed as single argument. It is still TBD if better solutions are possible. Reviewed By: bixia Differential Revision: https://reviews.llvm.org/D125596
-
Yang Keao authored
In D123677, @YangKeao provided an implementation of `DOTGraphTraits{Viewer,Printer}` in the new pass manager. This commit migrates the `DomPrinter` and `DomViewer` to the new pass manager. Reviewed By: Meinersbur Differential Revision: https://reviews.llvm.org/D124904
-