- Jul 14, 2020
-
-
Roman Lebedev authored
[NFCI][InstCombine] Move store merging from `visitStoreInst()` into `visitUnconditionalBranchInst()` Summary: As @nikic is pointing out in https://bugs.llvm.org/show_bug.cgi?id=46680#c5, InstCombine should not have forward instruction scans, so let's move this transform into the proper place. This is pretty much NFCI. Reviewers: nikic, spatel Reviewed By: nikic Subscribers: hiraditya, llvm-commits, nikic Tags: #llvm Differential Revision: https://reviews.llvm.org/D83670
-
David Sherwood authored
I have added a new file: llvm/test/CodeGen/AArch64/README that describes what to do in the event one of the SVE codegen tests fails the warnings check. In addition, I've added comments to all the relevant SVE tests pointing users at the README file. Differential Revision: https://reviews.llvm.org/D83467
-
Kirill Bobyrev authored
Summary: This patch introduces basic textDocument/foldingRange support. It relies on textDocument/documentSymbols to collect all symbols and uses takes ranges to create folds. The next steps for textDocument/foldingRange support would be: * Implementing FoldingRangeClientCapabilities and respecting respect client preferences * Specifying folding range kind * Migrating from DocumentSymbol implementation to custom RecursiveASTVisitor flow that will allow more flexibility * Supporting more folding range types: comments, PP conditional regions, includes and other code regions (e.g. public/private/protected sections of classes, control flow statement bodies) Tested: (Neo)Vim (coc-clangd) and VSCode. Related issue: https://github.com/clangd/clangd/issues/310 Reviewers: sammccall Reviewed By: sammccall Subscribers: nridge, ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D82436
-
David Sherwood authored
In getCastInstrCost() when comparing different sizes for src and dst types we should be using the TypeSize comparison operators instead of relying upon TypeSize being converted a uin64_t. Previously this meant we were dropping the scalable property and treating fixed and scalable vector types the same. Differential Revision: https://reviews.llvm.org/D83461
-
David Sherwood authored
In DAGCombiner::TransformFPLoadStorePair we were dropping the scalable property of TypeSize when trying to create an integer type of equivalent size. In fact, this optimisation makes no sense for scalable types since we don't know the size at compile time. I have changed the code to bail out when encountering scalable type sizes. I've added a test to llvm/test/CodeGen/AArch64/sve-fp.ll that exercises this code path. The test already emits an error if it encounters warnings due to implicit TypeSize->uint64_t conversions. Differential Revision: https://reviews.llvm.org/D83572
-
Carl Ritson authored
Pre-commit clean up for D83641.
-
Djordje Todorovic authored
Attach DbgLoc on insertvalue/extractvalue instructions created by DeadArgumentElimination. This fixes the PR46350. Differential Revision: https://reviews.llvm.org/D81939
-
Carl Ritson authored
Preserve SCC dead flags in SIOptimizeExecMaskingPreRA. This helps with removing redundant s_andn2 instructions later. Reviewed By: rampitec Differential Revision: https://reviews.llvm.org/D83637
-
Amy Kwan authored
This patch implements builtins for the Test LSB by Byte instruction introduced in Power10. Differential Revision: https://reviews.llvm.org/D82431
-
Amara Emerson authored
On AArch64 we generate redundant G_SEXTs or G_SEXT_INREGs because of this. Differential Revision: https://reviews.llvm.org/D81993
-
Xing GUO authored
Is64bit is ambiguous. In this patch, we replace it with Is64BitAddrSize to make it clearer.
-
Kai Luo authored
Add missing CFI directives when probing in prologue if `stack-clash-protection` is enabled. Differential Revision: https://reviews.llvm.org/D83276
-
Valentin Clement authored
This reverts commit 65049d16. Buildbot failure clang-ppc64le-rhel
-
Valentin Clement authored
-
Jameson Nash authored
Here we teach the ConstantFolding analysis pass that it is not legal to replace a load of a bitcast constant (having a non-integral addrspace) with a bitcast of the value of that constant (with a different non-integral addrspace). But also teach it that certain bit patterns are always known and convertable (a fact it already uses elsewhere). This required us to also fix a globalopt test, since, after this change, LLVM is able to realize that the test actually is a valid transform (NULL is always a known bit-pattern) and so it doesn't need to emit the failure remarks for it. Also simplify some of the negative tests for transforms by avoiding a type change in their bitcast, and add positive versions of the same tests, to show that they otherwise should work. Differential Revision: https://reviews.llvm.org/D59730
-
Jameson Nash authored
This could previously make it more complicated for ConstantFolding later, leading to a higher likelyhood it would have to reject the expression, even though zero seems like probably the common case here. Differential Revision: https://reviews.llvm.org/D59730
-
Jameson Nash authored
And adds some additional test coverage to ensure later commits don't introduce regressions. Differential Revision: https://reviews.llvm.org/D59730
-
zuojian lin authored
Caused by uninitialized load of llvm::DwarfDebug::PrevCU: llvm::DwarfCompileUnit::addRange () at ../lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp:276 llvm::DwarfDebug::endFunctionImpl () at ../lib/CodeGen/AsmPrinter/DwarfDebug.cpp:1586 llvm::DebugHandlerBase::endFunction () at ../lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp:319 llvm::AsmPrinter::EmitFunctionBody () at ../lib/CodeGen/AsmPrinter/AsmPrinter.cpp:1230 llvm::ARMAsmPrinter::runOnMachineFunction () at ../lib/Target/ARM/ARMAsmPrinter.cpp:161 Most of the DebugInfo tests under `LLVM_LIT_ARGS:STRING=-sv --vg` prior to this fix, and pass with the fix applied. Reviewed By: aprantl, dblaikie Differential Revision: https://reviews.llvm.org/D81631
-
Walter Erquinigo authored
It was failing because some module events had empty UUID, and that was not handled correctly. The diff that added that logic is https://reviews.llvm.org/D82477
-
clementval authored
-
Walter Erquinigo authored
This test was added in https://reviews.llvm.org/D82477 and needs to wait a little bit before fetching some information.
-
Valentin Clement authored
Summary: This patch introduce the parser for OpenACC 3.0 in Flang. It uses the same TableGen mechanism than OpenMP. Reviewers: nvdatian, sscalpone, tskeith, klausler, ichoyjx, jdoerfert, DavidTruby Reviewed By: klausler Subscribers: SouraVX, mgorny, hiraditya, jfb, sstefan1, llvm-commits Tags: #llvm, #flang Differential Revision: https://reviews.llvm.org/D83649
-
Gui Andrade authored
Implement llvm.experimental.vector.{add,mul,or,and,...}. An IR test is included but no C test for lack of good way to get the compiler to emit these. Differential Revision: https://reviews.llvm.org/D82920 -
Mircea Trofin authored
The CHECKs are now in Inputs/test-module.ll
-
Richard Smith authored
We don't allow runtime-sized flexible array members, nor initialization of flexible array members, but it seems reasonable to support the most basic case where the flexible array member is empty.
-
Fangrui Song authored
Commit 1fed1316 assumed that NewShuffle (shuffle vector canonicalization result) will always be ShuffleVectorSDNode, which may be false (it may be a BITCAST node): ``` ... t12: v4i32 = scalar_to_vector t2 t15: v16i8 = bitcast t12 # LHS t17: v16i8 = vector_shuffle<u,u,u,u,u,u,u,u,0,1,2,3,u,u,u,u> t15, undef:v16i8 # SVN ``` Reviewed By: #powerpc, nemanjai Differential Revision: https://reviews.llvm.org/D83617
-
Ryan Prichard authored
The %arm_call_apsr expansion doesn't work when config.clang is a clang driver defaulting to a non-ARM arch. Rather than fix it, replace call_apsr.S with inline asm in call_apsr.h, which also resolves the FIXME added in D31259. Maybe the `__attribute__((noinline,pcs("aapcs")))` attributes are unnecessary on the static functions, but I was unsure what liberty the compiler had to insert instructions that modified the condition codes, so it seemed helpful. Differential Revision: https://reviews.llvm.org/D82147 -
Ryan Prichard authored
For Android only, compiler-rt used detect_target_arch to select the architecture to target. detect_target_arch was added in Sept 2014 (SVN r218605). At that time, compiler-rt selected the default arch using ${LLVM_NATIVE_ARCH}, which seems to have been the host architecture and therefore not suitable for cross-compilation. The compiler-rt build system was refactored in Sept 2015 (SVN r247094 and SVN r247099) to use COMPILER_RT_DEFAULT_TARGET_TRIPLE to control the target arch rather than LLVM_NATIVE_ARCH. This approach is simpler and also works for Android cross-compilation, so remove the detect_target_arch function. Android targets i686, but compiler-rt seems to identify 32-bit x86 as "i386". For Android, we were previously calling add_default_target_arch with i386, and calling add_default_target_arch with i686 does not build anything. i686 is not listed in builtin-config-ix.cmake, ALL_BUILTIN_SUPPORTED_ARCH. Differential Revision: https://reviews.llvm.org/D82148 -
Ryan Prichard authored
Split filter_builtin_sources into two functions: - filter_builtin_sources that removes generic files when an arch-specific file is selected. - darwin_filter_builtin_sources that implements the EXCLUDE/INCLUDE lists (using the files in lib/builtins/Darwin-excludes). darwin_filter_builtin_sources delegates to filter_builtin_sources. Previously, lib/builtins/CMakeLists.txt had a number of calls to filter_builtin_sources (with a confusing/broken use of the `excluded_list` parameter), as well as a redundant arch-vs-generic filtering for the non-Apple code path at the end of the file. Replace all of this with a single call to filter_builtin_sources. Remove i686_SOURCES. Previously, this list contained only the arch-specific files common to 32-bit and 64-bit x86, which is a strange set. Normally the ${ARCH}_SOURCES list contains everything needed for the arch. "i686" isn't in ALL_BUILTIN_SUPPORTED_ARCH. NFCI, but i686_SOURCES won't be defined, and the order of files in ${arch}_SOURCES lists will change. Differential Revision: https://reviews.llvm.org/D82151 -
Ryan Prichard authored
Android 32-bit x86 uses a 64-bit long double. Android 64-bit x86 uses a 128-bit quad-precision long double. Differential Revision: https://reviews.llvm.org/D82152
-
LLVM GN Syncbot authored
-
Stephen Hines authored
https://reviews.llvm.org/D75383 switched the C default to gnu17, but missed this instance. Differential Revision: https://reviews.llvm.org/D83726
-
Gui Andrade authored
Adds LLVM option to control eager checking under -msan-eager-checks. This change depends on the noundef keyword to determining cases where it it sound to check these shadows, and falls back to passing shadows values by TLS. Checking at call boundaries enforces undefined behavior rules with passing uninitialized arguments by value. Differential Revision: https://reviews.llvm.org/D81699
-
Mircea Trofin authored
The CHECKs are going to be shared with the development mode test
-
Mircea Trofin authored
This reverts commit 9908a3b9. The fix was to exclude the content of TFUtils.h (automatically included in the LLVM_Analysis module, when LLVM_ENABLE_MODULES is enabled). Differential Revision: https://reviews.llvm.org/D82817
-
Lang Hames authored
-
Gui Andrade authored
-
Tyker authored
Summary: NOTE: There is a mailing list discussion on this: http://lists.llvm.org/pipermail/llvm-dev/2019-December/137632.html Complemantary to the assumption outliner prototype in D71692, this patch shows how we could simplify the code emitted for an alignemnt assumption. The generated code is smaller, less fragile, and it makes it easier to recognize the additional use as a "assumption use". As mentioned in D71692 and on the mailing list, we could adopt this scheme, and similar schemes for other patterns, without adopting the assumption outlining. Reviewers: hfinkel, xbolva00, lebedev.ri, nikic, rjmccall, spatel, jdoerfert, sstefan1 Reviewed By: jdoerfert Subscribers: thopre, yamauchi, kuter, fhahn, merge_guards_bot, hiraditya, bollu, rkruppe, cfe-commits, llvm-commits Tags: #clang, #llvm Differential Revision: https://reviews.llvm.org/D71739
-
Eric Christopher authored
-
Kiran Chandramohan authored
This patch introduces lowering of the OpenMP parallel operation to LLVM IR using the OpenMPIRBuilder. Functions topologicalSort and connectPhiNodes are generalised so that they work with operations also. connectPhiNodes is also made static. Lowering works for a parallel region with multiple blocks. Clauses and arguments of the OpenMP operation are not handled. Reviewed By: rriddle, anchu-rajendran Differential Revision: https://reviews.llvm.org/D81660
-