- Feb 26, 2020
-
-
Jay Foad authored
Reviewers: arsenm, rampitec Subscribers: kzhuravl, jvesely, wdng, nhaehnle, yaxunl, rovka, dstuttard, tpr, t-tye, hiraditya, kerbowa, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D75108
-
- Feb 25, 2020
-
-
Fangrui Song authored
Fixes https://bugs.llvm.org/show_bug.cgi?id=44450 https://sourceware.org/binutils/docs/ld/Input-Section-Basics.html#Input-Section-Basics The following two rules are not implemented. * `archive:` matches every file in the archive. * `:file` matches a file not in an archive. Reviewed By: grimar, ruiu Differential Revision: https://reviews.llvm.org/D75100
-
Haojian Wu authored
Summary: This fixes a clangd rename issue, which is missing the reference of an incomplete specialization. Unfortunately, I didn't reproduce this issue in clang-rename, I guess the input `FoundDecl` of AdditionalUSRFinder is different in clangd vs clang-rename, clang-rename uses the underlying CXXRecordDecl of the ClassTemplateDecl, which is fixed in https://github.com/llvm/llvm-project/commit/5d862c042b52ae2aad37471d0b83b6c678a520e3; while clangd-rename uses the ClassTemplateDecl. Reviewers: kbobyrev Reviewed By: kbobyrev Subscribers: ilya-biryukov, jkorous, arphaman, kadircet, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D74829
-
Artem Dergachev authored
So far we've been dropping coverage every time we've encountered a CXXInheritedCtorInitExpr. This patch attempts to add some initial support for it. Constructors for arguments of a CXXInheritedCtorInitExpr are still not fully supported. Differential Revision: https://reviews.llvm.org/D74735
-
Pavel Labath authored
Summary: This patch if motivated by D74560, specifically the subthread about what to print upon encountering reserved initial length values. If the debug_line prologue has an unsupported version, we skip parsing the rest of the data. If we encounter an reserved initial length field, we don't even parse the version. However, we still print out all members (with value 0) in the dump function. This patch introduces early exits in the Prologue::dump function so that we print only the fields that were parsed successfully. In case of an unsupported version, we skip printing all subsequent prologue fields -- because we don't even know if this version has those fields. In case of a reserved unit length, we don't print anything -- if the very first field of the prologue is invalid, it's hard to say if we even have a prologue to begin with. Note that the user will still be able to see the invalid/reserved initial length value in the error message. I've modified (reordered) debug_line_invalid.test to show that the error message comes straight after the debug_line offset. I've also added some flush() calls to the dumping code to ensure this is the case in all situations (without that, the warnings could get out of sync if the output was not a terminal -- I guess this is why std::iostreams have the tie() function). Reviewers: jhenderson, ikudrin, dblaikie Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D75043
-
Ayke van Laethem authored
AVR usually uses two byte addresses. By making DataExtractor deal with this, it is possible to load AVR binaries that don't have debug info associated with them. Differential Revision: https://reviews.llvm.org/D73969
-
Roman Lebedev authored
Much like with reassociateShiftAmtsOfTwoSameDirectionShifts(), as input, we have the following pattern: icmp eq/ne (and ((x shift Q), (y oppositeshift K))), 0 We want to rewrite that as: icmp eq/ne (and (x shift (Q+K)), y), 0 iff (Q+K) u< bitwidth(x) While we know that originally (Q+K) would not overflow (because 2 * (N-1) u<= iN -1), we may have looked past extensions of shift amounts. so it may now overflow in smaller bitwidth. To ensure that does not happen, we need to ensure that the total maximal shift amount is still representable in that smaller bitwidth. If the overflow would happen, (Q+K) u< bitwidth(x) check would be bogus. https://bugs.llvm.org/show_bug.cgi?id=44802
-
-
Roman Lebedev authored
As input, we have the following pattern: Sh0 (Sh1 X, Q), K We want to rewrite that as: Sh x, (Q+K) iff (Q+K) u< bitwidth(x) While we know that originally (Q+K) would not overflow (because 2 * (N-1) u<= iN -1), we may have looked past extensions of shift amounts. so it may now overflow in smaller bitwidth. To ensure that does not happen, we need to ensure that the total maximal shift amount is still representable in that smaller bitwidth. If the overflow would happen, (Q+K) u< bitwidth(x) check would be bogus. https://bugs.llvm.org/show_bug.cgi?id=44802
-
-
Benjamin Kramer authored
-
Jay Foad authored
[AMDGPU] Precommit some test updates for D68338 "Remove dubious logic in bidirectional list scheduler"
-
Nico Weber authored
This flag is like /showIncludes, but it only includes user headers and omits system headers (similar to MD and MMD). The motivation is that projects that already track system includes though other means can use this flag to get consistent behavior on Windows and non-Windows, and it saves tools that output /showIncludes output (e.g. ninja) some work. implementation-wise, this makes `HeaderIncludesCallback` honor the existing `IncludeSystemHeaders` bit, and changes the three clients of `HeaderIncludesCallback` (`/showIncludes`, `-H`, `CC_PRINT_HEADERS=1`) to pass `-sys-header-deps` to set that bit -- except for `/showIncludes:user`, which doesn't pass it. Differential Revision: https://reviews.llvm.org/D75093
-
Kristóf Umann authored
Exactly what it says on the tin! I decided not to merge this with the patch that changes all these to a CallDescriptionMap object, so the patch is that much more trivial. Differential Revision: https://reviews.llvm.org/D68163
-
Kadir Cetinkaya authored
Summary: Also fixes a bug, resulting from directly using ND.getEndLoc() for end location of the range. As ND.getEndLoc() points to the begining of the last token, whereas it should point one past the end, since LSP ranges are half open (exclusive on the end). Reviewers: sammccall Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D74850
-
Joerg Sonnenberger authored
-
Kelvin Li authored
Differential Revision: https://reviews.llvm.org/D75001
-
Jonathan Coe authored
Summary: Ensure that auto-implemented properties `{ get; private set }` are wrapped on to one line for C# code. Reviewers: MyDeveloperDay, krasimir Reviewed By: MyDeveloperDay, krasimir Subscribers: cfe-commits Tags: #clang-format, #clang Differential Revision: https://reviews.llvm.org/D75006 -
Hans Wennborg authored
No functionality change (intended), but this seems to make the code a bit clearer for the compiler and maybe for human readers too.
-
Luís Marques authored
D68391 added tests that check scenarios where no RISC-V GCC toolchain is supposed to be detected. When running the tests on RISC-V hosts the system's GCC toolchain will be detected, and the tests will fail. This patch adds a `--gcc-toolchain` option pointing to a path where no GCC toolchain is present, ensuring that the tests are run under the expected conditions, and therefore are able to pass in all test environments. Differential Revision: https://reviews.llvm.org/D75061
-
Alex Zinenko authored
The documentation was describing an obsolete version of the transformation.
-
Sanjay Patel authored
There's already a FIXME note on this file; it can break when the underlying LLVM behavior changes independently of anything in clang.
-
Sanjay Patel authored
-
Adam Balogh authored
Currently, using negative numbers in iterator operations (additions and subractions) results in advancements with huge positive numbers due to an error. This patch fixes it. Differential Revision: https://reviews.llvm.org/D74760
-
Balázs Kéri authored
Reviewers: martong, a.sidorin, shafik Reviewed By: martong Subscribers: rnkovacs, dkrupp, Szelethus, gamesh411, teemperor, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D74720
-
Sanjay Patel authored
-
Sanjay Patel authored
Code duplication (subsequently removed by refactoring) allowed a logic discrepancy to creep in here. We were being conservative about creating a vector binop -- but not a vector cmp -- in the case where a vector op has the same estimated cost as the scalar op. We want to be more aggressive here because that can allow other combines based on reduced instruction count/uses. We can reverse the transform in DAGCombiner (potentially with a more accurate cost model) if this causes regressions. AFAIK, this does not conflict with InstCombine. We have a scalarize transform there, but it relies on finding a constant operand or a matching insertelement, so that means it eliminates an extractelement from the sequence (so we won't have 2 extracts by the time we get here if InstCombine succeeds). Differential Revision: https://reviews.llvm.org/D75062
-
Florian Hahn authored
We have to skip MemoryDefs that cannot be removed. This fixes a crash in the newly added test case and fixes a wrong case in memset-and-memcpy.ll.
-
Stephan Herhut authored
Summary: The original patch had TODOs to add support for step computations, which this commit addresses. The computations are expressed using affine expressions so that the affine canonicalizers can simplify the full bound and index computations. Also cleans up the code a little and exposes the pass in the header file. Differential Revision: https://reviews.llvm.org/D75052
-
Alex Zinenko authored
AffineOps dialect lives under lib/Dialect/AffineOps and so should its tests.
-
Jeremy Morse authored
On Windows, an error running the debugger typically leaves a process hanging around in the working directory. When Dexter exits, it can't then delete the working directory and produces an exception, masking the problem in the debugger. (This can be worked around by specifying --save-temps). Rather than hard-erroring, print a warning when we can't delete the working directory instead. It'd be much better to improve our error handling, and make the WorkingDirectory class aware that something's wrong when it enters exit. However, this is something that's going to mask genuine errors and make everyones lives harder right now, so I think this non-ideal fix is important to get in first. Differential Revision: https://reviews.llvm.org/D74548
-
Raphael Isemann authored
-
Raphael Isemann authored
This member is for some reason initialized in ClangASTSource::FindExternalVisibleDecls so all other functions using this member dereference a nullptr unless we call this function before that. Let's just initialize this in the constructor. This should be NFC as the only side effect is that we don't reset the namespace map when calling ClangASTSource::FindExternalVisibleDecls multiple times (and we never call this function multiple times for one NameSearchContext from what I can see).
-
Nico Weber authored
-
whitequark authored
-
Raphael Isemann authored
The size of NameSearchContext isn't important as we never store it and rarely allocate more than a few. This way we also don't have to use the memset to initialize these fields to zero.
-
Raphael Isemann authored
The class is large enough to be in its own file. This patch also removes the cyclic dependency between ClangASTSource <-> NameSearchContext.
-
Kadir Cetinkaya authored
Summary: Currently extract variable doesn't spell the type explicitly and just uses an `auto` instead, which is not available in C. Reviewers: usaxena95 Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D75053
-
Hans Wennborg authored
Now that the Windows installer no longer does anything besides self-extract, maybe it would make sense to distribute the toolchain as a plain zip file in addition to the current installer. Differential revision: https://reviews.llvm.org/D74896
-
Stephan Herhut authored
I forward declared mlir::Region as a struct by mistake :(
-