- Mar 24, 2020
-
-
Sam McCall authored
Summary: This clears the way for adding an Error dependence bit to Type and having it mostly-automatically propagated. Reviewers: hokein Subscribers: jfb, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D76424
-
Benjamin Kramer authored
-
Simon Pilgrim authored
-
Russell Gallop authored
-
Simon Tatham authored
Summary: The next release of LLVM will support the full ACLE spec for MVE intrinsics, so it's worth saying so in the release notes. Reviewers: kristof.beyls Reviewed By: kristof.beyls Subscribers: cfe-commits, hans, dmgreen, llvm-commits Tags: #llvm, #clang Differential Revision: https://reviews.llvm.org/D76513
-
Lorenz Junglas authored
`parseDocumentation` retains hard line breaks and removes soft line breaks inside documentation comments. Wether a line break is hard or soft is determined by the following rules (some of which have been discussed in https://github.com/clangd/clangd/issues/95): Line breaks that are preceded by a punctuation are retained Line breaks that are followed by "interesting characters" (e.g. Markdown syntax, doxygen commands) are retained All other line breaks are removed Related issue: https://github.com/clangd/clangd/issues/95 Differential Revision: https://reviews.llvm.org/D76094
-
Raphael Isemann authored
This was triggering -Winconsistent-missing-override warnings.
-
Sam Parker authored
-
Simon Pilgrim authored
[UpdateTestChecks] Use common ir function name matcher and extend to accept periods in names (PR37586) Remove the local versions of the IR_FUNCTION_RE matcher (they weren't doing anything different), and ensure all the function name matchers accept '.' and '-'. We don't need to use '\.' inside python regex sets either, or '\-' as long as thats at the end of the set.
-
Dmitry Vyukov authored
realeaseAcquire() is a new function added to TSan in support of the Go data-race detector. It's semantics is: void ThreadClock::releaseAcquire(SyncClock *sc) const { for (int i = 0; i < kMaxThreads; i++) { tmp = clock[i]; clock[i] = max(clock[i], sc->clock[i]); sc->clock[i] = tmp; } } For context see: https://go-review.googlesource.com/c/go/+/220419 Reviewed-in: https://reviews.llvm.org/D76322 Author: dfava (Daniel Fava) -
Momchil Velikov authored
This patch adds CMSE attributes `cmse_nonsecure_call` and `cmse_nonsecure_entry`. As usual, specification is available here: https://developer.arm.com/docs/ecm0359818/latest Patch by Javed Absar, Bradley Smith, David Green, Momchil Velikov, possibly others. Differential Revision: https://reviews.llvm.org/D71129
-
David Green authored
We deliberately split stores of the form store(truncate(larger-than-legal-type)) into two stores, allowing each store to perform part of the truncate for free. There are times however where it makes more sense to use VMOVN to de-interlace the results back into a single vector, and store that in one go. This adds a check for that situation, not splitting the store if it looks like a VMOVN can be more useful. Differential Revision: https://reviews.llvm.org/D76511
-
Sam Parker authored
Modify ValidateLiveOuts to track 'FalseLaneZeros' more precisely, including checks on specific operations that can generate non-zeros from zero values, e.g VMVN. We can then check that any instructions that retain some information in their output register (all narrowing instructions) that they only use and def registers that always have zeros in their falsely predicated bytes, whether or not tail predication happens. Most of the logic remains the same, just the names of the data structures and helpers have been renamed to reflect the change in logic. The key change, apart from the opcode checkers, is that the FalseZeros set now strictly contains only instructions which will always generate zeros, and not instructions that could also have their false bytes masked away later. Differential Revision: https://reviews.llvm.org/D76235
-
Sam Parker authored
Add a flag, 'RetainsPreviousHalfElement', for operations that operate on top/bottom halves of their input and only write to half of their destination, leaving the other half to retain its previous value. Differential Revision: https://reviews.llvm.org/D76608
-
Haojian Wu authored
Normally clang avoids creating expressions when it encounters semantic errors, even if the parser knows which expression to produce. This works well for the compiler. However, this is not ideal for source-level tools that have to deal with broken code, e.g. clangd is not able to provide navigation features even for names that compiler knows how to resolve. The new RecoveryExpr aims to capture the minimal set of information useful for the tools that need to deal with incorrect code: source range of the expression being dropped, subexpressions of the expression. We aim to make constructing RecoveryExprs as simple as possible to ensure writing code to avoid dropping expressions is easy. Producing RecoveryExprs can result in new code paths being taken in the frontend. In particular, clang can produce some new diagnostics now and we aim to suppress bogus ones based on Expr::containsErrors. We deliberately produce RecoveryExprs only in the parser for now to minimize the code affected by this patch. Producing RecoveryExprs in Sema potentially allows to preserve more information (e.g. type of an expression), but also results in more code being affected. E.g. SFINAE checks will have to take presence of RecoveryExprs into account. Initial implementation only works in C++ mode, as it relies on compiler postponing diagnostics on dependent expressions. C and ObjC often do not do this, so they require more work to make sure we do not produce too many bogus diagnostics on the new expressions. See documentation of RecoveryExpr for more details. original patch from Ilya This change is based on https://reviews.llvm.org/D61722 Reviewers: sammccall, rsmith Reviewed By: sammccall, rsmith Tags: #clang Differential Revision: https://reviews.llvm.org/D69330
-
Walter Erquinigo authored
-
Chen Zheng authored
Implement target hook isProfitableToHoist - typo fix.
-
Douglas Yung authored
-
Jun Ma authored
coroutine frame Currently we move all allocas into the frame when build coroutine frame in CoroSplit pass. However, this can be relaxed. Since CoroSplit pass run after Inline pass, we can use lifetime intrinsic to do such analysis: If the scope of lifetime intrinsic is not across any suspend point, rather than move the allocas to frame, we can just move them to entry bb of corresponding function. This reduce the frame size. More importantly, this also avoid data race in multithread environment. Consider one inline function by coroutine: it starts a thread which access local variables, while after inline the movement of allocs to frame also access them. cause data race. Differential Revision: https://reviews.llvm.org/D75664
-
Jun Ma authored
Differential Revision: https://reviews.llvm.org/D76119
-
Vedant Kumar authored
PR35760 shows an example program which, when compiled with `clang -O0` or gcc at any optimization level, prints '0'. However, llvm transforms the program in a way that causes it to print '1'. Fix the issue by having `AllUsesOfValueWillTrapIfNull` return false when analyzing a load from a global which is used by an `icmp`. This special case was untested [0] so this is just deleting dead code. An alternative fix might be to change the GlobalStatus analysis for the global to report "Stored" instead of "StoredOnce". However, "StoredOnce" is appropriate when only one value other than the initializer is stored to the global. [0] http://lab.llvm.org:8080/coverage/coverage-reports/coverage/Users/buildslave/jenkins/workspace/coverage/llvm-project/llvm/lib/Transforms/IPO/GlobalOpt.cpp.html#L662 Differential Revision: https://reviews.llvm.org/D76645
-
Uday Bondhugula authored
- refactor to remove duplicate code - some renaming / comment updates for readability Signed-off-by:
Uday Bondhugula <uday@polymagelabs.com> Differential Revision: https://reviews.llvm.org/D76667
-
Douglas Yung authored
-
Pierre Habouzit authored
Some methods are sometimes declared in the @implementation blocks which can cause undiagnosed clashes. Just write a checkObjCDirectMethodClashes() for this purpose. Also make sure that "unavailable" selectors do not inherit objc_direct_members. Differential Revision: https://reviews.llvm.org/D76643 Signed-off-by:
Pierre Habouzit <phabouzit@apple.com> Radar-ID: rdar://problem/59332804, rdar://problem/59782963
-
Paula Toth authored
Summary: Add clang-tidy for llvm-libc source directory. Example of check in action: ``` /workspace/llvm-project/libc/src/string/strcpy.cpp:10:1: error: system include stdio.h not allowed [llvmlibc-restrict-system-libc-headers,-warnings-as-errors] #include <stdio.h> ^~~~~~~~~~~~~~~~~~ ``` Reviewers: sivachandra, abrachet Reviewed By: sivachandra, abrachet Subscribers: aheejin, MaskRay, tschuett, libc-commits Tags: #libc-project Differential Revision: https://reviews.llvm.org/D76559
-
Jinsong Ji authored
Add a new line, so that we always print MI in a new line, before and after UpdateRegMask, for easier check..
-
John McCall authored
The algorithm supports both assigning a fixed offset to a field prior to layout and allowing fields to have sizes that aren't multiples of their required alignments. This means that the well-known algorithm of sorting by decreasing alignment isn't always good enough. Still, we start with that, and only if that leaves padding around do we fall back on a greedy padding-minimizing algorithm. There is no known efficient algorithm for producing a guaranteed-minimal layout in all cases. In fact, allowing arbitrary fixed-offset fields means there's a straightforward reduction from bin-packing, making this NP-hard. But as usual with such problems, we can still efficiently produce adequate solutions to the cases that matter most to us. I intend to use this in coroutine frame layout, where the retcon lowerings very badly want to minimize total space usage, and where the switch lowering can indeed produce a header with interior padding if the promise field is highly-aligned. But it may be useful in a much wider variety of situations.
-
Uday Bondhugula authored
The declarations for these were already part of transforms utils, but the definitions were left in affine transforms. Move definitions to loop transforms utils. Signed-off-by:
Uday Bondhugula <uday@polymagelabs.com> Differential Revision: https://reviews.llvm.org/D76633
-
Walter Erquinigo authored
-
Uday Bondhugula authored
Improve comments, naming, and other cleanup Signed-off-by:
Uday Bondhugula <uday@polymagelabs.com> Differential Revision: https://reviews.llvm.org/D76616
-
aartbik authored
Summary: Makes the vector.tranpose runnable on CPU. Reviewers: nicolasvasilache, andydavis1, rriddle Reviewed By: nicolasvasilache Subscribers: mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, nicolasvasilache, arpith-jacob, mgester, lucyrfox, liufengdb, Joonsoo, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D76644
-
Jonas Devlieghere authored
Add a unit test for vfs::YAMLVFSWriter. This patch exposes an issue in the writer: when we call addFileMapping with a directory, the VFS writer will emit it as a regular file, causing any of the nested files or directories to not be found.
-
Peter Collingbourne authored
For MTE error reporting we will need to expose interfaces for crash handlers to use to interpret scudo headers and metadata. The intent is that these interfaces will live in scudo/interface.h. Move the existing interface.h into an include/scudo directory and make it independent of the internal headers, so that we will be able to add the interfaces there. Differential Revision: https://reviews.llvm.org/D76648
-
Walter Erquinigo authored
This reverts commit fd868f51.
-
Walter Erquinigo authored
-
Chris Lattner authored
Fix a bug in the .mlir lexer, where a \0 character in a file is treated as a colon (due to an accidental fall through) instead of whitespace. Summary: While here, simplify the lexer a bit by eliminating the unneeded 'operator' classification of certain sigils, they can just be treated as 'punctuation'. Reviewers: rriddle! Subscribers: mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, nicolasvasilache, arpith-jacob, mgester, lucyrfox, liufengdb, Joonsoo, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D76647
-
Johannes Doerfert authored
This should fix the issue reported here: https://reviews.llvm.org/D76058#1937554
-
Jessica Paquette authored
When we find something like this: ``` %a:_(s32) = G_SOMETHING ... ... %select:_(s32) = G_SELECT %cond(s1), %a, %a ``` We can remove the select and just replace it entirely with `%a` because it's always going to result in `%a`. Same if we have ``` %select:_(s32) = G_SELECT %cond(s1), %a, %b ``` where we can deduce that `%a == %b`. This implements the following cases: - `%select:_(s32) = G_SELECT %cond(s1), %a, %a` -> `%a` - `%select:_(s32) = G_SELECT %cond(s1), %a, %some_copy_from_a` -> `%a` - `%select:_(s32) = G_SELECT %cond(s1), %a, %b` -> `%a` when `%a` and `%b` are defined by identical instructions This gives a few minor code size improvements on CTMark at -O3 for AArch64. Differential Revision: https://reviews.llvm.org/D76523
-
Sam McCall authored
This feature is being added to LSP with a different (request-response) protocol in 3.16, so this should avoid some confusion.
-
Max Moroz authored
Reviewers: hctim, metzman Subscribers: dberris, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D76448
-