summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [InstSimplify] remove zero-shift-guard fold for general funnel shiftSanjay Patel2019-02-262-29/+54
| | | | | | | | | | | | | | | | | | | | | | As discussed on llvm-dev: http://lists.llvm.org/pipermail/llvm-dev/2019-February/130491.html We can't remove the compare+select in the general case because we are treating funnel shift like a standard instruction (as opposed to a special instruction like select/phi). That means that if one of the operands of the funnel shift is poison, the result is poison regardless of whether we know that the operand is actually unused based on the instruction's particular semantics. The motivating case for this transform is the more specific rotate op (rather than funnel shift), and we are preserving the fold for that case because there is no chance of introducing extra poison when there is no anonymous extra operand to the funnel shift. llvm-svn: 354905
* Remove P1272R1, it was not moved in KonaMarshall Clow2019-02-261-1/+0
| | | | llvm-svn: 354904
* [clang-tidy] undo bitfields in ExceptionAnalyzerJonas Toth2019-02-261-4/+2
| | | | | | | Scoped enums do induce some problems with some MSVC and GCC versions if used as bitfields. Therefor this is deactivated for now. llvm-svn: 354903
* [libFuzzer] Remove extra semicolonsJonathan Metzman2019-02-263-5/+5
| | | | | | | | | | | | | | | | | | Summary: Remove extra semicolons so that libFuzzer can compile with -Werror -Wextra-semi Reviewers: Dor1s, morehouse, thakis Reviewed By: Dor1s, morehouse Subscribers: jdoerfert, #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D58674 llvm-svn: 354902
* Put a 'first implemented' version into the entry for P1357Marshall Clow2019-02-261-1/+1
| | | | llvm-svn: 354901
* [MIPS GlobalISel] Select G_UADDOPetar Avramovic2019-02-264-1/+67
| | | | | | | | | Lower G_UADDO. Legalize G_UADDO for MIPS32 Differential Revision: https://reviews.llvm.org/D58671 llvm-svn: 354900
* [X86] AMD znver2 enablementGanesh Gopalasubramanian2019-02-267-2/+111
| | | | | | | | | | | | | | | | | This patch enables the following 1) AMD family 17h "znver2" tune flag (-march, -mcpu). 2) ISAs that are enabled for "znver2" architecture. 3) For the time being, it uses the znver1 scheduler model. 4) Tests are updated. 5) This patch is the clang counterpart to D58343 Reviewers: craig.topper Tags: #clang Differential Revision: https://reviews.llvm.org/D58344 llvm-svn: 354899
* Mark several issues (and one paper) as complete. Reviewed as D58099; but I ↵Marshall Clow2019-02-262-8/+8
| | | | | | added LWG3101 and LWG3144 and P1357R1 as well. llvm-svn: 354898
* [X86] AMD znver2 enablementGanesh Gopalasubramanian2019-02-267-5/+31
| | | | | | | | | | | | | | | | This patch enables the following 1) AMD family 17h "znver2" tune flag (-march, -mcpu). 2) ISAs that are enabled for "znver2" architecture. 3) For the time being, it uses the znver1 scheduler model. 4) Tests are updated. 5) Scheduler descriptions are yet to be put in place. Reviewers: craig.topper Differential Revision: https://reviews.llvm.org/D58343 llvm-svn: 354897
* [SystemZ] Wait with selection of legal vector/FP constants until Select().Jonas Paulsson2019-02-269-182/+299
| | | | | | | | | | | | | | | | | | | | | This patch aims to make sure that any such constant that can be generated with a vector instruction (for example VGBM) is recognized as such during legalization and kept as a target independent node through post-legalize DAGCombining. Two new functions named isVectorConstantLegal() and loadVectorConstant() replace old ways of handling vector/FP constants. A new struct named SystemZVectorConstantInfo is used to cache the results of isVectorConstantLegal() and pass them onto loadVectorConstant(). Support for fp128 constants in the presence of FeatureVectorEnhancements1 (z14) has been added. Review: Ulrich Weigand https://reviews.llvm.org/D58270 llvm-svn: 354896
* [scudo][standalone] Introduce platform specific code & mutexesKostya Kortchinsky2019-02-2615-52/+986
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: This CL adds the platform specific code for Fuchsia, Linux & Android, as well as some tests related to those (more tests to come later). While some of it is pretty much a straight port of the existing scudo & sanitizer_common code, the memory mapping functions have been reworked a bit to fit the limited usage scenario that Scudo has for them. For Fuchsia, I can now track the Vmar/Vmo pair for memory mappings if there is an intent to grow or decommit some mapping (that will be useful for the Primary). Reviewers: eugenis, vitalybuka, mcgrathr, phosek, flowerhack, morehouse, dmmoore415 Reviewed By: vitalybuka, morehouse Subscribers: kcc, dvyukov, srhines, mgorny, delcypher, jfb, jdoerfert, #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D58184 llvm-svn: 354895
* [InstSimplify] add tests for rotate; NFCSanjay Patel2019-02-261-0/+100
| | | | | | | | Rotate is a special-case of funnel shift that has different poison constraints than the general case. That's not visible yet in the existing tests, but it needs to be corrected. llvm-svn: 354894
* [OpenCL] Fix assertion due to blocksYaxun Liu2019-02-262-0/+8
| | | | | | | | | | | | | | | | A recent change caused assertion in CodeGenFunction::EmitBlockCallExpr when a block is called. There is code Func = CGM.getOpenCLRuntime().getInvokeFunction(E->getCallee()); getCalleeDecl calls Expr::getReferencedDeclOfCallee, which does not handle BlockExpr and returns nullptr, which causes isa to assert. This patch fixes that. Differential Revision: https://reviews.llvm.org/D58658 llvm-svn: 354893
* Implement P1357: Traits for [Un]bounded Arrays; adopted in KonaMarshall Clow2019-02-263-0/+171
| | | | llvm-svn: 354891
* Fix short options syntax in Minidump testTatyana Krasnukha2019-02-261-20/+20
| | | | llvm-svn: 354890
* [InstCombine] remove duplicate (but not updated) tests; NFCSanjay Patel2019-02-261-134/+0
| | | | | | | Not sure how it happened, but rL354886 was a duplicate of rL354881, but not updated with rL354887. llvm-svn: 354889
* [compiler-rt] Disable failing test on darwin during investigation.Clement Courbet2019-02-261-0/+1
| | | | | | | | | | | | | | /Users/buildslave/jenkins/workspace/clang-stage1-configure-RA/llvm/projects/compiler-rt/test/asan/TestCases/Posix/bcmp_test.cc:14:12: error: CHECK: expected string not found in input // CHECK: {{#1.*bcmp}} ^ <stdin>:2:57: note: scanning from here ==34677==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7ffee93777c4 at pc 0x0001068a7285 bp 0x7ffee9377770 sp 0x7ffee9376ef8 ^ <stdin>:6:20: note: possible intended match here #2 0x106888e77 in main bcmp_test.cc:12 ^ llvm-svn: 354888
* [InstCombine] canonicalize more unsigned saturated add with 'not'Sanjay Patel2019-02-262-24/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Yet another pattern variation suggested by: https://bugs.llvm.org/show_bug.cgi?id=14613 There are 8 more potential commuted patterns here on top of the 8 that were already handled (rL354221, rL354276, rL354393). We have the obvious commute of the 'add' + commute of the cmp predicate/operands (ugt/ult) + commute of the select operands: Name: base %notx = xor i32 %x, -1 %a = add i32 %notx, %y %c = icmp ult i32 %x, %y %r = select i1 %c, i32 -1, i32 %a => %c2 = icmp ult i32 %a, %y %r = select i1 %c2, i32 -1, i32 %a Name: ugt %notx = xor i32 %x, -1 %a = add i32 %notx, %y %c = icmp ugt i32 %y, %x %r = select i1 %c, i32 -1, i32 %a => %c2 = icmp ult i32 %a, %y %r = select i1 %c2, i32 -1, i32 %a Name: commute select %notx = xor i32 %x, -1 %a = add i32 %notx, %y %c = icmp ult i32 %y, %x %r = select i1 %c, i32 %a, i32 -1 => %c2 = icmp ult i32 %a, %y %r = select i1 %c2, i32 -1, i32 %a Name: ugt + commute select %notx = xor i32 %x, -1 %a = add i32 %notx, %y %c = icmp ugt i32 %x, %y %r = select i1 %c, i32 %a, i32 -1 => %c2 = icmp ult i32 %a, %y %r = select i1 %c2, i32 -1, i32 %a https://rise4fun.com/Alive/den llvm-svn: 354887
* [InstCombine] add more tests for saturated add; NFCSanjay Patel2019-02-261-0/+134
| | | | llvm-svn: 354886
* [libclang] Avoid crashing when getting layout info of an undeduced type.Emilio Cobos Alvarez2019-02-264-13/+46
| | | | | | | | | | When the type is not deducible, return an error instead of crashing. This fixes https://bugs.llvm.org/show_bug.cgi?id=40813. Differential Revision: https://reviews.llvm.org/D58569 llvm-svn: 354885
* [DAG] Fix constant store folding to handle non-byte sizes.Nirav Dave2019-02-264-19/+34
| | | | | | | | | | | | | | | | Avoid crashes from zero-byte values due to sub-byte store sizes. Reviewers: uabelho, courbet, rnk Reviewed By: courbet Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58626 llvm-svn: 354884
* Fix error handling in Options::ParseTatyana Krasnukha2019-02-261-2/+3
| | | | | | | Moved `if (error.Fail())` to correct place to catch all faulty cases such as "unknown or ambiguous option" which was ignored before. llvm-svn: 354883
* [mips] Emit `.module softfloat` directiveSimon Atanasyan2019-02-263-3/+15
| | | | | | | This change fixes crash on an assertion in case of using `soft float` ABI for mips32r6 target. llvm-svn: 354882
* [InstCombine] add more tests for saturated add; NFCSanjay Patel2019-02-261-0/+134
| | | | llvm-svn: 354881
* [clang-format] SpaceBeforeParens for lambda expressionsAndrew Ng2019-02-262-1/+5
| | | | | | | | | Add support for lambda expressions to the SpaceBeforeParens formatting option. Differential Revision: https://reviews.llvm.org/D58241 llvm-svn: 354880
* [clangd] Index UsingDeclsKadir Cetinkaya2019-02-264-8/+35
| | | | | | | | | | | | | | | | Summary: D58340 enables indexing of USRs, this makes sure test in clangd are aligned with the change Reviewers: hokein Subscribers: ilya-biryukov, ioeric, MaskRay, jkorous, arphaman, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58341 llvm-svn: 354879
* [clang][Index] Visit UsingDecls and generate USRs for themKadir Cetinkaya2019-02-265-3/+30
| | | | | | | | | | | | | | | | | Summary: Add indexing of UsingDecl itself. Also enable generation of USRs for UsingDecls, using the qualified name of the decl. Reviewers: ilya-biryukov, akyrtzi Subscribers: arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58340 llvm-svn: 354878
* [MCA] Always check if scheduler resources are unavailable when reporting ↵Andrea Di Biagio2019-02-264-17/+30
| | | | | | | | | | | dispatch stalls. Dispatch stall cycles may be associated to multiple dispatch stall events. Before this patch, each stall cycle was associated with a single stall event. This patch also improves a couple of code comments, and adds a helper method to query the Scheduler for dispatch stalls. llvm-svn: 354877
* [yaml2obj][obj2yaml] - Add support for the architecture specific dynamic tags.George Rimar2019-02-263-4/+302
| | | | | | | | | | | This allows tools to parse/dump the architecture specific tags like DT_MIPS_*, DT_PPC64_* and DT_HEXAGON_* Also fixes a bug in DynamicTags.def which was revealed in this patch. Differential revision: https://reviews.llvm.org/D58667 llvm-svn: 354876
* revert r354873 as this breaks lldb builds.Pierre Gousseau2019-02-2611-325/+145
| | | | llvm-svn: 354875
* [Sanitizer] Add interceptor for pthread_sigmaskPavel Labath2019-02-265-0/+31
| | | | | | | | | | | | | | | | | | | | | | Summary: pthread_sigmask is just like sigprocmask, except that its behavior in multithreaded programs is explicitly specified. Sanitizers were lacking a common interceptor for pthread_sigmask (although some specific sanitizers defined custom version), which lead to false positives (at least in msan) when using this function. The interceptor implementation, and its test are based on the equivalent code for sigprocmask. Reviewers: eugenis, vitalybuka Subscribers: kubamracek, delcypher, jfb, jdoerfert, llvm-commits, #sanitizers Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D58382 llvm-svn: 354874
* [Driver] Allow enum SanitizerOrdinal to represent more than 64 different ↵Pierre Gousseau2019-02-2611-145/+325
| | | | | | | | | | | | | sanitizer checks, NFC. enum SanitizerOrdinal has reached maximum capacity, this change extends the capacity to 128 sanitizer checks. This can eventually allow us to add gcc 8's options "-fsanitize=pointer-substract" and "-fsanitize=pointer-compare". Fixes: https://llvm.org/PR39425 Differential Revision: https://reviews.llvm.org/D57914 llvm-svn: 354873
* [AArch64] Add arithmetic zext bswap tests.Simon Pilgrim2019-02-261-0/+30
| | | | | | As requested on D58017. llvm-svn: 354872
* [llvm-objdump] Add `Version Definitions` dumperXing GUO2019-02-262-3/+85
| | | | | | | | | | | | | | | | Summary: `llvm-objdump` needs a `Version Definitions` dumper. Reviewers: grimar, jhenderson Reviewed By: grimar, jhenderson Subscribers: rupprecht, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58615 llvm-svn: 354871
* [llvm-objdump] Implement -Mreg-names-raw/-std options.Igor Kudrin2019-02-268-11/+86
| | | | | | | | | | | | | | The --disassembler-options, or -M, are used to customize the disassembler and affect its output. The two implemented options allow selecting register names on ARM: * With -Mreg-names-raw, the disassembler uses rNN for all registers. * With -Mreg-names-std it prints sp, lr and pc for r13, r14 and r15, which is the default behavior of llvm-objdump. Differential Revision: https://reviews.llvm.org/D57680 llvm-svn: 354870
* [AArch64] Add 'free' zext bswap tests.Simon Pilgrim2019-02-261-0/+28
| | | | | | As requested on D58017. llvm-svn: 354869
* [ARM] Add Cortex-M35PLuke Cheeseman2019-02-265-1/+42
| | | | | | | | | | - Add LLVM backend support for Cortex-M35P - Documentation can be found at https://developer.arm.com/products/processors/cortex-m/cortex-m35p Differentail Revision: https://reviews.llvm.org/D57763 llvm-svn: 354868
* [LegalizeDAG] Use APInt::getSplat helper to create bitreverse masks. NFCI.Simon Pilgrim2019-02-261-10/+6
| | | | llvm-svn: 354867
* [LegalizeDAG] Expand SADDO/SSUBO using SADDSAT/SSUBSAT (PR37763)Simon Pilgrim2019-02-263-322/+143
| | | | | | | | | | If SADDSAT/SSUBSAT are legal, then we can expand SADDO/SSUBO by performing a ADD/SUB and a SADDO/SSUBO and then compare the results. I looked at doing this for UADDO/USUBO as well but as we don't have to do as many range comparisons I didn't see any/much benefit. Differential Revision: https://reviews.llvm.org/D58637 llvm-svn: 354866
* [clangd] Update docs to mention YCM integration and new LSP featuresKadir Cetinkaya2019-02-261-14/+14
| | | | | | | | | | | | | | Reviewers: gribozavr Reviewed By: gribozavr Subscribers: ilya-biryukov, ioeric, MaskRay, jkorous, arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D56718 llvm-svn: 354865
* [CodeComplete] Propagate preferred type for function arguments in more casesIlya Biryukov2019-02-269-98/+153
| | | | | | | | | | | | | | | | | | | | | Summary: See the added test for some new cases. This change also removes special code completion calls inside the ParseExpressionList function now that we properly propagate expected type to the function responsible for parsing elements of the expression list (ParseAssignmentExpression). Reviewers: kadircet Reviewed By: kadircet Subscribers: xbolva00, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58541 llvm-svn: 354864
* [AMDGPU] Regenerate bswap/bitreverse tests.Simon Pilgrim2019-02-262-96/+1621
| | | | | | Make codegen changes more obvious in D58017 llvm-svn: 354863
* [llvm-exegesis] Teach llvm-exegesis to handle instructions with multiple ↵Clement Courbet2019-02-262-17/+53
| | | | | | | | | | | | | | tied variables. Reviewers: gchatelet Subscribers: tschuett, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58285 llvm-svn: 354862
* CodeGen: Explicitly initialize structure padding in the ↵Alexander Potapenko2019-02-262-25/+232
| | | | | | | | | | | | | | | -ftrivial-auto-var-init mode When generating initializers for local structures in the -ftrivial-auto-var-init mode, explicitly wipe the padding bytes with either 0x00 or 0xAA. This will allow us to automatically handle the padding when splitting the initialization stores (see https://reviews.llvm.org/D57898). Reviewed at https://reviews.llvm.org/D58188 llvm-svn: 354861
* [llvm-objcopy] Add --set-start, --change-start and --adjust-startEugene Leviant2019-02-266-1/+105
| | | | | | Differential revision: https://reviews.llvm.org/D58173 llvm-svn: 354854
* [compiler-rt] disable asan bcmp tests on android.Clement Courbet2019-02-261-0/+1
| | | | | | | | Android does not have bcmp. sanitizer-x86_64-linux-android: run instrumented asan tests [arm/aosp_marlin-userdebug/PI] - stdio llvm-svn: 354853
* [compiler-rt] Fix test broken by r354851.Clement Courbet2019-02-262-2/+2
| | | | | | | error: CHECK: expected string not found in input // CHECK: Uninitialized bytes in __interceptor_memcmp at offset 3 llvm-svn: 354852
* [compiler-rt] Intercept the bcmp() function.Clement Courbet2019-02-266-26/+87
| | | | | | | | | | | | | | | | | | | | | Summary: I have not introduced a separate hook for `bcmp()` as I don't think there should be any reason for a sanitizer to treat it differently from `memcmp()`. This is only enabled when building on POSIX with GNU extensions. Context: this is to avoid losing coverage when emitting `bcmp() == 0` instead of `memcmp() == 0` in llvm, see https://reviews.llvm.org/D56593. Reviewers: mgorny, krytarowski, vitalybuka, dvyukov Subscribers: kubamracek, dberris, delcypher, jdoerfert, #sanitizers, llvm-commits, jyknight Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D58379 llvm-svn: 354851
* [ThinLTO] Use defined node and edge order when dumping DOT fileEugene Leviant2019-02-263-73/+66
| | | | | | Differential revision: https://reviews.llvm.org/D58631 llvm-svn: 354850
* Revert "Improve "llvm-nm -f sysv" output for Elf files"Vlad Tsyrklevich2019-02-267-88/+19
| | | | | | | This reverts commit r354833, it was causing ASan test failures on sanitizer-x86_64-linux-fast. llvm-svn: 354849
OpenPOWER on IntegriCloud