- Nov 21, 2018
-
-
Michal Gorny authored
Copy the fix for determining the correct terminfo library from LLVM -- use distinct variables for check_library_exists() calls. Otherwise, the first check (for -ltinfo) populates the variable and no other checks are performed. Effectively, systems with other libraries than the first one listed are presumed not to have terminfo routines at all. Also sync the check order to include the NetBSD fix from r347156. This partially fixes undefined symbols when linking XRay tests. It's probably not the best solution to the problem there but as long as the terminfo check stays in config-ix, I thnk it's worth fixing. Differential Revision: https://reviews.llvm.org/D54641 llvm-svn: 347338
-
Michal Gorny authored
Skip all MappedMemoryTest variants that rely on memory pages being mapped for MF_WRITE|MF_EXEC when MPROTECT is enabled on NetBSD. W^X protection causes all those mmap() calls to fail, causing the tests to fail. Differential Revision: https://reviews.llvm.org/D54080 llvm-svn: 347337
-
Vitaly Buka authored
Reviewers: dvyukov Subscribers: krytarowski, kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D54664 llvm-svn: 347336
-
Simon Pilgrim authored
llvm-svn: 347335
-
Leonard Chan authored
Differential Revision: https://reviews.llvm.org/D54729 llvm-svn: 347334
-
Sanjay Patel authored
These are included in D54666, so adding them first with baseline results. Patch by: @nikic (Nikita Popov) llvm-svn: 347333
-
Sanjay Patel authored
Splitting these off from the D54666. Patch by: nikic (Nikita Popov) llvm-svn: 347332
-
Sanjay Patel authored
These are part of D54666, so adding them here before the patch to show the baseline (currently unoptimized) results. Patch by: @nikic (Nikita Popov) llvm-svn: 347331
-
Sanjay Patel authored
Add support for saturating add/sub in InstructionSimplify. In particular, the following simplifications are supported: sat(X + 0) -> X sat(X + undef) -> -1 sat(X uadd MAX) -> MAX (and commutative variants) sat(X - 0) -> X sat(X - X) -> 0 sat(X - undef) -> 0 sat(undef - X) -> 0 sat(0 usub X) -> 0 sat(X usub MAX) -> 0 Patch by: @nikic (Nikita Popov) Differential Revision: https://reviews.llvm.org/D54532 llvm-svn: 347330 -
Samuel Benzaquen authored
Summary: Benchmarks for std::sort, std::stable_sort, std::make_heap, std::sort_heap, std::pop_heap and std::push_heap. The benchmarks are run with integers and strings, and with different sorted input. Reviewers: EricWF Subscribers: christof, mgrang, ldionne, libcxx-commits Differential Revision: https://reviews.llvm.org/D53978 llvm-svn: 347329
-
Sanjay Patel authored
Support saturating add/sub in constant folding, based on the APInt methods introduced in D54332. Patch by: @nikic (Nikita Popov) Differential Revision: https://reviews.llvm.org/D54531 llvm-svn: 347328
-
Fangrui Song authored
Summary: When --noinhibit-exec is used, ld.bfd/gold emit errors but allow to produce corrupted executable, which is handy for debugging purpose. lld's --noinhibit-exec has a different meaning and changes some errors to warnings. This patch replaces "error" with "errorOrWarn" to exploit that property. We may revisit this: if we should keep them as errors (as ld.bfd/gold do) but allow to produce a (corrupted) executable. Reviewers: ruiu, grimar, espindola Reviewed By: grimar Subscribers: Timmmm, jhenderson, emaste, arichardson, llvm-commits Differential Revision: https://reviews.llvm.org/D54651 llvm-svn: 347327
-
Simon Pilgrim authored
Makes an upcoming SimplifyDemandedBits optimization much easier to understand. llvm-svn: 347326
-
Guozhi Wei authored
This patch fixes PR39695. The original LoopSink only considers memory alias in loop body. But PR39695 shows that instructions following sink candidate in preheader should also be checked. This is a conservative patch, it simply adds whole preheader block to alias set. It may lose some optimization opportunity, but I think that is very rare because: 1 in the most common case st/ld to the same address, the load should already be optimized away. 2 usually preheader is not very large. Differential Revision: https://reviews.llvm.org/D54659 llvm-svn: 347325
-
Sanjay Patel authored
This adds the sadd_sat, uadd_sat, ssub_sat, usub_sat methods for performing saturating additions and subtractions to APInt. Split out from D54237. Patch by: nikic (Nikita Popov) Differential Revision: https://reviews.llvm.org/D54332 llvm-svn: 347324
-
Stella Stamenova authored
If we just invoke clang-cl without specifying the linker, the tests fail on Windows because they cannot find the correct linker to use, so it needs to be specified explicitly llvm-svn: 347323
-
Erich Keane authored
Change-Id: I74704acf052e2e8fe707f18230bc5655c2bf2a91 llvm-svn: 347322
-
Stella Stamenova authored
These tests are not able to pass on Windows as written as they don't even build llvm-svn: 347321
-
Bruno Ricci authored
Use the newly available space in the bit-fields of Stmt and store the expressions in a trailing array. This saves 2 pointer per ParenListExpr. Differential Revision: https://reviews.llvm.org/D54675 Reviewed By: rjmccall llvm-svn: 347320
-
Bruno Ricci authored
Factor out the test for whether the LHS is the base of the array subscript expression into a private method lhsIsBase. NFC. llvm-svn: 347319
-
Sanjay Patel authored
This patch fixes the issue noticed in D54532. The problem is that cst_pred_ty-based matchers like m_Zero() currently do not match scalar undefs (as expected), but *do* match vector undefs. This may lead to optimization inconsistencies in rare cases. There is only one existing test for which output changes, reverting the change from D53205. The reason here is that vector fsub undef, %x is no longer matched as an m_FNeg(). While I think that the new output is technically worse than the previous one, it is consistent with scalar, and I don't think it's really important either way (generally that undef should have been folded away prior to reassociation.) I've also added another test case for this issue based on InstructionSimplify. It took some effort to find that one, as in most cases undef folds are either checked first -- and in the cases where they aren't it usually happens to not make a difference in the end. This is the only case I was able to come up with. Prior to this patch the test case simplified to undef in the scalar case, but zeroinitializer in the vector case. Patch by: @nikic (Nikita Popov) Differential Revision: https://reviews.llvm.org/D54631 llvm-svn: 347318
-
Bruno Ricci authored
Use the newly available space in the bit-fields of Stmt. This saves one pointer per ArraySubscriptExpr. llvm-svn: 347317
-
- Nov 20, 2018
-
-
Sanjay Patel authored
llvm-svn: 347316
-
Haojian Wu authored
Summary: Currently the smart_ptr check (modernize-make-unique) generates the fixes that cannot compile for cases like below -- because brace list can not be deduced in `make_unique`. ``` struct Bar { int a, b; }; struct Foo { Foo(Bar); }; auto foo = std::unique_ptr<Foo>(new Foo({1, 2})); ``` Reviewers: aaron.ballman Subscribers: xazax.hun, cfe-commits Differential Revision: https://reviews.llvm.org/D54704 llvm-svn: 347315 -
Nico Weber authored
llvm-svn: 347314
-
Simon Pilgrim authored
This uncovered an off-by-one typo in SimplifyDemandedVectorElts's INSERT_SUBVECTOR handling as its bounds check was bailing on safe indices. llvm-svn: 347313
-
Aaron Ballman authored
This clarifies that __has_cpp_attribute is no longer always an extension since it's now available in C++2a. Also, Both __has_cpp_attribute and __has_c_attribute can accept attribute scope tokens with alternative spelling (clang vs _Clang and gnu vs __gnu__). llvm-svn: 347312
-
Jinsong Ji authored
When doing some instruction scheduling work, we noticed some missing itineraries. Before we switch to machine scheduler, those missing itineraries might not have impact to actually scheduling, because we can still get same latency due to default values. With machine scheduler, however, itineraries will have impact to scheduling. eg: NumMicroOps will default to be 0 if there is NO itineraries for specific instruction class. And most of the instruction class with itineraries will have NumMicroOps default to 1. This will has impact on the count of RetiredMOps, affects the Pending/Available Queue, then causing different scheduling or suboptimal scheduling further. This patch is for STWU/STWUX (IIC_LdStStoreUpd ) for P8. Since there are already multiple IIC for store update, this patch also merge IIC_LdStSTDU/IIC_LdStStoreUpd to IIC_LdStSTU IIC_LdStSTDUX to IIC_LdStSTUX and we add a new testcase in https://reviews.llvm.org/D54699 to show the difference. Differential Revision: https://reviews.llvm.org/D54700 llvm-svn: 347311
-
Jinsong Ji authored
This patch add a STWU testcase for scheduling check. Currently P7/P8 which use itineraries are missing IIC_LdStStoreUpd, We use CHECK-ITIN prefix to check P7/P8, then use default for P9 (and future). We will fix the missing itineraries of IIC_LdStStoreUpd in following patch, and update this testcase to show the scheduling difference only there. Differential Revision: https://reviews.llvm.org/D54699 llvm-svn: 347310
-
Jinsong Ji authored
Apply review comments of https://reviews.llvm.org/D54185 to other target as well, specifically: 1. make anonymous namespaces as small as possible, avoid using static inside anonymous namespaces 2. Add missing header to some files 3. GetLoadImmediateOpcodem-> getLoadImmediateOpcode 4. Fix typo Differential Revision: https://reviews.llvm.org/D54343 llvm-svn: 347309
-
Simon Pilgrim authored
llvm-svn: 347308
-
Krasimir Georgiev authored
Summary: Clang-format is treating all occurences of `is` in js as type matchers. In some cases this is wrong, as it might be a dict key. Reviewers: mprobst Reviewed By: mprobst Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D54753 llvm-svn: 347307
-
Gabor Marton authored
Summary: FunctionDecl import starts with a lookup and then we create a new Decl. Then in case of CXXConstructorDecl we further import other Decls (base classes, members through CXXConstructorDecl::inits()) before connecting the redecl chain. During those in-between imports structural eq fails because the canonical decl is different. This commit fixes this. Synthesizing a test seemed extremely hard, however, Xerces analysis reproduces the problem. Reviewers: a_sidorin, a.sidorin Subscribers: rnkovacs, dkrupp, Szelethus, cfe-commits Differential Revision: https://reviews.llvm.org/D53702 llvm-svn: 347306
-
Stefan Granitz authored
Summary: Use llvm_codesign to sign debugserver with entitlements. Set global LLVM_CODESIGNING_IDENTITY from LLDB_CODESIGN_IDENTITY (if given). Pass through ENTITLEMENTS from add_lldb_executable to add_llvm_executable. Handle reconfigurations correctly. We have a lot of cases, make them explicit: (1) build and sign debugserver, if all conditions apply: * LLDB_NO_DEBUGSERVER=OFF (default) * On Darwin: LLDB_USE_SYSTEM_DEBUGSERVER=OFF (default) * On Darwin: LLVM_CODESIGNING_IDENTITY == lldb_codesign (2) use system debugserver, if on Darwin and any of: * LLDB_USE_SYSTEM_DEBUGSERVER=ON and found on system (explicit case) * LLVM_CODESIGNING_IDENTITY != lldb_codesign and found on system (fallback case) (3) debugserver will not be available, in case of: * LLDB_NO_DEBUGSERVER=ON * On Darwin: LLVM_CODESIGNING_IDENTITY != lldb_codesign and not found on system (4) error state, in case of: * LLDB_USE_SYSTEM_DEBUGSERVER=ON and not found on system * LLDB_USE_SYSTEM_DEBUGSERVER=ON and LLDB_NO_DEBUGSERVER=ON Reviewers: xiaobai, beanz, vsk, JDevlieghere Subscribers: mgorny, lldb-commits, llvm-commits Differential Revision: https://reviews.llvm.org/D54476 llvm-svn: 347305
-
Vassil Vassilev authored
Our internal clients implement parsing cache based on FileID. In order for the Preprocessor to reenter the cached FileID it needs to reset its NumCreatedFIDsForFileID. Differential Revision: https://reviews.llvm.org/D51295 llvm-svn: 347304
-
Simon Pilgrim authored
Pull out getPackDemandedElts demanded elts remapping helper from computeKnownBitsForTargetNode and use in computeKnownBits/ComputeNumSignBits. llvm-svn: 347303
-
Simon Pilgrim authored
Noticed while working on improving demanded elts target shuffle shuffle combining llvm-svn: 347302
-
Simon Pilgrim authored
For bitcast nodes from larger element types, add the ability for SimplifyDemandedVectorElts to call SimplifyDemandedBits by merging the elts mask to a bits mask. I've raised https://bugs.llvm.org/show_bug.cgi?id=39689 to deal with the few places where SimplifyDemandedBits's lack of vector handling is a problem. Differential Revision: https://reviews.llvm.org/D54679 llvm-svn: 347301
-
Simon Pilgrim authored
As discussed on rL347240, this avoids some regressions on D54679 and also helps some combines to kick in a bit earlier. llvm-svn: 347300
-
Simon Pilgrim authored
As discussed on rL347240. llvm-svn: 347299
-