- Jan 11, 2021
-
-
Zi Xuan Wu authored
Add LLVM_EXTERNAL_VISIBILITY macro to fix link error of https://reviews.llvm.org/D88466#2476378
-
Adrian Kuegel authored
Differential Revision: https://reviews.llvm.org/D94305
-
Craig Topper authored
[RISCV] Clear isCodeGenOnly flag on VMSGE(U) pseudo instructions. Remove InstAliases that duplicate the asm strings in the pseudos. The Pseudo class sets isCodeGenOnly=1 which causes the asm strings in the pseudos to be ignored. I think this is why the aliases are needed at all. Reviewed By: frasercrmck Differential Revision: https://reviews.llvm.org/D94024
-
Lang Hames authored
PreFixupPasses better reflects when these passes will run. A future patch will (re)introduce a PostAllocationPasses list that will run after allocation, but before JITLinkContext::notifyResolved is called to notify the rest of the JIT about the resolved symbol addresses.
-
Hsiangkai Wang authored
The size of spill/reload may be unknown for scalable vector types. When the size is unknown, print it as "Unknown-size" instead of a very large number. Differential Revision: https://reviews.llvm.org/D94299
-
ergawy authored
This commit adds support for (de-)serializing SpecConstantOpeation. One thing worth noting is that during deserialization, we assign a fake ID to enclosed ops inside SpecConstantOpeation. We need to do this in order for deserialization logic to properly update ID to value map and to later reference the created value from the sibling 'spv::YieldOp'. Reviewed By: antiagainst Differential Revision: https://reviews.llvm.org/D93591
-
Fangrui Song authored
Tested with stage 2 -DCMAKE_BUILD_TYPE=Debug clang, byte identical.
-
Fangrui Song authored
-
Chris Lattner authored
llvm::APInt cannot hold zero bit values, therefore we shouldn't try to form them. Differential Revision: https://reviews.llvm.org/D94384
-
Esme-Yi authored
Summary: This patch added variants of vec_sel and fixed bugzilla 46770. Reviewed By: nemanjai Differential Revision: https://reviews.llvm.org/D94162
-
Serguei Katkov authored
Loop peeling as a last step triggers loop simplification and this can change the loop structure. As a result all cashed values like latch branch becomes invalid. Patch re-structure the code to take into account the possible changes caused by peeling. Reviewers: dmgreen, Meinersbur, etiotto, fhahn, efriedma, bmahjour Reviewed By: Meinersbur, fhahn Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D93686
-
Craig Topper authored
This patch moves all but the BaseInstr to bits in TSFlags. For the index fields, we can just use a bit to indicate their presence. The locations of the operands are well defined. This reduces the llc binary by about 32K on my build. It also removes the binary search of the table from the custom inserter. Instead we just check that the SEW op is present. Reviewed By: rogfer01 Differential Revision: https://reviews.llvm.org/D94375
-
QingShan Zhang authored
We are checking the unsafe-fp-math for sqrt but not for fpow, which behaves inconsistent. As the direction is to remove this global option, we need to remove the unsafe-fp-math check for sqrt and update the test with afn fast-math flags. Reviewed By: Spatel Differential Revision: https://reviews.llvm.org/D93891
-
Nico Weber authored
This reverts commit 80dee796. Makes clang sometimes hang forever. See https://bugs.chromium.org/p/chromium/issues/detail?id=1164786#c6 for a stand-alone repro.
-
Philip Reames authored
This is a resubmit of dd6bb367 (which was reverted due to stage2 build failures in 7c63aac7), with the additional restriction added to the transform to only consider outer most loops. As shown in the added test case, ensuring LCSSA is up to date when deleting an inner loop is tricky as we may actually need to remove blocks from any outer loops, thus changing the exit block set. For the moment, just avoid transforming this case. I plan to return to this case in a follow up patch and see if we can do better. Original commit message follows... The basic idea is that if SCEV can prove the backedge isn't taken, we can go ahead and get rid of the backedge (and thus the loop) while leaving the rest of the control in place. This nicely handles cases with dispatch between multiple exits and internal side effects. Differential Revision: https://reviews.llvm.org/D93906
-
Fangrui Song authored
-
Kazu Hirata authored
This patch introduces a helper class SubsequentDelim to simplify loops that generate a comma-separated lists. For example, consider the following loop, taken from llvm/lib/CodeGen/MachineBasicBlock.cpp: for (auto I = pred_begin(), E = pred_end(); I != E; ++I) { if (I != pred_begin()) OS << ", "; OS << printMBBReference(**I); } The new class allows us to rewrite the loop as: SubsequentDelim SD; for (auto I = pred_begin(), E = pred_end(); I != E; ++I) OS << SD << printMBBReference(**I); where SD evaluates to the empty string for the first time and ", " for subsequent iterations. Unlike interleaveComma, defined in llvm/include/llvm/ADT/STLExtras.h, SubsequentDelim can accommodate a wider variety of loops, including: - those that conditionally skip certain items, - those that need iterators to call getSuccProbability(I), and - those that iterate over integer ranges. As an example, this patch cleans up MachineBasicBlock::print. Differential Revision: https://reviews.llvm.org/D94377 -
Shilei Tian authored
For now, `*_STANDALONE_BUILD` is set to ON even if they're built along with LLVM because of issues mentioned in the comments. This can cause some issues. For example, if we build OpenMP along with LLVM, we'd like to copy those OpenMP headers to `<prefix>/lib/clang/<version>/include` such that `clang` can find those headers without using `-I <prefix>/include` because those headers will be copied to `<prefix>/include` if it is built standalone. In this patch, we fixed the dependence issue in OpenMP such that it can be built correctly even with `OPENMP_STANDALONE_BUILD=OFF`. The issue is in the call to `add_lit_testsuite`, where `clang` and `clang-resource-headers` are passed as `DEPENDS`. Since we're building OpenMP along with LLVM, `clang` is set by CMake to be the C/C++ compiler, therefore these two dependences are no longer needed, where caused the dependence issue. Reviewed By: jdoerfert Differential Revision: https://re...
-
Shilei Tian authored
This patch added `openmp` to `LLVM_ALL_RUNTIMES` so that when the CMake argument `LLVM_ENABLE_RUNTIMES=all`, OpenMP can also be built. Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D94369
-
Roman Lebedev authored
[NFCI][SimplifyCFG] Prefer to add Insert edges before Delete edges into DomTreeUpdater, if reasonable This has a measurable impact on the number of DomTree recalculations. While this doesn't handle all the cases, it deals with the most obvious ones.
-
Pavel Labath authored
- s/createUniqueFile/createUniquePath -- we don't want to create the file, just the file name - s/data()/str().c_str()/ -- paths given to system apis must be null-terminated
-
Philip Reames authored
-
Philip Reames authored
-
Fangrui Song authored
The test added in D87147 did not actually test PR47391. Use an absolute path to test the canonicalization.
-
Philip Reames authored
-
Sanjay Patel authored
This snuck into 0aa75fb1 , but I didn't catch it locally.
-
Sanjay Patel authored
A severe compile-time slowdown from this call is noted in: https://llvm.org/PR48689 My naive fix was to put it under LLVM_DEBUG ( 267ff790 ), but that's not limiting in the way we want. This is a quick fix (or we could just remove the call completely and rely on some later pass to discover potentially wrong IR?). A bigger/better fix would be to improve/limit verifyFunction() as noted in: https://llvm.org/PR47712 Differential Revision: https://reviews.llvm.org/D94328
-
Kazu Hirata authored
This patch eliminates pesky "No newline at end of file" messages from git diff.
-
Kazu Hirata authored
The function was introduced without a use on Feb 2, 2016 in commit e1100f53.
-
Kazu Hirata authored
-
Nikita Popov authored
The APFloat::convertToInteger() API already implements the desired saturation semantics.
-
Nikita Popov authored
-
- Jan 10, 2021
-
-
Florian Hahn authored
Currently make_early_inc_range cannot be used with iterators with operator* implementations that do not return a reference. Most notably in the LLVM codebase, this means the User iterator ranges cannot be used with make_early_inc_range, which slightly simplifies iterating over ranges while elements are removed. Instead of directly using BaseT::reference as return type of operator*, this patch uses decltype to get the actual return type of the operator* implementation in WrappedIteratorT. This patch also updates a few places to use make use of make_early_inc_range. Reviewed By: dblaikie Differential Revision: https://reviews.llvm.org/D93992
-
Nico Weber authored
-
Nicolas Vasilache authored
This assertion is an old remnant from earlier days when only affine functions existed. It is not the place of affine map composition to check whether orthogonal considerations on what is allowed to be a symbol under the AffineScope trait.
-
Juneyoung Lee authored
This patch is a part of D93817 and makes transformations in CodeGen use poison for shufflevector/insertelem's initial vector element. The change in CodeGenPrepare.cpp is fine because the mask of shufflevector should be always zero. It doesn't touch the second element (which is poison). The change in InterleavedAccessPass.cpp is also fine becauses the mask is of the form <a, a+m, a+2m, .., a+km> where a+km is smaller than the size of the first vector operand. This is guaranteed by the caller of replaceBinOpShuffles, which is lowerInterleavedLoad. It calls isDeInterleaveMask and isDeInterleaveMaskOfFactor to check the mask is the desirable form. isDeInterleaveMask has the check that a+km is smaller than the vector size. To check my understanding, I added an assertion & added a test to show that this optimization doesn't fire in such case. Reviewed By: spatel Differential Revision: https://reviews.llvm.org/D94056
-
Fangrui Song authored
-
Craig Topper authored
This makes the mask align with the position of the bits in TSFlags which is a little more logical. I might be adding more fields to TSFlags and some might be single bits where just ANDing with mask to test the bit would make sense. While there rename TargetFlags in validateInstruction to reflect that it's just the constraint bits.
-
Craig Topper authored
We currently have about 7000 opcodes in the RISCVGenInstrInfo.inc enum. We can use uint16_t to store these values. We would need to grow by nearly 9x before we run out of space so this should last for a little while. This reduces the llc binary by 32K.
-
Nico Weber authored
This is already checked two lines up. No behavior change.
-