- Nov 05, 2020
-
-
Louis Dionne authored
-
Mehdi Amini authored
Refactor PyPrintAccumulatorm, PyFileAccumulator, and PySinglePartStringAccumulator from IRModules.cpp to PybindUtils.h These are reusable utilities across bindings. Differential Revision: https://reviews.llvm.org/D90737
-
Mehdi Amini authored
This is a generic utility that can be reused beyond the IR bindings. Differential Revision: https://reviews.llvm.org/D90736
-
cchen authored
Clang now asserts for the below case: ``` void clang::CodeGen::CGOpenMPRuntime::createOffloadEntriesAndInfoMetadata(): Assertion `std::get<0>(E) && "All ordered entries must exist!"' failed. ``` The reason why Clang hit the assert is because in `emitTargetDataCalls`, both `BeginThenGen` and `BeginElseGen` call `registerTargetRegionEntryInfo` and try to register the Entry in OffloadEntriesTargetRegion with same key. If changing the expression in if clause to any constant expression, then the assert disappear. (https://godbolt.org/z/TW7haj) The assert itself is to avoid user from accessing elements out of bound inside `OrderedEntries` in `createOffloadEntriesAndInfoMetadata`. In this patch, I add a check in `registerTargetRegionEntryInfo` to avoid register the target region more than once. A test case that triggers assert: https://godbolt.org/z/4cnGW8 Reviewed By: ABataev Differential Revision: https://reviews.llvm.org/D90704
-
Craig Topper authored
riscv_sllw/srlw only reads the lower 32 bits of the first operand. And the lower 5 bits of the second operands. Whether the upper 32 bits of the input are sign bits or not doesn't matter. Also use ineg and not to shorten the patterns. Differential Revision: https://reviews.llvm.org/D90668
-
Rahul Joshi authored
- Eliminate duplicated information about mapping from memref -> its descriptor fields by consolidating that mapping in two functions: getMemRefDescriptorFields and getUnrankedMemRefDescriptorFields. - Change convertMemRefType() and convertUnrankedMemRefType() to use these functions. - Remove convertMemrefSignature and convertUnrankedMemrefSignature. Differential Revision: https://reviews.llvm.org/D90707
-
Rahul Joshi authored
- Also spell "isUninitialized" correctly. Differential Revision: https://reviews.llvm.org/D90768
-
Arnold Schwaighofer authored
This patch adds the `async` lowering of coroutines. This will be used by the Swift frontend to lower async functions. In contrast to the `retcon` lowering the frontend needs to be in control over control-flow at suspend points as execution might be suspended at these points. This is very much work in progress and the implementation will change as it evolves with the frontend. As such the documentation is lacking detail as some of it might change. rdar://70097093 Reapply with fix for memory sanitizer failure and sphinx failure. Differential Revision: https://reviews.llvm.org/D90612
-
Sean Silva authored
Previously, linalg-bufferize was a "finalizing" bufferization pass (it did a "full" conversion). This wasn't great because it couldn't be used composably with other bufferization passes like std-bufferize and scf-bufferize. This patch makes linalg-bufferize a composable bufferization pass. Notice that the integration tests are switched over to using a pipeline of std-bufferize, linalg-bufferize, and (to finalize the conversion) func-bufferize. It all "just works" together. While doing this transition, I ran into a nasty bug in the 1-use special case logic for forwarding init tensors. That logic, while well-intentioned, was fundamentally flawed, because it assumed that if the original tensor value had one use, then the converted memref could be mutated in place. That assumption is wrong in many cases. For example: ``` %0 = some_tensor : tensor<4xf32> br ^bb0(%0, %0: tensor<4xf32>, tensor<4xf32>) ^bb0(%bbarg0: tensor<4xf32>, %bbarg1: tensor<4xf32>) // %bbarg0 is an alias of %bbarg1. We cannot safely write // to it without analyzing uses of %bbarg1. linalg.generic ... init(%bbarg0) {...} ``` A similar example can happen in many scenarios with function arguments. Even more sinister, if the converted memref is produced by a `std.get_global_memref` of a constant global memref, then we might attempt to write into read-only statically allocated storage! Not all memrefs are writable! Clearly, this 1-use check is not a local transformation that we can do on the fly in this pattern, so I removed it. The test is now drastically shorter and I basically rewrote the CHECK lines from scratch because: - the new composable linalg-bufferize just doesn't do as much, so there is less to test - a lot of the tests were related to the 1-use check, which is now gone, so there is less to test - the `-buffer-hoisting -buffer-deallocation` is no longer mixed in, so the checks related to that had to be rewritten Differential Revision: https://reviews.llvm.org/D90657 -
Sean Silva authored
Differential Revision: https://reviews.llvm.org/D90656
-
Craig Topper authored
We need to ensure the upper 32 bits of the mask are zero. So that the srl shifts zeroes into the lower 32 bits. Differential Revision: https://reviews.llvm.org/D90585
-
Mehdi Amini authored
This is mostly a scripted update, it may not be perfect. function replace() { FROM=$1 TO=$2 git grep "$FROM" $REPO_PATH |cut -f 1 -d : | sort -u | \ while read file; do sed -i "s#$FROM#$TO#" $file ; done } replace '|\*===----------------------------------------------------------------------===\*|$' '//===----------------------------------------------------------------------===//' replace '^/\* =' '//==' replace '^/\*=' '//=' replace '^\\\*=' '//=' replace '^|\*' '//' replace ' \*|$' '' replace '=\*\\$' '=//' replace '== \*/$' '===//' replace '==\*/$' '==//' replace '^/\*\*\(.*\)\*/$' '///\1' replace '^/\*\(.*\)\*/$' '//\1' replace '//============================================================================//' '//===----------------------------------------------------------------------===//' Differential Revision: https://reviews.llvm.org/D90732 -
Christopher Tetreault authored
Silence warning Undefined Behavior Sanitzer warning: runtime error: negation of -9223372036854775808 cannot be represented in type 'int64_t' (aka 'long'); cast to an unsigned type to negate this value to itself Reviewed By: paulwalker-arm Differential Revision: https://reviews.llvm.org/D90710
-
Craig Topper authored
We don't need custom matching, we just a need a predicate to check the immediate is greater than 32. We can use the existing ImmSub32 to adjust the immediate. I've also used the new predicate in the other location that used ImmSub32. I tried to create a test case where we would break without the greater than 32 check on that pattern, but DAG combine defeated me. Still seemed safer to have it. Differential Revision: https://reviews.llvm.org/D90546
-
Joe Nash authored
Pseudo-registers allow different register encodings between gpu generations. Make sure we resolve the pseudo regs to real regs whenever we get their hardware encoding. Using the correct encodings revealed a register bank conflict and an unnecessary write dependency. Tests have been updated to match. Reviewed By: rampitec Differential Revision: https://reviews.llvm.org/D90721 Change-Id: I73c154cd24aecc820993b50bebaf4df97a5710ca
-
Fangrui Song authored
Revert "[GlobalISel] GISelKnownBits::computeKnownBitsImpl - Replace TargetOpcode::G_MUL handling with the common KnownBits::computeForMul implementation" This reverts commit 0b8711e1 which broke GlobalISelTests AArch64GISelMITest.TestKnownBits
-
Arthur Eubanks authored
This allows those instrumentation to log when they decide to skip a pass. This provides extra helpful info for optnone functions and also will help with opt-bisect. Have OptNoneInstrumentation print when it skips due to seeing optnone. Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D90545
-
Sebastian Neubauer authored
The insertion of waterfall loops splits the current basic block into three blocks. So the basic block that we iterate over must be updated. This failed assert(!NodePtr->isKnownSentinel()) in ilist_iterator for divergent calls in branches before. Differential Revision: https://reviews.llvm.org/D90596
-
Fangrui Song authored
This matches behavior GNU objcopy and can simplify clang-offload-bundler (which currently works around the issue by invoking llvm-objcopy twice). Reviewed By: jhenderson Differential Revision: https://reviews.llvm.org/D90438
-
Alexander Shaposhnikov authored
This diff makes the function isValidMachOCannonicalName static. NFC. Test plan: make check-all
-
Mehdi Amini authored
This also includes and exercise a register function for individual passes. Differential Revision: https://reviews.llvm.org/D90728
-
Simon Pilgrim authored
Use const references instead.
-
Simon Pilgrim authored
[GlobalISel] GISelKnownBits::computeKnownBitsImpl - Replace TargetOpcode::G_MUL handling with the common KnownBits::computeForMul implementation Avoid code duplication
-
Nabeel Omer authored
Adds visual studio debugger support to dexter via option --debugger vs2019 Differential Revision: https://reviews.llvm.org/D89803 Author: Nabeel Omer <nabeel.omer@sony.com>
-
Nabeel Omer authored
adds a test that checks debugging experience in functions that are marked __attribute__((optnone)) and have loops inside them. Differential Revision: https://reviews.llvm.org/D89873 Author: Nabeel Omer <nabeel.omer@sony.com>
-
Louis Dionne authored
Those are part of the library, and shipping them just adds a tiny bit of size to the distribution. This was originally added in b422ecc7 to make it possible to match the Makefile build, which doesn't exist anymore. The upside is build system simplification.
-
Arnold Schwaighofer authored
This reverts commit ea606cce. This patch causes memory sanitizer failures sanitizer-x86_64-linux-fast.
-
Louis Dionne authored
This will allow running the basic test on all platforms, and the part that requires signals on platforms that support them only.
-
Vy Nguyen authored
Differential Revision: https://reviews.llvm.org/D90764
-
- Nov 04, 2020
-
-
Kadir Cetinkaya authored
RemoteIndexClient implementations only depends on clangdSupport for logging functionality and has no dependence on clangDeamon itself. This clears out that link time dependency and enables depending on it in clangDeamon itself, so that we can have other index implementations that makes use of the RemoteIndex. Differential Revision: https://reviews.llvm.org/D90746
-
LLVM GN Syncbot authored
-
Balázs Kéri authored
SIG30-C. Call only asynchronous-safe functions within signal handlers First version of this check, only minimal list of functions is allowed ("strictly conforming" case), for C only. Differential Revision: https://reviews.llvm.org/D87449 -
Arnold Schwaighofer authored
This patch adds the `async` lowering of coroutines. This will be used by the Swift frontend to lower async functions. In contrast to the `retcon` lowering the frontend needs to be in control over control-flow at suspend points as execution might be suspended at these points. This is very much work in progress and the implementation will change as it evolves with the frontend. As such the documentation is lacking detail as some of it might change. rdar://70097093 Differential Revision: https://reviews.llvm.org/D90612
-
Eric Astor authored
Allows the MACRO directive to define macro procedures with parameters and macro-local symbols. Supports required and optional parameters (including default values), and matches ml64.exe for its macro-local symbol handling (up to 65536 macro-local symbols in any translation unit). Reviewed By: thakis Differential Revision: https://reviews.llvm.org/D89729
-
Pavel Labath authored
Use llvm::is(U)IntN (MathExtras.h) instead.
-
Pavel Labath authored
It's unused, and the same functionality is available in llvm (is(U)IntN in MathExtras.h).
-
Simon Pilgrim authored
-
Simon Pilgrim authored
gcc warns that the EXPECT_TRUE macro isn't surrounded by if() {} - we already do this in other cases in the file. -
Louis Dionne authored
Also simplify a few conditionals along the way for readability.
-
Aaron Ballman authored
This silences about 6000 warnings about truncating from double to float with Visual Studio.
-