summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [NFC] [PowerPC] Update mi-peephole-splat testQiu Chaofan2020-01-111-23/+115
| | | | | Use script to re-generate the test case, for easier comparison with future patches.
* [SCEV] [NFC] add more test cases for range of addrecexpr with nsw flagZheng Chen2020-01-101-4/+65
|
* [TargetLowering][ARM][Mips][WebAssembly] Remove the ordered FP compare from ↵Craig Topper2020-01-107-31/+7
| | | | | | | | | | | | | | | | | | | RunttimeLibcalls.def and all associated usages Summary: This always just used the same libcall as unordered, but the comparison predicate was different. This change appears to have been made when targets were given the ability to override the predicates. Before that they were hardcoded into the type legalizer. At that time we never inverted predicates and we handled ugt/ult/uge/ule compares by emitting an unordered check ORed with a ogt/olt/oge/ole checks. So only ordered needed an inverted predicate. Later ugt/ult/uge/ule were optimized to only call a single libcall and invert the compare. This patch removes the ordered entries and just uses the inverting logic that is now present. This removes some odd things in both the Mips and WebAssembly code. Reviewers: efriedma, ABataev, uweigand, cameron.mcinally, kpn Reviewed By: efriedma Subscribers: dschuff, sdardis, sbc100, arichardson, jgravelle-google, kristof.beyls, hiraditya, aheejin, sunfish, atanasyan, Petar.Avramovic, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D72536
* [COFF] Align ARM64 range extension thunks at instruction boundaryTom Tan2020-01-102-3/+19
| | | | | | | | | | | | | | | RangeExtensionThunkARM64 is created for out-of-range branches on Windows ARM64 because branch instructions has limited bits to encode target address. Currently, RangeExtensionThunkARM64 is appended to its referencing COFF section from object file at link time without any alignment requirement, so if size of the preceding COFF section is not aligned to instruction boundary (4 bytes), RangeExtensionThunkARM64 will emit thunk instructions at unaligned address which is never a valid branch target on ARM64, and usually triggers invalid instruction exception when branching to it. This PR fixes it by requiring such thunks to align at 4 bytes. Differential revision: https://reviews.llvm.org/D72473
* Remove umask testsAlexandre Ganea2020-01-102-25/+0
| | | | | | | These tests were added in 18627115f4d2db5dc73207e0b5312f52536be7dd and e08b59f81d950bd5c8b8528fcb3ac4230c7b736c for validating a refactoring. Removing because they break on ACL-controlled folders on Ubuntu, and their added value is low. Differential Revision: https://reviews.llvm.org/D70854
* [Concepts] Fix MarkUsedTemplateParameters for exprsSaar Raz2020-01-111-25/+20
| | | | | | D41910 introduced a recursive visitor to MarkUsedTemplateParameters, but disregarded the 'Depth' parameter, and had incorrect assertions. This fixes the visitor and removes the assertions.
* [Driver] Fix OptionClass of -fconvergent-functions and -fms-volatile (Joined ↵Fangrui Song2020-01-101-2/+2
| | | | -> Flag)
* driver: Allow -fdebug-compilation-dir=foo in joined form.Nico Weber2020-01-107-4/+19
| | | | | | | All 130+ f_Group flags that take an argument allow it after a '=', except for fdebug-complation-dir. Add a Joined<> alias so that it behaves consistently with all the other f_Group flags. (Keep the old Separate flag for backwards compat.)
* Clean up and slightly generalize implementation of composite pointerRichard Smith2020-01-103-126/+245
| | | | | | | | | | | type computation, in preparation for P0388R4, which adds another few cases here. We now properly handle forming multi-level composite pointer types involving nested Objective-C pointer types (as is consistent with including them as part of the notion of 'similar types' on which this rule is based). We no longer lose non-CVR qualifiers on nested pointer types.
* Add a FIXME and corresponding test coverage for some suspicious behaviorRichard Smith2020-01-103-0/+33
| | | | forming composite ObjC pointer types in comparisons.
* Remove redundant implicit cast creation.Richard Smith2020-01-101-2/+0
| | | | | FindCompositePointerType has already cast the operands to the composite type for us in the case where it succeeds.
* [AArch64] Don't generate libcalls for wide shifts on DarwinJessica Paquette2020-01-102-1/+6
| | | | | | | Similar to cff90f07cb5cc3. Darwin doesn't always use compiler-rt, and so we can't assume that these functions are available (at least on arm64).
* Improve precision of documentation comment.Richard Smith2020-01-101-2/+2
|
* [mlir][ods] Support dialect specific content emission via hooksLei Zhang2020-01-103-7/+81
| | | | | | | | | | | | | Thus far we can only generate the same set of methods even for operations in different dialects. This is problematic for dialects that want to generate additional operation class methods programmatically, e.g., a special builder method or attribute getter method. Apparently we cannot update the OpDefinitionsGen backend every time when such a need arises. So this CL introduces a hook into the OpDefinitionsGen backend to allow dialects to emit additional methods and traits to operation classes. Differential Revision: https://reviews.llvm.org/D72514
* [mlir] NFC: put C++ code emission classes in their own filesLei Zhang2020-01-104-340/+408
| | | | | | This exposes thse classes so that they can be used in interfaces. Differential Revision: https://reviews.llvm.org/D72514
* [NFC][InlineCost] Factor cost modeling out of CallAnalyzer traversal.Mircea Trofin2020-01-101-328/+431
| | | | | | | | | | | | | | | | | | Summary: The goal is to simplify experimentation on the cost model. Today, CallAnalyzer decides 2 things: legality, and benefit. The refactoring keeps legality assessment in CallAnalyzer, and factors benefit evaluation out, as an extension. Reviewers: davidxl, eraman Reviewed By: davidxl Subscribers: kamleshbhalui, fedor.sergeev, hiraditya, baloghadamsoftware, haicheng, a.sidorin, Szelethus, donat.nagy, dkrupp, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D71733
* [LockFileManager] Make default waitForUnlock timeout a parameter, NFCVedant Kumar2020-01-102-5/+5
| | | | Patch by Xi Ge!
* Only destroy static locals if they have non-trivial destructors.Richard Smith2020-01-102-1/+14
| | | | | | | This fixes a regression introduced in 2b4fa5348ee157b6b1a1af44d0137ca8c7a71573 that caused us to emit shutdown-time destruction for variables with ARC ownership, using C++-specific functions that don't exist in C implementations.
* [lldb/Reproducer] Add SBReproducer::Replay overload (again)Jonas Devlieghere2020-01-102-1/+6
| | | | | | | I modified the SBAPI under the assumption that nobody was using the old API yet. However, that turns out to be false. So instead of adding the deafault argument I've reintroduced the old API and made the new one an overload.
* Let targets adjust operand latency of bundlesStanislav Mekhanoshin2020-01-104-42/+34
| | | | | | | | | | | This reverts the AMDGPU DAG mutation implemented in D72487 and gives a more general way of adjusting BUNDLE operand latency. It also replaces FixBundleLatencyMutation with adjustSchedDependency callback in the AMDGPU, fixing not only successor latencies but predecessors' as well. Differential Revision: https://reviews.llvm.org/D72535
* lldbutil: Forward ASan launch info to test inferiorsVedant Kumar2020-01-102-1/+14
| | | | | | | | | This allows an unsanitized test process which loads a sanitized DSO (the motivating example is a Swift runtime dylib) to launch on Darwin. rdar://57290132 Differential Revision: https://reviews.llvm.org/D71379
* [lldb/Utils] Remove vim-lldbJonas Devlieghere2020-01-109-1834/+0
| | | | | | | | | The vim-lldb plugin is unmaintained and doesn't work with a recent vim installation that uses Python 3. This removes it from the LLDB repository. The code is still available under lldb-tools on GitHub like we did with for lldb-mi. (https://github.com/lldb-tools/vim-lldb) Differential revision: https://reviews.llvm.org/D72541
* [lldb/Test] Bypass LLDB_TEST_COMMON_ARGS for certain dotest args (NFC)Jonas Devlieghere2020-01-104-15/+39
| | | | | | | | Rather than serializing every argument through LLDB_TEST_COMMON_ARGS, we can pass some of them directly using their CMake variable. Although this does introduce some code duplication between lit's site config and the lldb-dotest utility, it also means that it becomes easier to override these values (WIP).
* [AArch64] Add isAuthenticated predicate to MCInstDescVedant Kumar2020-01-109-6/+61
| | | | | | | | | | Add a predicate to MCInstDesc that allows tools to determine whether an instruction authenticates a pointer. This can be used by diagnostic tools to hint at pointer authentication failures. Differential Revision: https://reviews.llvm.org/D70329 rdar://55089604
* [lldb/Scripts] Move android script from underneath Python dirJonas Devlieghere2020-01-102-26/+0
| | | | | The scripts root directory already contains python scripts. No need to keep this one nested under a dedicated Python directory.
* [lldb/Scripts] Remove remote-build.pyJonas Devlieghere2020-01-101-312/+0
| | | | With Xcode gone this is no longer relevant.
* [lldb/Scripts] Remove buildbot.pyJonas Devlieghere2020-01-101-196/+0
| | | | | This file is outdated and still references SVN. Buildbots are configured through the zorg repository.
* Summary: update macro for OFF_T so that sanitizer works on AARCH64.Lirong Yuan2020-01-105-12/+5
| | | | | | | | | | | | Reviewers: vitalybuka, eugenis, MaskRay Reviewed By: eugenis, MaskRay Subscribers: MaskRay, kristof.beyls, #sanitizers, llvm-commits, jkz, scw Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D72367
* clang-tidy doc: unbreak the CISylvestre Ledru2020-01-101-0/+2
|
* [TargetLowering] Use SelectionDAG::getSetCC and remove a repeated call to ↵Craig Topper2020-01-101-8/+4
| | | | getSetCCResultType in softenSetCCOperands. NFCI
* clang-tidy doc: Refresh the list of checkers and polish the scriptSylvestre Ledru2020-01-102-33/+28
|
* MakeUniqueCheck.cpp: explicit the fact that there is an autofix for this checkerSylvestre Ledru2020-01-101-0/+2
|
* Implement new AST matcher hasAnyCapture to match on LambdaExpr captures.Reid2020-01-104-0/+97
| | | | Accepts child matchers cxxThisExpr to match on capture of this and also on varDecl.
* [lldb] Fix TestClangASTContext.TestFunctionTemplateInRecordConstruction in ↵Raphael Isemann2020-01-101-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | Debug builds Summary: In Debug builds we call VerifyDecl in ClangASTContext::CreateFunctionDeclaration which in turn calls `getAccess` on the created FunctionDecl. As we passed in a RecordDecl as the DeclContext for the FunctionDecl, we end up hitting the assert in `getAccess` that checks that we never have a Decl inside a Record without a valid AccessSpecifier. FunctionDecls are never in RecordDecls (that would be a CXXMethodDecl) so setting a access specifier would not be the correct way to fix this. Instead this patch does the same thing that DWARFASTParserClang::ParseSubroutine is doing: We pass in the FunctionDecl with the TranslationUnit as the DeclContext. That's not ideal but it is how we currently do it when creating our debug info AST, so the unit test should do the same. Reviewers: shafik Reviewed By: shafik Subscribers: aprantl, JDevlieghere, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D72359
* [lldb] Make CompleteTagDeclsScope completion order deterministicRaphael Isemann2020-01-101-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | Summary: We iterate over `m_decls_to_complete` to complete declarations. As `m_decls_to_complete` is a set the iteration order can be non-deterministic. The order is currently only non-deterministic when we have a large set of decls that need to be completed (i.e. more than 32 decls, as otherwise the SmallPtrSet is just a linear-searched list). This doesn't really fix any specific bug or has any really observable change in behavior as the order in which we import should not influence any semantics. However the order we create decls/types is now always deterministic which should make debugging easier. Reviewers: labath, mib, shafik, davide Reviewed By: shafik, davide Subscribers: davide, abidh, JDevlieghere, lldb-commits, mgrang Tags: #lldb Differential Revision: https://reviews.llvm.org/D72495
* [Tests] Precommit tests showing default branch padding on skylakePhilip Reames2020-01-102-0/+75
| | | | A follow up patch will change the default for the compiler, but not the assembler, just making sure we have testing for each in place.
* [ASTMatchers] Make test more clear about what it is verifyingStephen Kelly2020-01-101-2/+5
|
* [Driver][PowerPC] Move powerpcspe logic from cc1 to DriverFangrui Song2020-01-104-4/+8
| | | | | | | | | Follow-up of D72014. It is more appropriate to use a target feature instead of a SubTypeArch to express the difference. Reviewed By: #powerpc, jhibbits Differential Revision: https://reviews.llvm.org/D72433
* [clang] Fix out-of-bounds memory access in ComputeLineNumbersJan Korous2020-01-102-13/+32
| | | | Differential Revision: https://reviews.llvm.org/D72409
* [CMake] Fix modules build after DWARFLinker reorganizationJonas Devlieghere2020-01-102-0/+9
| | | | | Create a dedicate module for the DWARFLinker and make it depend on intrinsics gen.
* [lld][WebAssembly] Add libcall symbols to the link when LTO is being used.Sam Clegg2020-01-106-0/+74
| | | | | | | | | | | | | | | This code is copied almost verbatim from the equivalent change to the ELF linker: - https://reviews.llvm.org/D50017 - https://reviews.llvm.org/D50475 The upshot is that libraries containing libcall (such as compiler-rt and libc) can be compiled with LTO. Fixes PR41384 Differential Revision: https://reviews.llvm.org/D71738
* [TargetLowering][ARM][X86] Change softenSetCCOperands handling of ONE to ↵Craig Topper2020-01-105-35/+36
| | | | | | | | | | | | avoid spurious exceptions for QNANs with strict FP quiet compares ONE is currently softened to OGT | OLT. But the libcalls for OGT and OLT libcalls will trigger an exception for QNAN. At least for X86 with libgcc. UEQ on the other hand uses UO | OEQ. The UO and OEQ libcalls will not trigger an exception for QNAN. This patch changes ONE to use the inverse of the UEQ lowering. So we now produce O & UNE. Technically the existing behavior was correct for a signalling ONE, but since I don't know how to generate one of those from clang that seemed like something we can deal with later as we would need to fix other predicates as well. Also removing spurious exceptions seemed better than missing an exception. There are also problems with quiet OGT/OLT/OLE/OGE, but those are harder to fix. Differential Revision: https://reviews.llvm.org/D72477
* [analyzer] Move PlacementNewChecker to alphaGabor Marton2020-01-103-8/+8
|
* Update the attribution policy to use the 'Author' property of a git commitDaniel Sanders2020-01-101-7/+19
| | | | | | | | | | | | | | | Summary: The older method of adding 'Patch by John Doe' is documented in the `Attribution of Changes` section to support correct attribution of commits that pre-date the adoption of git. Reviewers: hfinkel, aaron.ballman, mehdi_amini Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D72468
* [lldb/Lua] Support loading Lua modulesJonas Devlieghere2020-01-106-0/+69
| | | | | | Implements the command script import command for Lua. Differential revision: https://reviews.llvm.org/D71825
* [lldb] Remove FieldDecl stealing hack by rerouting indirect imports to the ↵Raphael Isemann2020-01-102-14/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | original AST Summary: This is a port of D67803 that was about preventing indirect importing to our scratch context when evaluating expressions. D67803 already has a pretty long explanation of how this works, but the idea is that instead of importing declarations indirectly over the expression AST (i.e., Debug info AST -> Expression AST -> scratch AST) we instead directly import the declaration from the debug info AST to the scratch AST. The difference from D67803 is that here we have to do this in the ASTImporterDelegate (which is our ASTImporter subclass we use in LLDB). It has the same information as the ExternalASTMerger in D67803 as it can access the ClangASTImporter (which also keeps track of where Decls originally came from). With this patch we can also delete the FieldDecl stealing hack in the ClangASTSource (this was only necessary as the indirect imports caused the creation of duplicate Record declarations but we needed the fields in the Record decl we originally found in the scratch ASTContext). This also fixes the current gmodules failures where we fail to find std::vector fields after an indirect import over the expression AST (where it seems even our FieldDecl stealing hack can't save us from). Reviewers: shafik, aprantl Reviewed By: shafik Subscribers: JDevlieghere, lldb-commits, mib, labath, friss Tags: #lldb Differential Revision: https://reviews.llvm.org/D72507
* [LegalizeVectorOps] Improve handling of multi-result operations.Craig Topper2020-01-102-173/+307
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This system wasn't very well designed for multi-result nodes. As a consequence they weren't consistently registered in the LegalizedNodes map leading to nodes being revisited for different results. I've removed the "Result" variable from the main LegalizeOp method and used a SDNode* instead. The result number from the incoming Op SDValue is only used for deciding which result to return to the caller. When LegalizeOp is called it should always register a legalized result for all of its results. Future calls for any other result should be pulled for the LegalizedNodes map. Legal nodes will now register all of their results in the map instead of just the one we were called for. The Expand and Promote handling to use a vector of results similar to LegalizeDAG. Each of the new results is then re-legalized and logged in the LegalizedNodes map for all of the Results for the node being legalized. None of the handles register their own results now. And none call ReplaceAllUsesOfValueWith now. Custom handling now always passes result number 0 to LowerOperation. This matches what LegalizeDAG does. Since the introduction of STRICT nodes, I've encountered several issues with X86's custom handling being called with an SDValue pointing at the chain and our custom handlers using that to get a VT instead of result 0. This should prevent us from having any more of those issues. On return we will update the LegalizedNodes map for all results so we shouldn't call the custom handler again for each result number. I want to push SDNode* further into the Expand and Promote handlers, but I've left that for a follow to keep this patch size down. I've created a dummy SDValue(Node, 0) to keep the handlers working. Differential Revision: https://reviews.llvm.org/D72224
* [ELF] Make TargetInfo::writeIgotPlt a no-opFangrui Song2020-01-104-9/+5
| | | | | | | | | | | | | | RELA targets don't read initial .got.plt entries. REL targets (ARM, x86-32) write the address of the IFUNC resolver to the entry (`write32le(buf, s.getVA())`). The default writeIgotPlt() is not meaningful. Make it a no-op. AArch64 and x86-64 will have 0 as initial .got.plt entries associated with IFUNC. Reviewed By: peter.smith Differential Revision: https://reviews.llvm.org/D72474
* [Driver][CodeGen] Add -fpatchable-function-entry=N[,0]Fangrui Song2020-01-109-0/+58
| | | | | | | | | | | In the backend, this feature is implemented with the function attribute "patchable-function-entry". Both the attribute and XRay use TargetOpcode::PATCHABLE_FUNCTION_ENTER, so the two features are incompatible. Reviewed By: ostannard, MaskRay Differential Revision: https://reviews.llvm.org/D72222
* Support function attribute patchable_function_entryFangrui Song2020-01-108-1/+99
| | | | | | | | | This feature is generic. Make it applicable for AArch64 and X86 because the backend has only implemented NOP insertion for AArch64 and X86. Reviewed By: nickdesaulniers, aaron.ballman Differential Revision: https://reviews.llvm.org/D72221
OpenPOWER on IntegriCloud