summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [X86][AVX] Enabled SMUL_LOHI/UMUL_LOHI v8i32 vectors on AVX1 targetsSimon Pilgrim2016-03-263-352/+127
| | | | | | Correct splitting of v8i32 vectors into v4i32 vectors to prevent scalarization llvm-svn: 264517
* Revert "NFC: static_assert instead of comment"JF Bastien2016-03-261-3/+1
| | | | | | | | | | | This reverts commit fa36fcff16c7d4f78204d6296bf96c3558a4a672. Causes the following Windows failure: C:\Buildbot\Slave\llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast\llvm.src\lib\CodeGen\MachineInstr.cpp(762): error C2338: must be trivially copyable to memmove llvm-svn: 264516
* NFC: static_assert instead of commentJF Bastien2016-03-261-1/+3
| | | | | | | | | | Summary: isPodLike is as close as we have for is_trivially_copyable. Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D18483 llvm-svn: 264515
* Generalize the domain complexity restrictionsJohannes Doerfert2016-03-266-7/+196
| | | | | | | | | | | | | | | | | | This patch applies the restrictions on the number of domain conjuncts also to the domain parts of piecewise affine expressions we generate. To this end the wording is change slightly. It was needed to support complex additions featuring zext-instructions but it also fixes PR27045. lnt profitable runs reports only little changes that might be noise: Compile Time: Polybench/[...]/2mm +4.34% SingleSource/[...]/stepanov_container -2.43% Execution Time: External/[...]/186_crafty -2.32% External/[...]/188_ammp -1.89% External/[...]/473_astar -1.87% llvm-svn: 264514
* [Cxx1z-constexpr-lambda-P0170R1] Support parsing of constexpr specifier ↵Faisal Vali2016-03-269-12/+183
| | | | | | | | | | | | | | | | | | | | | | (and its inference) on lambda expressions Support the constexpr specifier on lambda expressions - and support its inference from the lambda call operator's body. i.e. auto L = [] () constexpr { return 5; }; static_assert(L() == 5); // OK auto Implicit = [] (auto a) { return a; }; static_assert(Implicit(5) == 5); We do not support evaluation of lambda's within constant expressions just yet. Implementation Strategy: - teach ParseLambdaExpressionAfterIntroducer to expect a constexpr specifier and mark the invented function call operator's declarator's decl-specifier with it; Have it emit fixits for multiple decl-specifiers (mutable or constexpr) in this location. - for cases where constexpr is not explicitly specified, have buildLambdaExpr check whether the invented function call operator satisfies the requirements of a constexpr function, by calling CheckConstexprFunctionDecl/Body. Much obliged to Richard Smith for his patience and his care, in ensuring the code is clang-worthy. llvm-svn: 264513
* [X86][AVX] Enabled MULHS/MULHU v16i16 vectors on AVX1 targetsSimon Pilgrim2016-03-263-694/+54
| | | | | | | | Correct splitting of v16i16 vectors into v8i16 vectors to prevent scalarization Differential Revision: http://reviews.llvm.org/D18307 llvm-svn: 264512
* [X86][SSE] Add MULHS/MULHU custom lowering for i8 vectorsSimon Pilgrim2016-03-265-5135/+819
| | | | | | | | Currently this is to mainly to prevent scalarization of integer division by constants. Differential Revision: http://reviews.llvm.org/D18307 llvm-svn: 264511
* [X86][SSE] Added v64i8 vector integer multiply testsSimon Pilgrim2016-03-261-0/+946
| | | | llvm-svn: 264510
* [X86][AVX512BW] AVX512BW can sign-extend v32i8 to v32i16 for simpler v32i8 ↵Simon Pilgrim2016-03-262-20/+10
| | | | | | | | multiplies. Only pre-AVX512BW targets need to split v32i8 vectors. llvm-svn: 264509
* [PowerPC] Disable the CTR optimization in the presence of {min,max}numDavid Majnemer2016-03-262-0/+46
| | | | | | | | | The minnum and maxnum intrinsics get lowered to libcalls which invalidates the CTR optimization. This fixes PR27083. llvm-svn: 264508
* [X86][SSE] Refreshed vector integer multiply testsSimon Pilgrim2016-03-261-121/+485
| | | | | | | | Add all 256-bit vector tests. Added AVX512F/AVX512BW test targets. Renamed tests something more meaningful. llvm-svn: 264507
* [X86][SSE] Don't duplicate Lower256IntArith functionality in LowerMul. NFC.Simon Pilgrim2016-03-261-13/+5
| | | | | | LowerMul v32i8 on AVX2 needs to split the 256-bit sources to allow sign-extension back to v16i16 to occur. Since this is basically the same as Lower256IntArith we simplify by using that here instead. llvm-svn: 264506
* Minor code cleanup. NFC.Junmo Park2016-03-261-1/+1
| | | | llvm-svn: 264505
* [Power9] Implement new altivec instructions: permute, count zero, extend ↵Chuang-Yu Cheng2016-03-265-0/+368
| | | | | | | | | | | | | | | | | | | | | sign, negate, parity, shift/rotate, mul10 This change implements the following vector operations: - vclzlsbb vctzlsbb vctzb vctzd vctzh vctzw - vextsb2w vextsh2w vextsb2d vextsh2d vextsw2d - vnegd vnegw - vprtybd vprtybq vprtybw - vbpermd vpermr - vrlwnm vrlwmi vrldnm vrldmi vslv vsrv - vmul10cuq vmul10uq vmul10ecuq vmul10euq 28 instructions Thanks Nemanja, Kit for invaluable hints and discussion! Reviewers: hal, nemanja, kbarton, tjablin, amehsan Phabricator: http://reviews.llvm.org/D15887 llvm-svn: 264504
* ThinLTO: use the callgraph from the combined index to drive the FunctionImporterMehdi Amini2016-03-267-270/+324
| | | | | | | | | | | | | | | | | | Summary: Now that the summary contains the full reference/call graph, we can replace the existing function importer that loads and inspect the IR to iteratively walk the call graph by a traversal based purely on the summary information. Decouple the actual importing decision from any IR manipulation. Reviewers: tejohnson Subscribers: llvm-commits, joker.eph Differential Revision: http://reviews.llvm.org/D18343 From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 264503
* abtest: Cleanup, improve commentsMatthias Braun2016-03-261-38/+48
| | | | llvm-svn: 264502
* [libprofile] Adjust dummy condition to be more forgiving.Sean Silva2016-03-261-1/+1
| | | | | | | | | | | On PS4, we have to fake environment variables by passing extra command line arguments, so the dummy test `argc > 1` was failing. The condition is just a dummy condition that the compiler can't fold away, so the number is arbitrary as long as the condition is false. Increase the number it compares against. llvm-svn: 264491
* [libprofile] Add some missing `env` prefixes on commands.Sean Silva2016-03-263-3/+3
| | | | llvm-svn: 264490
* Rename ModuleSummaryIndex::modPathStringEntries() into modulePaths()Mehdi Amini2016-03-263-7/+8
| | | | | | | It now return the map instead of an iterator. From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 264489
* Stop depending on the keys in a hash table being in a particular order.Richard Smith2016-03-261-77/+83
| | | | llvm-svn: 264488
* Stop testing the unspecified order in which the OnDiskHashTable stores entries.Richard Smith2016-03-263-57/+71
| | | | llvm-svn: 264487
* Don't force OnDiskHashTables to have a minimum of 64 buckets. That'sRichard Smith2016-03-261-0/+16
| | | | | | | | | | preposterously large for some lookup tables -- in C++ classes generated by template instantiation, it's very common for the number of lookup results to be either 1 or 2. This reduces size of a libstdc++ module by 7-15%. llvm-svn: 264486
* When we import the definition for a Tagdecl, propagate its completeness too.Sean Callanan2016-03-261-3/+14
| | | | | | | | | | | The ASTImporter completes the full definiton for a TagDecl in several places, including the type-deport logic. When this happens, we should also propagate the bit that says that this is a complete definition. This makes (for example) lambdas callable. <rdar://problem/22864976> llvm-svn: 264485
* abtest: Check all files, improve announcementsMatthias Braun2016-03-261-5/+6
| | | | | | | Simply searching for gooddir/* and baddir/* instead of *.s the script should also work with .o files. llvm-svn: 264484
* Record all translation units with more than one function in them (e.g., blocks).Sean Callanan2016-03-261-3/+9
| | | | | | | | | | | Blocks and lambdas have their implementation functions stored in the IR for an expression. If we put the block/lambda into a result variable it needs to stay around. As a heuristic, remember any execution unit that has more than one function in it. <rdar://problem/22864976> llvm-svn: 264483
* Put my abtest scripts into the util directoryMatthias Braun2016-03-263-0/+342
| | | | | | | | See http://lists.llvm.org/pipermail/llvm-dev/2016-March/097640.html There is also a description/tutorial in the comments of the abtest.py file. llvm-svn: 264482
* [asan] bump the scariness score of read-after-frees (based on feedback from ↵Kostya Serebryany2016-03-262-4/+8
| | | | | | the Chrome security team) llvm-svn: 264481
* [profile] Add integration test to validate PGO function namesVedant Kumar2016-03-254-1/+129
| | | | | | Differential Revision: http://reviews.llvm.org/D18485 llvm-svn: 264480
* [Support] Switch to RAII helper for error-as-out-parameter idiom.Lang Hames2016-03-253-13/+56
| | | | | | As discussed on the llvm-commits thread for r264467. llvm-svn: 264479
* Removed LoggingDiagnosticConsumer, an unused class.Sean Callanan2016-03-251-50/+0
| | | | llvm-svn: 264478
* Improve the reliability of file renaming in Windows by having the compiler retrySunil Srivastava2016-03-251-16/+33
| | | | | | | | | | | the rename operation on 3 error conditions of ReplaceFileW() that it was previously bailing out on. Patch by Douglas Yung! Differential Revision: http://reviews.llvm.org/D17903 llvm-svn: 264477
* Fix FILE * leak in Python APIStephane Sezer2016-03-253-9/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This fixes a leak introduced by some of these changes: r257644 r250530 r250525 The changes made in these patches result in leaking the FILE* passed to SetImmediateOutputFile. GetStream() will dup() the fd held by the python caller and create a new FILE*. It will then pass this FILE* to SetImmediateOutputFile, which always uses the flag transfer_ownership=false when it creates a File from the FILE*. Since transfer_ownership is false, the lldb File destructor will not close the underlying FILE*. Because this FILE* came from a dup-ed fd, it will also not be closed when the python caller closes its file. Leaking the FILE* causes issues if the same file is used multiple times by different python callers during the same lldb run, even if these callers open and close the python file properly, as you can end up with issues due to multiple buffered writes to the same file. Reviewers: granata.enrico, zturner, clayborg Subscribers: zturner, lldb-commits, sas Differential Revision: http://reviews.llvm.org/D18459 Change by Francis Ricci <fjricci@fb.com> llvm-svn: 264476
* StringMap/DenseMap unittests: use piecewise_construct and ensure no copy occurs.Mehdi Amini2016-03-252-22/+22
| | | | | | | | This makes us no longer relying on move-construction elision by the compiler. Suggested by D. Blaikie. From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 264475
* Add a 'language cplusplus demangle' command. This can be useful to provide a ↵Enrico Granata2016-03-251-1/+89
| | | | | | low-friction reproduction for issues with the LLDB demangling of C++ symbols llvm-svn: 264474
* [Object] Make createMachOObjectFile return Expected<...> rather thanLang Hames2016-03-254-13/+10
| | | | | | ErrorOr<...>. llvm-svn: 264473
* Allow value forwarding past release fences in GVNPhilip Reames2016-03-253-0/+126
| | | | | | | | | | | | | | A release fence acts as a publication barrier for stores within the current thread to become visible to other threads which might observe the release fence. It does not require the current thread to observe stores performed on other threads. As a result, we can allow store-load and load-load forwarding across a release fence. We choose to be much more conservative about stores. In theory, nothing prevents us from shifting a store from after a release fence to before it, and then eliminating the preceeding (previously fenced) store. Doing this without actually moving the second store is likely also legal, but we chose to be conservative at this time. The LangRef indicates only atomic loads and stores are effected by fences. This patch chooses to be far more conservative then that. This is the GVN companion to http://reviews.llvm.org/D11434 which applied the same logic in EarlyCSE and has been baking in tree for a while now. Differential Revision: http://reviews.llvm.org/D11436 llvm-svn: 264472
* Don't warn on "use" of undefined inline function that isn't actually an ODRRichard Smith2016-03-253-18/+30
| | | | | | | | use. In order for this to fire, the function needed to be a templated function marked 'constexpr' and declared but not defined. This weird pattern appears in libstdc++'s alloc_traits.h. llvm-svn: 264471
* SelectionDAG: Remove arbitrary and bug-prone complexity from SDLocJustin Bogner2016-03-251-30/+10
| | | | | | | | | | | | | | | The implementation of SDLoc has an extra layer of indirection here for no particular reason, and was leading to problems where we were dereferencing pointers to SDNodes that had already been deleted so that we could get at the DebugLoc for a new SDNode. This is one of the errors that came up often in PR26808. Instead, we can just track the DebugLoc and IROrder directly. This makes the code both easier to understand and more correct. It's also basically NFC other than fixing a large number of places where we were reading the memory of deleted SDNodes. llvm-svn: 264470
* [Object] Make MachOObjectFile's constructor private, provide a static createLang Hames2016-03-252-31/+32
| | | | | | | | | | method instead. This is not quite a named constructor: Construction may fail, and MachOObjectFiles are usually passed by unique_ptr anyway, so create returns an Expected<std::unique_ptr<MachOObjectFile>>. llvm-svn: 264469
* Fix an issue with nested aliases where the help system wouldn't correctly ↵Enrico Granata2016-03-253-0/+23
| | | | | | | | track the fact that an alias is an alias to a dash-dash alias (and I hope I typed the word 'alias' enough times in this commit message :-) llvm-svn: 264468
* [Support] Add Error::errorForOutParameter helper.Lang Hames2016-03-252-0/+13
| | | | | | | | This helper method creates a pre-checked Error suitable for use as an out parameter in a constructor. This avoids the need to have the constructor check a known-good error before assigning to it. llvm-svn: 264467
* Store list of undefined-but-used objects in a deterministic order to fixRichard Smith2016-03-258-35/+36
| | | | | | | | non-deterministic diagnostics (and non-deterministic PCH files). Check these when building a module rather than serializing it; it's not reasonable for a module's use to be satisfied by a definition in the user of the module. llvm-svn: 264466
* [X86] Emit a proper ADJCALLSTACKDOWN in EmitLoweredTLSAddrDavid Majnemer2016-03-252-1/+30
| | | | | | | | | We forgot to add the second machine operand to our ADJCALLSTACKDOWN, resulting in crashes in PEI. This fixes PR27071. llvm-svn: 264465
* Delete dead variable.Richard Smith2016-03-251-3/+1
| | | | llvm-svn: 264464
* [analyzer] Add CIFIlter modeling to DeallocChecker.Devin Coughlin2016-03-253-11/+150
| | | | | | | | | | | | | | | | | | | | The -dealloc method in CIFilter is highly unusual in that it will release instance variables belonging to its *subclasses* if the variable name starts with "input" or backs a property whose name starts with "input". Subclasses should not release these ivars in their own -dealloc method -- doing so could result in an over release. Before this commit, the DeallocChecker would warn about missing releases for such "input" properties -- which could cause users of the analyzer to add over releases to silence the warning. To avoid this, DeallocChecker now treats CIFilter "input-prefixed" ivars as MustNotReleaseDirectly and so will not require a release. Further, it will now warn when such an ivar is directly released in -dealloc. rdar://problem/25364901 llvm-svn: 264463
* [MachineCopyPropagation] Expose more dead copies across instructions with ↵Jun Bum Lim2016-03-252-3/+81
| | | | | | | | | | | regmasks When encountering instructions with regmasks, instead of cleaning up all the elements in MaybeDeadCopies map, remove only the instructions erased. By keeping more instruction in MaybeDeadCopies, this change will expose more dead copies across instructions with regmasks. llvm-svn: 264462
* Prevent construction of cycle in DAG store mergeNirav Dave2016-03-255-52/+111
| | | | | | | | | | | | | | | | | | | | | When merging stores in DAGCombiner, add check to ensure that no dependenices exist that would cause the construction of a cycle in our DAG. This may happen if one store has a data dependence on another instruction (e.g. a load) which itself has a (chain) dependence on another store being merged. These stores cannot be merged safely and doing so results in a cycle that is discovered in LegalizeDAG. This test is only done in cases where Antialias analysis is used (UseAA) as non-AA store merge candidates will be merged logically after all loads which have been checked to not alias. Reviewers: ahatanak, spatel, niravd, arsenm, hfinkel, tstellarAMD, jyknight Subscribers: llvm-commits, tberghammer, danalbert, srhines Differential Revision: http://reviews.llvm.org/D18336 llvm-svn: 264461
* Add files forgotten in r264452Tobias Grosser2016-03-256-0/+51
| | | | llvm-svn: 264460
* [libFuzzer] use fflush after every PrintfKostya Serebryany2016-03-251-0/+1
| | | | llvm-svn: 264459
* Remove useless and unused CrashRecoveryContext::getBacktrace(). This ↵Richard Smith2016-03-252-17/+1
| | | | | | function always returned an empty string. llvm-svn: 264458
OpenPOWER on IntegriCloud