- Aug 18, 2020
-
-
Roman Lebedev authored
While x*undef is undef, shift-by-undef is poison, which we must avoid introducing. Also log2(iN undef) is *NOT* iN undef, because log2(iN undef) u< N. See https://bugs.llvm.org/show_bug.cgi?id=47133 (cherry picked from commit 12d93a27)
-
Dávid Bolvanský authored
Clang command line docs mention `-fno-stack-clash-protection`, and GCC also uses -fno-stack-clash-protection. Fixes PR47139 Reviewed By: tstellar Differential Revision: https://reviews.llvm.org/D85844 (cherry picked from commit df3bfaa3)
-
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: sscalpone, AlexisPerry, richard.barton.arm, tskeith Differential Revision: https://reviews.llvm.org/D84334 (cherry picked from commit 89a9db43)
-
Richard Barton authored
As expected by user in http://lists.llvm.org/pipermail/flang-dev/2020-June/000404.html Depends on D84856 Differential Revision: https://reviews.llvm.org/D84857 (cherry picked from commit 30e45f33)
-
Richard Barton authored
Add a usage string and a defaults section that clarifies: * If no input files are given, f18 reads from stdin * If no input files are given, f18 dumps the parse tree. * The default behaviour is to exec F18_FC. * The fefault F18_FC setting is 'gfortran' Adds a simple regression test which tests the top and tail of the help screen and the exit status. Depends on D84855 Differential Revision: https://reviews.llvm.org/D84856 (cherry picked from commit b068d19a)
-
Richard Barton authored
When flang is invoked with no files it waits for input on stdin. Make it print a message saying this to prevent the user being surprised. Differential Revision: https://reviews.llvm.org/D84855 (cherry picked from commit dd5ea567)
-
Camille Coti authored
When the f18 frontend calls the link editor, put the libraries and object files in the correct order. Fixes the issues reported here https://github.com/flang-compiler/flang/issues/897 Reviewed By: sscalpone, AlexisPerry Differential Revision: https://reviews.llvm.org/D84340 (cherry picked from commit ca0bf440)
-
AlexisPerry authored
fixes BUG 46307 Differential Revision: https://reviews.llvm.org/D84266 (cherry picked from commit 4a4cafab)
-
Chen Zheng authored
Reviewed By: lkail Differential Revision: https://reviews.llvm.org/D85659 (cherry picked from commit 4d52ebb9)
-
David Sherwood authored
The code wasn't taking into account that the two operands passed to ptest could be identical and was trying to erase them twice. Differential Revision: https://reviews.llvm.org/D85892 (cherry picked from commit 6c7957c9)
-
Hans Wennborg authored
By Tobias Hieta!
-
- Aug 17, 2020
-
-
David Blaikie authored
Introduced by fd6584a2 Following similar use of casts in AsmParser.cpp, for instance - ideally this type would use unsigned chars as they're more representative of raw data and don't get confused around implementation defined choices of char's signedness, but this is what it is & the signed/unsigned conversions are (so far as I understand) safe/bit preserving in this usage and what's intended, given the API design here. (cherry picked from commit e31cfc4c)
-
David Sherwood authored
Fixed an incorrect pattern in lib/Target/AArch64/AArch64SVEInstrInfo.td for storing out <vscale x 2 x f32> unpacked scalable vectors. Added a couple of tests to test/CodeGen/AArch64/sve-st1-addressing-mode-reg-imm.ll Differential Revision: https://reviews.llvm.org/D85441 (cherry picked from commit 0905d9f3)
-
Sander de Smalen authored
This fixes an issue triggered by the following code, where emitEpilogue got confused when trying to restore the SVE registers after the call, whereas the call to bar() is implemented as a TCReturn: int non_sve(); int sve(svint32_t x) { return non_sve(); } Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D84869 (cherry picked from commit f2916636) -
Sander de Smalen authored
This patch adds a CFI entry for each SVE callee saved register that needs unwind info at an offset from the CFA. The offset is a DWARF expression because the offset is partly scalable. The CFI entries only cover a subset of the SVE callee-saves and only encodes the lower 64-bits, thus implementing the lowest common denominator ABI. Existing unwinders may support VG but only restore the lower 64-bits. Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D84044 (cherry picked from commit bb3344c7)
-
Sander de Smalen authored
The CFA is calculated as (SP/FP + offset), but when there are SVE objects on the stack the SP offset is partly scalable and should instead be expressed as the DWARF expression: SP + offset + scalable_offset * VG where VG is the Vector Granule register, containing the number of 64bits 'granules' in a scalable vector. Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D84043 (cherry picked from commit fd6584a2) -
Martin Storsjö authored
-
- Aug 13, 2020
-
-
Richard Smith authored
an array of unknown bound as the initializer of an array new expression. (cherry picked from commit bd08e0cf)
-
- Aug 10, 2020
-
-
Sam McCall authored
-
Sam McCall authored
-
- Aug 08, 2020
-
-
Fangrui Song authored
tl;dr See D81784 for the 'tombstone value' concept. This patch changes our behavior to be almost the same as GNU ld (except that we also use 1 for .debug_loc): * .debug_ranges & .debug_loc: 1 (LLD<11: 0+addend; GNU ld uses 1 for .debug_ranges) * .debug_*: 0 (LLD<11: 0+addend; GNU ld uses 0; future LLD: -1) We make the tweaks because: 1) The new tombstone is novel and needs more time to be adopted by consumers before it's the default. 2) The old (gold) strategy had problems with zero-length functions - so rather than going back that, we're going to the GNU ld strategy which doesn't have that problem. 3) One slight tweak to (2) is to apply the .debug_ranges workaround to .debug_loc for the same reasons it applies to debug_ranges - to avoid terminating lists early. ----- http://lists.llvm.org/pipermail/llvm-dev/2020-July/143482.html The tombstone value -1 in .debug_line caused problems to lldb (fixed by D83957; will be included in 11.0.0) and breakpad (fixed by https://crrev.com/c/2321300). It may potentially affects other DWARF consumers. For .debug_ranges & .debug_loc: 1, an argument preferring 1 (GNU ld for .debug_ranges) over -2 is that: ``` {-1, -2} <<< base address selection entry {0, length} <<< address range ``` may create a situation where low_pc is greater than high_pc. So we use 1, the GNU ld behavior for .debug_ranges For other .debug_* sections, there haven't been many reports. One issue is that bloaty (src/dwarf.cc) can incorrectly count address ranges in .debug_ranges . To reduce similar disruption, this patch changes the tombstone values to be similar to GNU ld. This does mean another behavior change to the default trunk behavior. Sorry about it. The default trunk behavior will be similar to release/11.x while we work on a transition plan for LLD users. Reviewed By: dblaikie, echristo Differential Revision: https://reviews.llvm.org/D84825 (cherry picked from commit 004be403)
-
Petar Avramovic authored
Add given input and mark it as tied. Doesn't create additional copy compared to matching input constraint to virtual register. Differential Revision: https://reviews.llvm.org/D85122 (cherry picked from commit d893278b)
-
- Aug 06, 2020
-
-
Martin Storsjö authored
These might occur in seemingly generic assembly. Previously when targeting COFF, they were silently ignored, which certainly won't give the right result. Instead clearly error out, to make it clear that the assembly needs to be adjusted for this target. Also change a preexisting report_fatal_error into a proper error message, pointing out the offending source instruction. This isn't strictly an internal error, as it can be triggered by user input. Differential Revision: https://reviews.llvm.org/D85242 (cherry picked from commit f5e6fbac)
-
Chen Zheng authored
In fixupIsDeadOrKill, we assume StartMI and EndMI not exist in same basic block, so we add an assertion in that function. This is wrong before RA, as before RA the true definition may exist in another block through copy like instructions. Reviewed By: nemanjai Differential Revision: https://reviews.llvm.org/D83365 (cherry picked from commit 36f9fe2d)
-
Nathan James authored
See bug https://bugs.llvm.org/show_bug.cgi\?id\=46976 (cherry picked from commit 7c4782ce)
-
Martin Storsjö authored
This can practically easily be a product of combining strings with macros in resource files. This fixes https://github.com/mstorsjo/llvm-mingw/issues/140. As string literals within llvm-rc are handled as StringRefs, each referencing an uninterpreted slice of the input file, with actual interpretation of the input string (codepage handling, unescaping etc) done only right before writing them out to disk, it's hard to concatenate them other than just bundling them up in a vector, without rearchitecting a large part of llvm-rc. This matches how the same already is supported in VersionInfoValue, with a std::vector<IntOrString> Values. MS rc.exe only supports concatenated string literals in version info values (already supported), string tables (implemented in this patch) and user data resources (easily implemented in a separate patch, but hasn't been requested by any end user yet), while GNU windres supports string immediates split into multiple strings anywhere (e.g. like (100 ICON "myicon" ".ico"). Not sure if concatenation in other statements actually is used in the wild though, in resource files normally built by GNU windres. Differential Revision: https://reviews.llvm.org/D85183 (cherry picked from commit b989fcba)
-
Peiyuan Song authored
Differential Revision: https://reviews.llvm.org/D84757 (cherry picked from commit 14c1b401)
-
Hans Wennborg authored
This fixes the ExecutionEngine/MCJIT/stubs-sm-pic.ll test in no-asserts builds which is set to XFAIL on some platforms like 32-bit x86. More importantly, we probably don't want to silently error in these cases. Differential revision: https://reviews.llvm.org/D84390 (cherry picked from commit 6a3b07a4)
-
AndreyChurbanov authored
Patch by mati865@gmail.com Differential Revision: https://reviews.llvm.org/D85210 (cherry picked from commit 4a04bc89)
-
Adrian Pop authored
RTM Adaptive Locks are supported on msys2/mingw for clang and gcc. Differential Revision: https://reviews.llvm.org/D81776 (cherry picked from commit bf2aa74e)
-
- Aug 05, 2020
-
-
Jonas Devlieghere authored
This fixes the modules build. (cherry picked from commit 1b3c25e7)
-
Hans Wennborg authored
-
- Aug 03, 2020
-
-
Changpeng Fang authored
Summary: This is in response to the review of https://reviews.llvm.org/D84873: The expensive check should be reordered last Reviewers: arsenm Differential Revision: https://reviews.llvm.org/D84890 (cherry picked from commit 243376cd)
-
Michał Górny authored
BUG_REPORT_URL is currently used both in LLVM and in Clang but declared only in the latter. This means that it's missing in standalone clang builds and the driver ends up outputting: PLEASE submit a bug report to and include [...] (note the missing URL) To fix this, include LLVM_PACKAGE_BUGREPORT in LLVMConfig.cmake (similarly to how we pass PACKAGE_VERSION) and use it to fill BUG_REPORT_URL when building clang standalone. Differential Revision: https://reviews.llvm.org/D84987 (cherry picked from commit 21c165de)
-
Florian Hahn authored
Currently we skip alias sets with only reads or a single write and no reads, but still add the pointers to the list of pointers in RtCheck. This can lead to cases where we try to access a pointer that does not exist when grouping checks. In most cases, the way we access PositionMap masked that, as the value would default to index 0. But in the example in PR46854 it causes a crash. This patch updates the logic to avoid adding pointers for alias sets that do not need any checks. It makes things slightly more verbose, by first checking the numbers of reads/writes and bailing out early if we don't need checks for the alias set. I think this makes the logic a bit simpler to follow. Reviewed By: anemet Differential Revision: https://reviews.llvm.org/D84608 (cherry picked from commit 2062b370)
-
Brendon Cahoon authored
In cases where the alignment of the datatype is smaller than expected by the instruction, the address is aligned. The aligned address is used for the load, but wasn't used for the store conditional, which resulted in a run-time alignment exception. (cherry picked from commit 7b114446)
-
Haojian Wu authored
`TemplateTypeParmDecl::hasTypeConstraint` is not a safe guard for checking `TemplateTypeParmDecl::getTypeConstraint()` result is null. in somecases (e.g. implicit deduction guide templates synthesized from the constructor, immediately-declared constraint is not formed because of an error), hasTypeConstraint returns false, and getTypeConstraint returns a nullptr. Fix https://bugs.llvm.org/show_bug.cgi?id=46790 Differential Revision: https://reviews.llvm.org/D84455 (cherry picked from commit 73c12bd8)
-
Aleksandr Platonov authored
Without this patch the word occurrence search always returns the first token of the file. Despite of that, `findNeardyIdentifier()` returns the correct result (but inefficently) until there are several matched tokens with the same value `floor(log2(<token line> - <word line>))` (e.g. several matched tokens on the same line). Reviewed By: kadircet Differential Revision: https://reviews.llvm.org/D84912 (cherry picked from commit 05b17346)
-
Fangrui Song authored
(cherry picked from commit ed7bde0e)
-
- Aug 01, 2020
-
-
Balazs Benics authored
It turned out that the D78704 included a private LLVM header, which is excluded from the LLVM install target. I'm substituting that `#include` with the public one by moving the necessary `#define` into that. There was a discussion about this at D78704 and on the cfe-dev mailing list. I'm also placing a note to remind others of this pitfall. Reviewed By: mgorny Differential Revision: https://reviews.llvm.org/D84929 (cherry picked from commit 63d3aeb5)
-