summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [X86][3DNow] Regenerate intrinsics testsSimon Pilgrim2018-02-201-26/+693
| | | | llvm-svn: 325609
* [WebAssembly] Remove unused headerSam Clegg2018-02-202-2/+0
| | | | | | | | | This header used to be needed here for the `OutRelocation` struct but that no longer exists. Differential Revision: https://reviews.llvm.org/D43516 llvm-svn: 325608
* [IRBuilder] fix CreateMaxNum to actually produce maxnum (PR36454)Sanjay Patel2018-02-202-1/+18
| | | | | | | | | The bug was introduced here: https://reviews.llvm.org/rL296409 ...but the patch doesn't use maxnum and nothing else in trunk has tried since then, so the bug went unnoticed. llvm-svn: 325607
* [Hexagon] Handle *Low8 register classes in early if-conversionKrzysztof Parzyszek2018-02-202-0/+29
| | | | llvm-svn: 325606
* [SLP] Fix tests checks, NFC.Alexey Bataev2018-02-205-74/+249
| | | | llvm-svn: 325605
* [X86] Correct SHRUNKBLEND creation to work correctly when there are multiple ↵Craig Topper2018-02-202-35/+23
| | | | | | | | | | | | | | uses of the condition. SimplifyDemandedBits forces the demanded mask to all 1s if the node has multiple uses, unless the AssumeSingleUse flag is set. So previously we were only really likely to simplify something if the condition had a single use. And on the off chance we did simplify with multiple uses the demanded mask being used was all ones so there was no reason to create a shrunkblend. This patch now checks that the condition is only used by selects first, and then sets the AssumeSingleUse flag for the simplifcation. Then we convert the selects to shrunkblend, and finally replace condition. Differential Revision: https://reviews.llvm.org/D43446 llvm-svn: 325604
* [WebAssembly] Remove InputChunk from Symbol baseclassSam Clegg2018-02-202-36/+44
| | | | | | | | | | Instead include InputFuction and InputSegment directly in the subclasses that use them (DefinedFunction and DefinedGlobal). Differential Revision: https://reviews.llvm.org/D43493 llvm-svn: 325603
* [SelectionDAG] Add LegalTypes flag to getShiftAmountTy. Use it to unify and ↵Craig Topper2018-02-205-20/+54
| | | | | | | | | | | | | | | | | | simplify DAGCombiner and simplifySetCC code and fix a bug. DAGCombiner and SimplifySetCC both use getPointerTy for shift amounts pre-legalization. DAGCombiner uses a single helper function to hide this. SimplifySetCC does it in multiple places. This patch adds a defaulted parameter to getShiftAmountTy that can make it return getPointerTy for scalar types. Use this parameter to simplify the SimplifySetCC and DAGCombiner. Additionally, there were two places in SimplifySetCC that were creating shifts using the target's preferred shift amount pre-legalization. If the target uses a narrow type and the type is illegal, this can cause SimplfiySetCC to create a shift with an amount that can't represent all possible shift values for the type. To fix this we should use pointer type there too. Alternatively we could make getScalarShiftAmountTy for each target return a safe value for large types as proposed in D43445. And maybe we should still do that, but fixing the SimplifySetCC code keeps other targets from tripping over this in the future. Fixes PR36250. Differential Revision: https://reviews.llvm.org/D43449 llvm-svn: 325602
* [X86] Promote 16-bit cmovs to 32-bitsCraig Topper2018-02-207-34/+86
| | | | | | | | | | This allows us to avoid an opsize prefix. And forcing some move immediates to i32 avoids a length changing prefix on those instructions. This mostly replaces the existing combine we had for zext/sext+cmov of constants. I left in a case for sign extending a 32 bit cmov of constants to 64 bits. Differential Revision: https://reviews.llvm.org/D43327 llvm-svn: 325601
* [dsymutil] Correctly handle DW_TAG_labelJonas Devlieghere2018-02-203-1/+44
| | | | | | | | | This patch contains logic for handling DW_TAG_label that's present in darwin's dsymutil implementation, but not yet upstream. Differential revision: https://reviews.llvm.org/D43438 llvm-svn: 325600
* [vim] Recognize more FileCheck commentsMikhail Maltsev2018-02-201-0/+1
| | | | | | | | | | | | | | | | | Summary: Currently vim syntax highlighting recognizes 'CHECK:' as a special comment, but not CHECK-DAG, CHECK-NOT and other CHECKs. This patch adds rules for these comments. Reviewers: chandlerc, compnerd, rogfer01 Reviewed By: rogfer01 Subscribers: rogfer01, llvm-commits Differential Revision: https://reviews.llvm.org/D43289 llvm-svn: 325599
* [WebAssembly] Check signatures of weakly defined funtions tooSam Clegg2018-02-203-0/+26
| | | | | | | | Subscribers: jfb, dschuff, jgravelle-google, aheejin, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D43492 llvm-svn: 325598
* [InstCombine] remove unneeded dyn_cast to prevent unused variable warningSanjay Patel2018-02-201-2/+1
| | | | llvm-svn: 325597
* [clangd] Fix formatting in XRefs.cppSimon Marchi2018-02-201-2/+2
| | | | | | This is also to test my commit access. llvm-svn: 325596
* [InstCombine] remove compound fdiv pattern foldsSanjay Patel2018-02-201-27/+1
| | | | | | | | | | | | | | These are fdiv-with-constant-divisor, so they already become reciprocal multiplies. The last gap for vector ops should be closed with rL325590. It's possible that we're missing folds for some edge cases with denormal intermediate constants after deleting these, but there are no tests for those patterns, and it would be better to handle denormals more consistently (and less conservatively) as noted in TODO comments. llvm-svn: 325595
* PR36442: Correct description of -fsplit-dwarf-inliningDavid Blaikie2018-02-201-1/+1
| | | | llvm-svn: 325594
* Stop linking sanitized applications with -lutil and -lkvm on NetBSDKamil Rytarowski2018-02-201-6/+0
| | | | | | | | | The proper approach is to rebuild libutil and libkvm with a desired sanitizer. An alternative approach to reimplement these functions (and other ones like curses(3), editline(3) etc) does not scale and enforces linkage every single binary with these libraries. llvm-svn: 325593
* [InstCombine] fold fdiv with non-splat divisor to fmul: X/C --> X * (1/C)Sanjay Patel2018-02-205-25/+49
| | | | llvm-svn: 325590
* [mips] Correct the definition of cvt.d.wSimon Dardis2018-02-203-7/+10
| | | | | | | | An upcoming patch D41434, changes the ordering of the matcher table for assembly. This patch corrects the definition of the normal MIPS cvt.d.w not to be available in microMIPS. llvm-svn: 325589
* Add new interceptor: strmode(3)Kamil Rytarowski2018-02-203-0/+35
| | | | | | | | | | | | | | | | | | | Summary: strmode - convert inode status information into a symbolic string Sponsored by <The NetBSD Foundation> Reviewers: joerg, vitalybuka Reviewed By: vitalybuka Subscribers: kubamracek, llvm-commits, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D43485 llvm-svn: 325588
* Add new interceptor: fgetln(3)Kamil Rytarowski2018-02-203-0/+41
| | | | | | | | | | | | | | | | | | | Summary: fgetln - get a line from a stream Sponsored by <The NetBSD Foundation> Reviewers: vitalybuka, joerg Reviewed By: vitalybuka Subscribers: llvm-commits, kubamracek, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D43482 llvm-svn: 325587
* Stop intercepting forkpty(3) and openpty(3) on NetBSDKamil Rytarowski2018-02-201-2/+16
| | | | | | | | | | | | | | | | | | | | | | | Summary: forkpty(3) and openpty(3) are part of `-lutil` and we don't intend to reimplement this system library in sanitizers. Everybody using these functions will need to use a precompiled library against MSan or other desired sanitizer. Restrict these functions to Linux-only. Sponsored by <The NetBSD Foundation> Reviewers: joerg, vitalybuka Reviewed By: vitalybuka Subscribers: llvm-commits, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D43490 llvm-svn: 325585
* [DEBUGINFO] Add support for emission of the inlined strings.Alexey Bataev2018-02-204-0/+66
| | | | | | | | | | | | | | Summary: Patch adds an option for emission of inlined strings rather than .debug_str section. Reviewers: echristo, jlebar Subscribers: eraman, llvm-commits, JDevlieghere Differential Revision: https://reviews.llvm.org/D43390 llvm-svn: 325583
* [PowerPC] Reduce stack frame for fastcc functions by only allocating ↵Lei Huang2018-02-202-2/+152
| | | | | | | | | | | | parameter save area when needed Current implementation always allocates the parameter save area conservatively for fastcc functions. There is no reason to allocate the parameter save area if all the parameters can be passed via registers. Differential Revision: https://reviews.llvm.org/D42602 llvm-svn: 325581
* [Hexagon] Fix alignment calculation of stack objects in Hexagon bit trackerKrzysztof Parzyszek2018-02-204-6/+24
| | | | llvm-svn: 325580
* [X86] Regenerate XOR testsSimon Pilgrim2018-02-201-128/+422
| | | | llvm-svn: 325579
* [VectorLegalizer] Fix uint64_t typo in ExpandUINT_TO_FLOAT (PR36391)Simon Pilgrim2018-02-201-1/+1
| | | | | | | | ExpandUINT_TO_FLOAT can accept vXi32 or vXi64 inputs, so we need to use a uint64_t shift to generate the 2^(BW/2) constant. No test case unfortunately as no upstream target uses this, but its affecting a downstream target. llvm-svn: 325578
* Revert r325375 "[MS] Make constexpr static data members implicitly inline"Hans Wennborg2018-02-202-37/+5
| | | | | | | | | | | | | | | | This broke Clang bootstrap on Windows, PR36453. > This handles them exactly the same way that we handle const integral > static data members with inline definitions, which is what MSVC does. > > As a follow-up, now that we have a way to mark variables inline in the > AST, we should consider marking them implicitly inline there instead of > only treating them as inline in CodeGen. Unfortunately, this breaks a > lot of dllimport test cases, so that is future work for now. > > Fixes PR36125. llvm-svn: 325576
* [CodeGen] Fix generation of TBAA tags for may-alias accessesIvan A. Kosarev2018-02-204-32/+64
| | | | | | | | | | | This patch fixes creating TBAA access descriptors for may_alias-marked access types. Currently, for such types we generate ordinary descriptors with char as its access type. The patch changes this to produce proper may-alias descriptors. Differential Revision: https://reviews.llvm.org/D42366 llvm-svn: 325575
* [clangd] Dump stack on crashSam McCall2018-02-201-0/+1
| | | | llvm-svn: 325574
* [ARM] Mark -1 as cheap in xor's for thumb1David Green2018-02-202-0/+200
| | | | | | | | | | We can always convert xor %a, -1 into MVN, even in thumb 1 where the -1 would not otherwise be considered a cheap constant. This prevents the -1's from being pulled out into constants and potentially hoisted. Differential Revision: https://reviews.llvm.org/D43451 llvm-svn: 325573
* [clang-tidy] Replace the usage of std::uncaught_exception with ↵Gabor Horvath2018-02-208-0/+294
| | | | | | | | | | std::uncaught_exceptions Patch by: Daniel Kolozsvari! Differential Revision: https://reviews.llvm.org/D40787 llvm-svn: 325572
* clang-cl: Make /d1PP an alias for -dD (PR36446)Hans Wennborg2018-02-202-0/+5
| | | | llvm-svn: 325571
* Avoid dirtying the source tree in breakpoint command testsPavel Labath2018-02-204-92/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The paralelization patch exposed a bunch of cases where we were still touching the source tree (as these tests were now stepping on each others toes and being flaky). This patch removes such issues from breakpoint command tests. Since the only reason they were creating files was to indirectly test whether the breakpoint commands got executed (and plumbing the full build tree path to all places that needed it would be messy) I decided to modify the tests to check for a different side effect instead: modification of a global variable. This also makes the code simpler as checking the value of the global variable is easier, and there is nothing to clean up. As the tests aren't really doing anything debug-info related, I took the opportunity to also mark them as NO_DEBUG_INFO_TESTCASEs. Reviewers: jingham, aprantl Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D43464 llvm-svn: 325570
* [llvm-mc] - Produce R_X86_64_PLT32 for "call/jmp foo".George Rimar2018-02-2014-21/+60
| | | | | | | | | | | For instructions like call foo and jmp foo patch changes relocation produced from R_X86_64_PC32 to R_X86_64_PLT32. Relocation can be used as a marker for 32-bit PC-relative branches. Linker will reduce PLT32 relocation to PC32 if function is defined locally. Differential revision: https://reviews.llvm.org/D43383 llvm-svn: 325569
* Handle typeof() expressionsJonas Devlieghere2018-02-202-17/+78
| | | | | | | | | | | | | | | | | | | | Before this patch, LLDB was not able to evaluate expressions that resulted in a value with a typeof- or decltype-type. This patch fixes that. Before: (lldb) p int i; __typeof__(i) j = 1; j (typeof (i)) $0 = After: (lldb) p int i; __typeof__(i) j = 1; j (typeof (i)) $0 = 1 Differential revision: https://reviews.llvm.org/D43471 rdar://37461520 llvm-svn: 325568
* [AMDGPU] stop buffer_store being moved illegallyTim Renouf2018-02-202-6/+55
| | | | | | | | | | | | | | | Summary: The machine instruction scheduler was illegally moving a buffer store past a buffer load with the same descriptor and offset. Fixed by marking buffer ops as mayAlias and isAliased. This may be overly conservative, and we may need to revisit. Subscribers: arsenm, kzhuravl, wdng, nhaehnle, yaxunl, dstuttard, t-tye, llvm-commits Differential Revision: https://reviews.llvm.org/D43332 Change-Id: Iff3173d9e0653e830474546276ab9d30318b8ef7 llvm-svn: 325567
* clang-format plugin: Add missing semicolon in list of file extensions (PR36383)Hans Wennborg2018-02-201-1/+1
| | | | llvm-svn: 325566
* [MC] - Don't crash on unclosed frame.George Rimar2018-02-202-3/+14
| | | | | | | | | | | | | | | | llvm-mc can crash when there is cfi_startproc without cfi_end_proc: .text .globl foo foo: .cfi_startproc Testcase shows the issue, patch fixes it. Differential revision: https://reviews.llvm.org/D43456 llvm-svn: 325564
* [X86][CET]: Adding full coverage of MC encoding for the CET instructions.<NFC>Gadi Haber2018-02-202-0/+300
| | | | | | | | | | | | NFC. Adding MC regressions tests to cover the CET instructions. This patch is part of a larger task to cover MC encoding of all X86 isa sets started in revision: https://reviews.llvm.org/D39952 Reviewers: zvi, craig.topper, RKSimon, AndreiGrischenko, oren_ben_simhon Differential Revision: https://reviews.llvm.org/D41329 Change-Id: I9c133d4ba07508ce8fd738a1230edd586e2c2f1b llvm-svn: 325561
* [X86] Remove mask from 512 bit pmulhrsw/pmulhw/pmulhuw builtins.Craig Topper2018-02-203-58/+47
| | | | | | We now use a vselect node in IR around an unmasked builtin. This makes it consistent with the 128 and 256 bit versions. llvm-svn: 325560
* [X86] Add 512-bit unmasked pmulhrsw/pmulhw/pmulhuw intrinsics. Remove and ↵Craig Topper2018-02-207-105/+310
| | | | | | | | auto upgrade 128/256/512 bit masked pmulhrsw/pmulhw/pmulhuw intrinsics. The 128 and 256 bit versions were already not used by clang. This adds an equivalent unmasked 512 bit version. Then autoupgrades all sizes to use unmasked intrinsics plus select. llvm-svn: 325559
* Use isl::manage_copy to simplify calls to isl::manage(isl_.._copy())Tobias Grosser2018-02-209-49/+37
| | | | | | | | | | | As part of this cleanup a couple of unnecessary isl::manage(obj.copy()) pattern are eliminated as well. We checked for all potential cleanups by scanning for: "grep -R isl::manage\( lib/ | grep copy" llvm-svn: 325558
* Update isl to isl-0.18-1047-g4a20ef8Tobias Grosser2018-02-20170-5446/+4116
| | | | | | | | | | | | | | | | | | This update: - Removes several deprecated functions (e.g., isl_band). - Improves the pretty-printing of sets by detecting modulos and "false" equalities. - Minor improvements to coalescing and increased robustness of the isl scheduler. This update does not yet include isl commit isl-0.18-90-gd00cb45 (isl_pw_*_alloc: add missing check for compatible spaces, Wed Sep 6 12:18:04 2017 +0200), as this additional check is too tight and unfortunately causes two test case failures in Polly. A patch has been submitted to isl and will be included in the next isl update for Polly. llvm-svn: 325557
* Fix broken isl-noexceptions.h path in update-isl scriptTobias Grosser2018-02-201-2/+2
| | | | llvm-svn: 325556
* Update isl C++ bindings to latest version of islTobias Grosser2018-02-201-276/+954
| | | | llvm-svn: 325555
* Do not call band_list().dump()Tobias Grosser2018-02-201-1/+0
| | | | | | This is in preparation for the removal of band_list from isl. llvm-svn: 325554
* [Sema] Fix -Wunused-variableSam McCall2018-02-201-1/+0
| | | | llvm-svn: 325553
* [X86] Remove GCCBuiltin from a bunch of intrinsics that aren't used by clang ↵Craig Topper2018-02-201-30/+26
| | | | | | and should be removed. llvm-svn: 325552
* Report fatal error in the case of out of memorySerge Pavlov2018-02-2018-29/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the second part of recommit of r325224. The previous part was committed in r325426, which deals with C++ memory allocation. Solution for C memory allocation involved functions `llvm::malloc` and similar. This was a fragile solution because it caused ambiguity errors in some cases. In this commit the new functions have names like `llvm::safe_malloc`. The relevant part of original comment is below, updated for new function names. Analysis of fails in the case of out of memory errors can be tricky on Windows. Such error emerges at the point where memory allocation function fails, but manifests itself when null pointer is used. These two points may be distant from each other. Besides, next runs may not exhibit allocation error. In some cases memory is allocated by a call to some of C allocation functions, malloc, calloc and realloc. They are used for interoperability with C code, when allocated object has variable size and when it is necessary to avoid call of constructors. In many calls the result is not checked for null pointer. To simplify checks, new functions are defined in the namespace 'llvm': `safe_malloc`, `safe_calloc` and `safe_realloc`. They behave as corresponding standard functions but produce fatal error if allocation fails. This change replaces the standard functions like 'malloc' in the cases when the result of the allocation function is not checked for null pointer. Finally, there are plain C code, that uses malloc and similar functions. If the result is not checked, assert statement is added. Differential Revision: https://reviews.llvm.org/D43010 llvm-svn: 325551
OpenPOWER on IntegriCloud