- Sep 15, 2020
-
-
Hans Wennborg authored
-
Craig Topper authored
The code that decomposes the GEP into ADD/MUL doesn't work properly for vector GEPs. It can create bad COPY instructions or possibly assert. For now just bail out to SelectionDAG. Fixes PR45906 (cherry picked from commit 4208ea3e)
-
Kirill Bobyrev authored
As per LSP specification, allCommitCharacters should be string[] instead of string: https://microsoft.github.io/language-server-protocol/specification#textDocument_completion Reviewed By: sammccall Differential Revision: https://reviews.llvm.org/D86604 (cherry picked from commit 9d11e678)
-
Qiu Chaofan authored
960cbc53 immediately removes nodes that won't be used to avoid compilation time explosion. This patch adds the removal to constants to fix PR47517. Reviewed By: RKSimon, steven.zhang Differential Revision: https://reviews.llvm.org/D87614 (cherry picked from commit 2508ef01)
-
Nikita Popov authored
This is a followup to D86834, which partially fixed this issue in InstSimplify. However, InstCombine repeats the same transform while dropping poison flags -- which does not cover cases where poison is introduced in some other way. The fix here is a bit more comprehensive, because things are quite entangled, and it's hard to only partially address it without regressing optimization. There are really two changes here: * Export the SimplifyWithOpReplaced API from InstSimplify, with an added AllowRefinement flag. For replacements inside the TrueVal we don't actually care whether refinement occurs or not, the replacement is always legal. This part of the transform is now done in InstSimplify only. (It should be noted that the current AllowRefinement check is not sufficient -- that's an issue we need to address separately.) * Change the InstCombine fold to work by temporarily dropping poison generating flags, running the fold and then restoring the flags if it didn't work out. This will ensure that the InstCombine fold is correct as long as the InstSimplify fold is correct. Differential Revision: https://reviews.llvm.org/D87445
-
Nikita Popov authored
-
Nikita Popov authored
Canonicalize icmp ne to icmp eq and implement all the folds only once.
-
- Sep 14, 2020
-
-
dfukalov authored
It was found some packed immediate operands (e.g. `<half 1.0, half 2.0>`) are incorrectly processed so one of two packed values were lost. Introduced new function to check immediate 32-bit operand can be folded. Converted condition about current op_sel flags value to fall-through. Fixes: SWDEV-247595 Reviewed By: rampitec Differential Revision: https://reviews.llvm.org/D87158 (cherry picked from commit d03c4034dc80c944ec4a5833ba8f87d60183f866)
-
- Sep 11, 2020
-
-
Richard Barton authored
Add a new index page to be the Flang documentation mainpage instead of Overview.md, which jumps straight into the compiler Design. The index file needs to be in .rst format to use the toctree directive to create table of contents. Also use the sphinx_markdown_tables extension to generate html tables form markdown. A number of additional style changes to the existing docs were needed to make this work well: * Convert all headings to the # style, which works better with toctree's titlesonly option. Ensure that there is only one top-level heading per document. * Add a title to documents that don't have one for rendering on the index. * Convert the grammar docs from .txt to .md. for better rendering * Fixed broken link to a section in another document - sphinx does not seem to support anchor links in markdown files. Depends on D87226 Reviewed By: sameeranjoshi Differential Revision: https://reviews.llvm.org/D87242
-
Cullen Rhodes authored
The AAPCS64 specifies the internal type is used for c++ mangling. For bfloat16 it was defined as `BFloat16` when it should be `Bfloat16`, i.e. lowercase 'f'. For more information, see: https://github.com/ARM-software/abi-aa/blob/master/aapcs64/aapcs64.rst#appendix-support-for-advanced-simd-extensions Reviewed By: stuij Differential Revision: https://reviews.llvm.org/D87463 (cherry picked from commit cabd60c2)
-
Alok Kumar Sharma authored
This is to fix CodeView build failure https://bugs.llvm.org/show_bug.cgi?id=47287 after DIsSubrange upgrade D80197 Assert condition is now removed and Count is calculated in case LowerBound is absent or zero and Count or UpperBound is constant. If Count is unknown it is later handled as VLA (currently Count is set to zero). Reviewed By: rnk Differential Revision: https://reviews.llvm.org/D87406 (cherry picked from commit e45b0708) -
Kamil Rytarowski authored
Partial revert of https://reviews.llvm.org/D82424 (cherry picked from commit f51e55e0)
-
Richard Barton authored
Switch ReleaseNotes from .rst to .md to match the other docs. At the same time, fix the version number for master.
-
Sourabh Singh Tomar authored
This reverts commit f787c9a9, this was causing some build issues. (cherry picked from commit 932aae77)
-
- Sep 09, 2020
-
-
Brad Smith authored
Reviewed By: nemanjai Differential Revision: https://reviews.llvm.org/D86165 (cherry picked from commit 88b368a1)
-
Craig Topper authored
SSE4_1 and SSE4_2 due imply SSSE3. So I guess I got confused when switching the code to being table based in D83273. Fixes PR47464 (cherry picked from commit e6bb4c8e)
-
mydeveloperday authored
In some situation shifts can be treated as a template, and is thus formatted as one. So, by doing a couple extra checks to assure that the condition doesn't contain a template, and is in fact a bit shift should solve this problem. This is a fix for [[ https://bugs.llvm.org/show_bug.cgi?id=46969 | bug 46969 ]] Reviewed By: MyDeveloperDay Patch By: Saldivarcher Differential Revision: https://reviews.llvm.org/D86581 (cherry picked from commit c81dd3d1)
-
- Sep 08, 2020
-
-
Serge Guelton authored
This patch is cherry-picked from 04b0a4e2, and amended to prevent an undefined reference to `llvm::EnableABIBreakingChecks' (cherry picked from commit 38778e10)
-
Nemanja Ivanovic authored
The load builtins in altivec.h do not have const in the signature for the pointer parameter. This prevents using them for loading from constant pointers. A notable case for such a use is Eigen. This patch simply adds the missing const. Fixes: https://bugs.llvm.org/show_bug.cgi?id=47408 (cherry picked from commit 54205f0b)
-
Juneyoung Lee authored
-
Brad Smith authored
Select the UltraSPARC instruction set with the external assembler on Linux / FreeBSD / OpenBSD, matches GCC. (cherry picked from commit 70523ecf)
-
Brad Smith authored
(cherry picked from commit 8542dab9)
-
Aaron Puchert authored
When parsing a C++17 binding declaration, we first create the BindingDecls in Sema::ActOnDecompositionDeclarator, and then build the DecompositionDecl in Sema::ActOnVariableDeclarator, so the contained BindingDecls are never null. But when deserializing, we read the DecompositionDecl with all properties before filling in the Bindings. Among other things, reading a declaration reads whether it's invalid, then calling setInvalidDecl which assumes that all bindings of the DecompositionDecl are available, but that isn't the case. Deserialization should just set all properties directly without invoking subsequent functions, so we just set the flag without using the setter. Fixes PR34960. Reviewed By: rsmith Differential Revision: https://reviews.llvm.org/D86207 (cherry picked from commit 16975a63)
-
Nemanja Ivanovic authored
These overloads are listed in appendix A of the ELFv2 ABI specification without a requirement for ISA 3.0. So these need to be available on all Altivec-capable architectures. The implementation in altivec.h erroneously had them guarded for Power9 due to the availability of the VCMPNE[BHW] instructions. However these need to be implemented in terms of the VCMPEQ[BHW] instructions on older architectures. Fixes: https://bugs.llvm.org/show_bug.cgi?id=47423
-
Craig Topper authored
[MachineCopyPropagation] In isNopCopy, check the destination registers match in addition to the source registers. Previously if the source match we asserted that the destination matched. But GPR <-> mask register copies on X86 can violate this since we use the same K-registers for multiple sizes. Fixes this ISPC issue https://github.com/ispc/ispc/issues/1851 Differential Revision: https://reviews.llvm.org/D86507 (cherry picked from commit 4783e2c9)
-
Nemanja Ivanovic authored
The test case in https://bugs.llvm.org/show_bug.cgi?id=47373 exposed two bugs in the PPC back end. The first one was fixed in commit 27714075 but the test case had to be added without -verify-machineinstrs due to the second bug. This commit fixes the use-after-kill that is left behind by the PPC MI peephole optimization. (cherry picked from commit 69289cc1)
-
Nemanja Ivanovic authored
Quite a while ago, we legalized these nodes as we added custom handling for reciprocal estimates in the back end. We have since moved to target-independent combines but neglected to turn off legalization. As a result, we can now get selection failures on non-VSX subtargets as evidenced in the listed PR. Fixes: https://bugs.llvm.org/show_bug.cgi?id=47373 (cherry picked from commit 27714075)
-
Fangrui Song authored
[GCDAProfiling] Suppress -Wprio-ctor-dtor for GCC>=9 and remove unused write_string/length_of_string The `__attribute__((destructor(100)))` diagnostic does not have a warning option in GCC 8 (before r264853) and thus cannot be suppressed. (cherry picked from commit 1cfde143)
-
Thomas Lively authored
Fixes PR47375, in which an assertion was triggering because WebAssemblyTargetLowering::isVectorLoadExtDesirable was improperly assuming the use of simple value types. Differential Revision: https://reviews.llvm.org/D87110 (cherry picked from commit caee15a0)
-
Dimitry Andric authored
Since the parameter is not used anywhere, and the default size of 16 apparently causes PR47359, remove it. This ensures that IntervalMap will automatically determine the optimal size, using its NodeSizer struct. Reviewed By: dblaikie Differential Revision: https://reviews.llvm.org/D87044 (cherry picked from commit f26fc568)
-
- Sep 05, 2020
-
-
Alex Bradbury authored
-
- Sep 02, 2020
-
-
Camille Coti authored
Fixed some version information in flang/f18: - fixed the behavior of the -v switch: this flag enables verbosity with used with arguments, but just displays the version when used alone (related to this bug: https://bugs.llvm.org/show_bug.cgi?id=46017) - added __FLANG, __FLANG_MAJOR__, __FLANG_MINOR__ and __FLANG_PATCHLEVEL__ (similar to their __F18* counterparts) for compatibility purpose Reviewed By: AlexisPerry, richard.barton.arm, tskeith Differential Revision: https://reviews.llvm.org/D84334 (cherry picked from commit b11c5278)
-
- Sep 01, 2020
-
-
Kang Zhang authored
Summary: PPC only supports the instruction selection for v16i8, v8i16, v4i32, v2i64, v4f32 and v2f64 for ISD::SETCC, don't support the v1i128, so v1i128 for ISD::SETCC will crash. This patch is to set v1i128 to expand to avoid crash. Reviewed By: steven.zhang Differential Revision: https://reviews.llvm.org/D84238 (cherry picked from commit 802c0430)
-
- Aug 31, 2020
-
-
Nikita Popov authored
Replace the check for poison-producing instructions in SimplifyWithOpReplaced() with the generic helper canCreatePoison() that properly handles poisonous shifts and thus avoids the problem from PR47322. This additionally fixes a bug in IIQ.UseInstrInfo=false mode, which previously could have caused this code to ignore poison flags. Setting UseInstrInfo=false should reduce the possible optimizations, not increase them. This is not a full solution to the problem, as poison could be introduced more indirectly. This is just a minimal, easy to backport fix. Differential Revision: https://reviews.llvm.org/D86834 (cherry picked from commit a5be86fd)
-
sameeran joshi authored
Solves issue https://reviews.llvm.org/D86131#2247275 Reviewed By: hans Differential Revision: https://reviews.llvm.org/D86875 (cherry picked from commit f787c9a9)
-
Brad Smith authored
(cherry picked from commit 4fbf0636)
-
Rainer Orth authored
Tests on Solaris/sparcv9 currently show about 250 failures when building with gcc, most of them like the following: FAIL: LLVM-Unit :: Support/./SupportTests/TaskQueueTest.UnOrderedFutures (4269 of 67884) ******************** TEST 'LLVM-Unit :: Support/./SupportTests/TaskQueueTest.UnOrderedFutures' FAILED ******************** Note: Google Test filter = TaskQueueTest.UnOrderedFutures [==========] Running 1 test from 1 test case. [----------] Global test environment set-up. [----------] 1 test from TaskQueueTest [ RUN ] TaskQueueTest.UnOrderedFutures 0 SupportTests 0x0000000100753b20 llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 32 1 SupportTests 0x0000000100752974 llvm::sys::RunSignalHandlers() + 68 2 SupportTests 0x0000000100752b18 SignalHandler(int) + 372 3 libc.so.1 0xffffffff7eedc800 __sighndlr + 12 4 libc.so.1 0xffffffff7eecf23c call_user_handler + 852 5 libc.so.1 0xffffffff7eecf594 sigacthandler + 84 6 SupportTests 0x00000001006f8cb8 std::thread::_State_impl<std::thread::_Invoker<std::tuple<llvm::ThreadPool::ThreadPool(llvm::ThreadPoolStrategy)::'lambda'()> > >::_M_run() + 512 7 libstdc++.so.6.0.28 0xfffffffc628117cc execute_native_thread_routine + 16 8 libc.so.1 0xffffffff7eedc6a0 _lwp_start + 0 Since it's effectively impossible to debug such a `SEGV` in a `Release` build, I tried a `Debug` build instead, only to find that the failures had gone away. Further investigation revealed that most of the issue centers around `llvm/lib/Support/ThreadPool.cpp`. That file is built with `-O3 -fPIC` in a `Release` build. The failure vanishes if - compiling without `-fPIC` - compiling with `-O -fPIC` - linking with GNU `ld` instead of Solaris `ld` It has meanwhile been determined that `gcc` doesn't correctly heed some TLS code sequences. To make things worse, Solaris `ld` doesn't properly validate its assumptions against the input, generating wrong code. `gld` like `gcc` is more liberal here and correctly deals with the code it gets fed from `gcc`. There's PR target/96607: GCC feeds SPARC/Solaris linker with unrecognized TLS sequences <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96607> now. An attempt to build with `-DLLVM_ENABLE_PIC=Off` initially failed since neither `libRemarks.so` (D85626 <https://reviews.llvm.org/D85626>) nor `LLVMPolly.so` (D85627 <https://reviews.llvm.org/D85627>) heed that option. Even with that fixed, a few codegen failures remain. Next I tried to build just `ThreadPool.cpp` with `-O -fPIC`. While that fixed the vast majority of the failures, 16 `LLVM :: CodeGen/X86` failures remained. Given that that solution was both incomplete and fragile, I went for building the whole tree with `-O -fPIC` for `Release` and `RelWithDebInfo` builds. As detailed in Bug 47304, 2-stage builds also show large numbers of failures when building with `-O3` or `-O2`, which are likewise worked around by building with `-O` until they are sufficiently analyzed and fixed. This way, all failures relative to a `Debug` build go away. Tested on `sparcv9-sun-solaris2.11`. Differential Revision: https://reviews.llvm.org/D85630 (cherry picked from commit 15c66b10)
-
QingShan Zhang authored
This is the follow up patch for https://reviews.llvm.org/D86183 as we miss to delete the node if NegX == NegY, which has use after we create the node. ``` if (NegX && (CostX <= CostY)) { Cost = std::min(CostX, CostZ); RemoveDeadNode(NegY); return DAG.getNode(Opcode, DL, VT, NegX, Y, NegZ, Flags); #<-- NegY is used here if NegY == NegX. } ``` Reviewed By: spatel Differential Revision: https://reviews.llvm.org/D86689 (cherry picked from commit deb4b258)
-
Kristof Beyls authored
-
Sameeran joshi authored
Need to build sphinx using below flags to Cmake `-DLLVM_ENABLE_SPHINX=ON -DSPHINX_WARNINGS_AS_ERRORS=OFF`. Generate html docs using cmake target `docs-flang-html` Generated html files should be at `build/tools/flang/docs/html`. Patch in series from the dicussion on review https://reviews.llvm.org/D85828 After this patch the markdown docmentation must be written using guide in- `llvm/docs/MarkdownQuickstartTemplate.md` Reviewed By: sscalpone Differential Revision: https://reviews.llvm.org/D86131 (cherry picked from commit bc9cdfa1)
-