summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [ORC] Rename MaterializationResponsibility resolve and emit methods toLang Hames2019-06-138-54/+55
| | | | | | | | | | | | | notifyResolved/notifyEmitted. The 'notify' prefix better describes what these methods do: they update the JIT symbol states and notify any pending queries that the 'resolved' and 'emitted' states have been reached (rather than actually performing the resolution or emission themselves). Since new states are going to be introduced in the near future (to track symbol registration/initialization) it's worth changing the convention pre-emptively to avoid further confusion. llvm-svn: 363322
* [dfsan] Introduce dfsan_flush().Kostya Serebryany2019-06-134-0/+42
| | | | | | | | | | | | | | | | | | | Summary: dfsan_flush() allows to restart tain tracking from scratch in the same process. The primary purpose right now is to allow more efficient data flow tracing for DFT fuzzing: https://github.com/google/oss-fuzz/issues/1632 Reviewers: pcc Reviewed By: pcc Subscribers: delcypher, #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D63037 llvm-svn: 363321
* [LangRef] Clarify poison semanticsNikita Popov2019-06-132-10/+25
| | | | | | | | | | | | | | | | | | | | | I find the current documentation of poison somewhat confusing, mainly because its use of "undefined behavior" doesn't seem to align with our usual interpretation (of immediate UB). Especially the sentence "any instruction that has a dependence on a poison value has undefined behavior" is very confusing. Clarify poison semantics by: * Replacing the introductory paragraph with the standard rationale for having poison values. * Spelling out that instructions depending on poison return poison. * Spelling out how we go from a poison value to immediate undefined behavior and give the two examples we currently use in ValueTracking. * Spelling out that side effects depending on poison are UB. Differential Revision: https://reviews.llvm.org/D63044 llvm-svn: 363320
* [SimplifyCFG] NFC, update Switch tests as a baseline.Shawn Landden2019-06-1319-1422/+2511
| | | | | | | | | | | | | Also add baseline tests to show effect of later patches. There were a couple of regressions here that were never caught, but my patch set that this is a preparation to will fix them. This is the third attempt to land this patch. Differential Revision: https://reviews.llvm.org/D61150 llvm-svn: 363319
* Add a clarifying comment about branching on poisonPhilip Reames2019-06-131-0/+4
| | | | | | I recently got this wrong (again), and I'm sure I'm not the only one. Put a comment in the logical place someone would look to "fix" the obvious "missed optimization" which arrises based on the common misunderstanding. Hopefully, this will save others time. :) llvm-svn: 363318
* Revert "[NFC][CodeGen] Add unary fneg tests to fp-fast.ll fp-fold.ll ↵Cameron McInally2019-06-136-85/+1
| | | | | | | | fp-in-intregs.ll fp-stack-compare-cmov.ll fp-stack-compare.ll fsxor-alignment.ll" This reverts commit 1d85a7518c6b660a85caabd580b632f9abd5a8ab. llvm-svn: 363317
* Revert "[NFC][CodeGen] Add unary fneg tests to fmul-combines.ll fnabs.ll"Cameron McInally2019-06-132-129/+0
| | | | | | This reverts commit 5c0114058126757ce21e546997121afffc8119cd. llvm-svn: 363316
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma_patterns_wide.ll"Cameron McInally2019-06-131-219/+0
| | | | | | This reverts commit f1b8c6ac4f9d31899a2bc128f8a37b5a1c3e1f77. llvm-svn: 363315
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma_patterns.ll"Cameron McInally2019-06-131-304/+0
| | | | | | This reverts commit 06de52674da73f30751f3ff19fdf457f87077c65. llvm-svn: 363314
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma4-fneg-combine.ll"Cameron McInally2019-06-131-105/+0
| | | | | | This reverts commit f288a0685f874d2b965db25a16b9c44f78c55b12. llvm-svn: 363313
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma-scalar-combine.ll"Cameron McInally2019-06-131-97/+3
| | | | | | This reverts commit 3d2ee0053aa2576fd19cd169798c496199f0a29b. llvm-svn: 363312
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma-intrinsics-x86.ll"Cameron McInally2019-06-131-896/+0
| | | | | | This reverts commit 169fc2b0209d5574fca0927a707706ea2d5f5a09. llvm-svn: 363311
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma4-intrinsics-x86.ll"Cameron McInally2019-06-131-221/+0
| | | | | | This reverts commit 66f286845cad73a280617a606e29c9009bb4da87. llvm-svn: 363310
* Revert "[NFC][CodeGen] Add unary FNeg tests to some X86/ and XCore/ tests."Cameron McInally2019-06-135-401/+1
| | | | | | This reverts commit 4f3cf3853e1145e3e08fb42ace79ba3e4e268540. llvm-svn: 363309
* Revert "[NFC][CodeGen] Add unary FNeg tests to X86/fma-intrinsics-canonical.ll"Cameron McInally2019-06-131-621/+0
| | | | | | This reverts commit ee5881a88cbe148bb64d14b8a5b31a314ee22343. llvm-svn: 363308
* Revert "[NFC][CodeGen] Forgot 2 unary FNeg tests in ↵Cameron McInally2019-06-131-56/+0
| | | | | | | | X86/fma-intrinsics-canonical.ll" This reverts commit 5f39a3096f8e7b09bd1645f4e4ca66343066a6e1. llvm-svn: 363307
* Revert "[NFC][CodeGen] Add unary fneg tests to X86/fma-fneg-combine.ll"Cameron McInally2019-06-131-434/+0
| | | | | | This reverts commit 10c085554215e84831d272f2e6a93b7c70d143bf. llvm-svn: 363306
* Revert "[NFC][CodeGen] Add unary FNeg tests to X86/combine-fcopysign.ll ↵Cameron McInally2019-06-134-181/+0
| | | | | | | | X86/dag-fmf-cse.ll X86/fast-isel-fneg.ll X86/fdiv.ll" This reverts commit e04c4b6af81d6142c4ff8dd9d00f44a27e9a66eb. llvm-svn: 363305
* Revert "[NFC][CodeGen] Add unary FNeg tests to ↵Cameron McInally2019-06-132-701/+0
| | | | | | | | X86/avx512vl-intrinsics-fast-isel.ll X86/combine-fabs.ll" This reverts commit 6fe46ec25d849a9fd5be25acf0ee77e3c06c0786. llvm-svn: 363304
* Revert "[NFC][CodeGen] Add unary FNeg tests to ↵Cameron McInally2019-06-131-618/+0
| | | | | | | | X86/avx512vl-intrinsics-fast-isel.ll" This reverts commit 2aa5ada267d268fec2b1e90efeae1ddee24617be. llvm-svn: 363303
* Revert "[NFC][CodeGen] Add unary FNeg tests to ↵Cameron McInally2019-06-131-71/+0
| | | | | | | | X86/avx512vl-intrinsics-fast-isel.ll" This reverts commit 27a5db9de57d13d44c7a7704e06d8ba69ec8b4af. llvm-svn: 363302
* Revert "[NFC][CodeGen] Add unary FNeg tests to ↵Cameron McInally2019-06-131-657/+0
| | | | | | | | X86/avx512-intrinsics-fast-isel.ll" This reverts commit 41e0b9f2803089155536bdec7cbea6b82680a727. llvm-svn: 363301
* Revert "[NFC][CodeGen] Add unary FNeg tests to ↵Cameron McInally2019-06-131-755/+0
| | | | | | | | X86/avx512-intrinsics-fast-isel.ll" This reverts commit aeb89f8b33d8fca4e819ba41267093699a7e4885. llvm-svn: 363300
* [AMDGPU] gfx1010 base changes for wave32Stanislav Mekhanoshin2019-06-1312-25/+209
| | | | | | Differential Revision: https://reviews.llvm.org/D63293 llvm-svn: 363299
* [lit] Disable test on darwin when building shared libs.Don Hinton2019-06-132-0/+4
| | | | | | | | | | | | | | | | | | | | | Summary: This test fails to link shared libraries because tries to run a copied version of clang-check to see if the mock version of libcxx in the same directory can be loaded dynamically. Since the test is specifically designed not to look in the default just-built lib directory, it must be disabled when building with BUILD_SHARED_LIBS=ON. Currently only disabling it on Darwin and basing it on the enable_shared flag. Reviewed By: ilya-biryukov Tags: #clang, #llvm Differential Revision: https://reviews.llvm.org/D61697 llvm-svn: 363298
* [AMDGPU] gfx1010: small test change for wave32. NFCStanislav Mekhanoshin2019-06-131-1/+1
| | | | llvm-svn: 363297
* [clang-tidy] Make ClangTidyCheck::OptionsView public.Yitzhak Mandelbaum2019-06-131-7/+7
| | | | | | | | | | | | | | Summary: The `OptionsView` class is currently protected. This constraint prevents tidies from passing the OptionsView to, for example, a helper function. Similarly, TransformerClangTidyCheck cannot pass the `OptionsView` object to functions that generate `tooling::RewriteRule`s. The latter is needed to allow the definition of such rules to depend on the clang-tidy options, as demonstrated in the child revision. Reviewers: gribozavr Subscribers: xazax.hun, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D63287 llvm-svn: 363296
* C++ DR712 and others: handle non-odr-use resulting from an lvalue-to-rvalue ↵Richard Smith2019-06-1312-90/+690
| | | | | | | | | | | | | | | | | | | | | conversion applied to a member access or similar not-quite-trivial lvalue expression. Summary: When a variable is named in a context where we can't directly emit a reference to it (because we don't know for sure that it's going to be defined, or it's from an enclosing function and not captured, or the reference might not "work" for some reason), we emit a copy of the variable as a global and use that for the known-to-be-read-only access. Reviewers: rjmccall Subscribers: jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D63157 llvm-svn: 363295
* [docs] Fix TableGen/LangRef typosJordan Rupprecht2019-06-131-2/+2
| | | | | | | | This fixes: - `Pred` -> `Prep` - `IfDef` -> `Ifdef` (rst is case sensitive here) llvm-svn: 363294
* [LFTR] Rename variable to minimize confusion [NFC]Philip Reames2019-06-131-18/+15
| | | | | | As pointed out by Nikita in D62625, BackedgeTakenCount is generally used to refer to the backedge taken count of the loop. A conditional backedge taken count - one which only applies if a particular exit is taken - is called a ExitCount in SCEV code, so be consistent here. llvm-svn: 363293
* [LFTR] Stylistic cleanup as suggested in last review comment of D62939 [NFC]Philip Reames2019-06-131-9/+9
| | | | llvm-svn: 363292
* [InstCombine] add test for failed libfunction prototype matching; NFCSanjay Patel2019-06-131-7/+25
| | | | llvm-svn: 363291
* [libc++] Add missing #include in <cwchar> testsLouis Dionne2019-06-132-0/+2
| | | | | | | Thanks to Mikhail Maltsev for the patch. Differential Revision: https://reviews.llvm.org/D63289 llvm-svn: 363290
* Fix a bug w/inbounds invalidation in LFTRPhilip Reames2019-06-135-22/+96
| | | | | | | | | | | | | | This contains fixes for two cases where we might invalidate inbounds and leave it stale in the IR (a miscompile). Case 1 is when switching to an IV with no dynamically live uses, and case 2 is when doing pre-to-post conversion on the same pointer type IV. The basic scheme used is to prove that using the given IV (pre or post increment forms) would have to already trigger UB on the path to the test we're modifying. As such, our potential UB triggering use does not change the semantics of the original program. As was pointed out in the review thread by Nikita, this is defending against a separate issue from the hasConcreteDef case. This is about poison, that's about undef. Unfortunately, the two are different, see Nikita's comment for a fuller explanation, he explains it well. (Note: I'm going to address Nikita's last style comment in a separate commit just to minimize chance of subtle bugs being introduced due to typos.) Differential Revision: https://reviews.llvm.org/D62939 llvm-svn: 363289
* PR42182: Allow thread-local to use __cxa_thread_atexit whenErich Keane2019-06-132-5/+13
| | | | | | | | | | | -fno-use-cxx-atexit is used This matches the GCC behavior, __cxa_thread_atexit should be permissible even though cxa_atexit is disabled. Differential Revision: https://reviews.llvm.org/D63283/ llvm-svn: 363288
* [clang][NewPM] Fix broken -O0 test from missing assumptionsLeonard Chan2019-06-133-4/+17
| | | | | | | | | | | Add an AssumptionCache callback to the InlineFuntionInfo used for the AlwaysInlinerPass to match codegen of the AlwaysInlinerLegacyPass to generate llvm.assume. This fixes CodeGen/builtin-movdir.c when new PM is enabled by default. Differential Revision: https://reviews.llvm.org/D63170 llvm-svn: 363287
* [InstCombine] auto-generate complete test checks; NFCSanjay Patel2019-06-131-23/+20
| | | | llvm-svn: 363286
* [NFC] Updated testcase for D54411/rL363284David Bolvansky2019-06-131-14/+8
| | | | llvm-svn: 363285
* [Codegen] Merge tail blocks with no successors after block placementDavid Bolvansky2019-06-1311-381/+295
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: I found the following case having tail blocks with no successors merging opportunities after block placement. Before block placement: bb0: ... bne a0, 0, bb2: bb1: mv a0, 1 ret bb2: ... bb3: mv a0, 1 ret bb4: mv a0, -1 ret The conditional branch bne in bb0 is opposite to beq. After block placement: bb0: ... beq a0, 0, bb1 bb2: ... bb4: mv a0, -1 ret bb1: mv a0, 1 ret bb3: mv a0, 1 ret After block placement, that appears new tail merging opportunity, bb1 and bb3 can be merged as one block. So the conditional constraint for merging tail blocks with no successors should be removed. In my experiment for RISC-V, it decreases code size. Author of original patch: Jim Lin Reviewers: haicheng, aheejin, craig.topper, rnk, RKSimon, Jim, dmgreen Reviewed By: Jim, dmgreen Subscribers: xbolva00, dschuff, javed.absar, sbc100, jgravelle-google, aheejin, kito-cheng, dmgreen, PkmX, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D54411 llvm-svn: 363284
* [clang][NewPM] Fix split debug testLeonard Chan2019-06-132-3/+10
| | | | | | | | | This contains the part of D62225 which fixes CodeGen/split-debug-single-file.c by not placing .dwo sections when using -enable-split-dwarf=split. Differential Revision: https://reviews.llvm.org/D63168 llvm-svn: 363281
* [CMake] Fix generated Xcode-project ignoring output directory setting for ↵Stefan Granitz2019-06-131-0/+6
| | | | | | | | | LLDB.framework Other generators honor the `LIBRARY_OUTPUT_DIRECTORY` target property, but apparently Xcode doesn't. So we call `set_output_directory()` as `llvm_add_library()` would do and this works. Note that `LIBRARY_OUTPUT_DIRECTORY` is still necessary, because it's used to store and read the target's absolute build directory (while `LLDB_FRAMEWORK_BUILD_DIR` is relative!). llvm-svn: 363280
* [CMake] Fix lldb-dotest for single-config generators in standalone buildsStefan Granitz2019-06-131-1/+5
| | | | | | Differential Revision: https://reviews.llvm.org/D62859 llvm-svn: 363279
* [clang][NewPM] Fix broken profile testLeonard Chan2019-06-132-4/+14
| | | | | | | | | | This contains the part of D62225 which fixes Profile/gcc-flag-compatibility.c by adding the pass that allows default profile generation to work under the new PM. It seems that ./default.profraw was not being generated with new PM enabled. Differential Revision: https://reviews.llvm.org/D63155 llvm-svn: 363278
* [clang][NewPM] Fix broken -O0 test from the AlwaysInlinerLeonard Chan2019-06-132-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | This contains the part of D62225 which prevents insertion of lifetime intrinsics when creating the AlwaysInliner. This fixes the following tests when the new PM is enabled by default: Clang :: CodeGen/aarch64-neon-across.c Clang :: CodeGen/aarch64-neon-fcvt-intrinsics.c Clang :: CodeGen/aarch64-neon-fma.c Clang :: CodeGen/aarch64-neon-perm.c Clang :: CodeGen/aarch64-neon-tbl.c Clang :: CodeGen/aarch64-poly128.c Clang :: CodeGen/aarch64-v8.2a-neon-intrinsics.c Clang :: CodeGen/arm-neon-fma.c Clang :: CodeGen/arm-neon-numeric-maxmin.c Clang :: CodeGen/arm-neon-vcvtX.c Clang :: CodeGen/avx-builtins.c Clang :: CodeGen/builtins-ppc-p9vector.c Clang :: CodeGen/builtins-ppc-vsx.c Clang :: CodeGen/lifetime.c Clang :: CodeGen/sse-builtins.c Clang :: CodeGen/sse2-builtins.c Differential Revision: https://reviews.llvm.org/D63153 llvm-svn: 363277
* [AMDGPU] ImmArg and SourceOfDivergence for permlane/dppStanislav Mekhanoshin2019-06-134-3/+76
| | | | | | | | | Added missing ImmArg and SourceOfDivergence to the crosslane intrinsics. Differential Revision: https://reviews.llvm.org/D63216 llvm-svn: 363276
* [NFC][CodeGen] Add unary FNeg tests to X86/avx512-intrinsics-fast-isel.llCameron McInally2019-06-131-0/+755
| | | | | | Patch 2 of n. llvm-svn: 363275
* [EarlyCSE] Ensure equal keys have the same hash valueJoseph Tremoulet2019-06-134-79/+166
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The logic in EarlyCSE that looks through 'not' operations in the predicate recognizes e.g. that `select (not (cmp sgt X, Y)), X, Y` is equivalent to `select (cmp sgt X, Y), Y, X`. Without this change, however, only the latter is recognized as a form of `smin X, Y`, so the two expressions receive different hash codes. This leads to missed optimization opportunities when the quadratic probing for the two hashes doesn't happen to collide, and assertion failures when probing doesn't collide on insertion but does collide on a subsequent table grow operation. This change inverts the order of some of the pattern matching, checking first for the optional `not` and then for the min/max/abs patterns, so that e.g. both expressions above are recognized as a form of `smin X, Y`. It also adds an assertion to isEqual verifying that it implies equal hash codes; this fires when there's a collision during insertion, not just grow, and so will make it easier to notice if these functions fall out of sync again. A new flag --earlycse-debug-hash is added which can be used when changing the hash function; it forces hash collisions so that any pair of values inserted which compare as equal but hash differently will be caught by the isEqual assertion. Reviewers: spatel, nikic Reviewed By: spatel, nikic Subscribers: lebedev.ri, arsenm, craig.topper, efriedma, hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D62644 llvm-svn: 363274
* [clang-tidy] Made abseil-faster-strsplit-delimiter tests pass on C++17Dmitri Gribenko2019-06-132-19/+10
| | | | | | | | | | | | | | | | Reviewers: hokein, gribozavr Reviewed By: hokein, gribozavr Subscribers: xazax.hun, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D63253 Patch by Johan Vikström. llvm-svn: 363273
* [clang-tidy] Fixed abseil-time-subtraction to work on C++17Dmitri Gribenko2019-06-132-17/+36
| | | | | | | | | | | | | | | | Summary: Fixed abseil-time-subtraction to work on C++17 Reviewers: hokein, gribozavr Subscribers: xazax.hun, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D63261 Patch by Johan Vikström. llvm-svn: 363272
* [CMake] Add fallbacks for copying clang-resource-headers to LLDB.framework ↵Stefan Granitz2019-06-131-3/+25
| | | | | | in standalone builds llvm-svn: 363271
OpenPOWER on IntegriCloud