summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix TestProcessLaunch breakage on MacOSPavel Labath2018-03-151-1/+1
| | | | | | | | | | | | | This test started failing after r327625. The cause seems difference in the treatment of relative --stdin paths between MacOS (debugserver?) and linux (lldb-server?). Linux treats this as relative to the debuggers PWD, while MacOS as relative to (I think) the future PWD of the launched process. This fixes the issue by using absolute paths, which should work everywhere, but we should probably unify this path handling as well. I'll ask around about what is the expected behavior here. llvm-svn: 327633
* [X86][Btver2] Remove JAny resource, and map system/microcoded instructions ↵Simon Pilgrim2018-03-156-129/+125
| | | | | | | | to JALU pipes Simplifies throughput to the issue width (1/2) instead of permitting any pipe (1/6) llvm-svn: 327632
* [InstSimplify] add tests with NaN operand for fp binops; NFCSanjay Patel2018-03-151-0/+185
| | | | llvm-svn: 327631
* [X86][SSE] Introduce Float/Vector WriteMove, WriteLoad and Writetore ↵Simon Pilgrim2018-03-1517-75/+148
| | | | | | | | | | | | scheduler classes As discussed on D44428 and PR36726, this patch splits off WriteFMove/WriteVecMove, WriteFLoad/WriteVecLoad and WriteFStore/WriteVecStore scheduler classes to permit vectors to be handled separately from gpr/scalar types. I've minimised the diff here by only moving various basic SSE/AVX vector instructions across - we can fix the rest when called for. This does fix the MOVDQA vs MOVAPS/MOVAPD discrepancies mentioned on D44428. Differential Revision: https://reviews.llvm.org/D44471 llvm-svn: 327630
* [change-namespace] Don't match a function call/ref multiple times.Eric Liu2018-03-152-9/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Previously, the matcher matches a function call/ref multiple times, one for each decl ancestor. This might cause problems. For example, in the following case, `func()` would be matched once (with namespace context) before using decl is seen and once after using decl is seeing, which would result in different conflicting replacements as the first match would replace `func` with "ns::func" as it doesn't know about the using decl. ``` namespace x { namespace { using ::ns::func; void f() { func(); } } } ``` Switching from `hasDescendant` matching to `hasAncestor` matching solves the problem. Reviewers: hokein Subscribers: klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D44517 llvm-svn: 327629
* [X86] Regenerate schedule tests with zero latency commentsSimon Pilgrim2018-03-154-78/+78
| | | | llvm-svn: 327628
* [PatternMatch, InstSimplify] allow undef elements when matching any vector ↵Sanjay Patel2018-03-153-34/+22
| | | | | | | | | | | FP zero This matcher implementation appears to be slightly more efficient than the generic constant check that it is replacing because every use was for matching FP patterns, but the previous code would check int and pointer type nulls too. llvm-svn: 327627
* [InstSimplify] remove 'nsz' requirement for frem 0, XSanjay Patel2018-03-152-11/+14
| | | | | | | | | | | From the LangRef definition for frem: "The value produced is the floating-point remainder of the two operands. This is the same output as a libm ‘fmod‘ function, but without any possibility of setting errno. The remainder has the same sign as the dividend. This instruction is assumed to execute in the default floating-point environment." llvm-svn: 327626
* Next batch of test-tree-cleaning changesPavel Labath2018-03-159-171/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The changes here fall into several categories. - some tests were redirecting inferior stdout/err to a file. For these I make sure we use an absolute path for the file. I also create a lldbutil.read_file_on_target helper function to encapsulate the differences between reading a file locally and remotely. - some tests were redirecting the pexpect I/O into a file. For these I use a python StringIO object to avoid creating a file altogether. - the TestSettings inferior was creating a file. Here, I make sure the inferior is launched with pwd=build-dir so that the files end up created there. - lldb-mi --log (used by some tests) creates a log file in PWD without the ability say differently. To make this work I make sure to run lldb-mi with PWD=build_dir. This in turn necessitated a couple of changes in other lldb-mi tests, which were using relative paths to access the source tree. Reviewers: aprantl Subscribers: ki.stfu, mehdi_amini, lldb-commits Differential Revision: https://reviews.llvm.org/D44159 llvm-svn: 327625
* [AArch64] Codegen tests for the Armv8.2-A FP16 intrinsicsSjoerd Meijer2018-03-157-0/+893
| | | | | | | | | This is a follow up of the AArch64 FP16 intrinsics work; the codegen tests had not been added yet. Differential Revision: https://reviews.llvm.org/D44510 llvm-svn: 327624
* [AAch64] Tests for ACLE FP16 macrosSjoerd Meijer2018-03-151-0/+12
| | | | | | | | This adds some missing tests for the AArch64 FP16 macros. Differential Revision: https://reviews.llvm.org/D44512 llvm-svn: 327623
* [Debug] Retain both copies of debug intrinsics in HoistThenElseCodeToIfUlrich Weigand2018-03-152-25/+89
| | | | | | | | | | | | | | | | | | | | | | | | When hoisting common code from the "then" and "else" branches of a condition to before the "if", the HoistThenElseCodeToIf routine will attempt to merge the debug location associated with the two original copies of the hoisted instruction. This is a problem in the special case where the hoisted instruction is a debug info intrinsic, since for those the debug location is considered part of the intrinsic and attempting to modify it may resut in invalid IR. This is the underlying cause of PR36410. This patch fixes the problem by handling debug info intrinsics specially: instead of hoisting one copy and merging the two locations, the code now simply hoists both copies, each with its original location intact. Note that this is still only done in the case where both original copies are otherwise (i.e. apart from location metadata) identical. Reviewed By: aprantl Differential Revision: https://reviews.llvm.org/D44312 llvm-svn: 327622
* [TSan] fix Go runtime test on amd64 with PIEMartin Pelikan2018-03-151-1/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Without this diff, the test segfaults. Examining the generated executable (which gets auto-deleted likely by cmake/ninja) yields this error message: ThreadSanitizer failed to allocate 0x4000 (16384) bytes at address 1755558480000 (errno: 12) Note that the address has more than 47 bits, which on amd64 means special treatment and therefore points out an overflow. The allocation came from __tsan_map_shadow on a .data pointer, which (on my work Debian-based box) means the 0x550000000000 range. This doesn't correspond to the constants mentioned in tsan_platform.h for Go binaries on Linux/amd64. The diff therefore allocates memory in the sort of area Go programs would, and prevents the test from crashing. It would be nice if reviewers kindly considered other setups and architectures :-) Reviewers: kcc, dvyukov Subscribers: kubamracek, delcypher, #sanitizers, llvm-commits Differential Revision: https://reviews.llvm.org/D44071 llvm-svn: 327621
* [CodeView] Initial support for emitting S_BLOCK32 symbols for lexical scopesBrock Wyma2018-03-154-14/+510
| | | | | | | | | This patch sorts local variables by lexical scope and emits them inside an appropriate S_BLOCK32 CodeView symbol. Differential Revision: https://reviews.llvm.org/D42926 llvm-svn: 327620
* [New PM][IRCE] port of Inductive Range Check Elimination pass to the new ↵Fedor Sergeev2018-03-1533-42/+155
| | | | | | | | | | | | | | | | | | | | | | | | | | pass manager There are two nontrivial details here: * Loop structure update interface is quite different with new pass manager, so the code to add new loops was factored out * BranchProbabilityInfo is not a loop analysis, so it can not be just getResult'ed from within the loop pass. It cant even be queried through getCachedResult as LoopCanonicalization sequence (e.g. LoopSimplify) might invalidate BPI results. Complete solution for BPI will likely take some time to discuss and figure out, so for now this was partially solved by making BPI optional in IRCE (skipping a couple of profitability checks if it is absent). Most of the IRCE tests got their corresponding new-pass-manager variant enabled. Only two of them depend on BPI, both marked with TODO, to be turned on when BPI starts being available for loop passes. Reviewers: chandlerc, mkazantsev, sanjoy, asbirlea Reviewed By: mkazantsev Differential Revision: https://reviews.llvm.org/D43795 llvm-svn: 327619
* More warnings when double truncation to float: compound assignment is ↵Andrew V. Tischenko2018-03-153-3/+40
| | | | | | supported now. llvm-svn: 327618
* [LoopUnroll] Ignore ephemeral values when checking full unroll profitability.Andrei Elovikov2018-03-152-20/+145
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Before this patch call graph is like this in the LoopUnrollPass: tryToUnrollLoop ApproximateLoopSize collectEphemeralValues /* Use collected ephemeral values */ computeUnrollCount analyzeLoopUnrollCost /* Bail out from the analysis if loop contains CallInst */ This patch moves collection of the ephemeral values to the tryToUnrollLoop function and passes the collected values into both ApproximateLoopsize (as before) and additionally starts using them in analyzeLoopUnrollCost: tryToUnrollLoop collectEphemeralValues ApproximateLoopSize(EphValues) /* Use EphValues */ computeUnrollCount(EphValues) analyzeLoopUnrollCost(EphValues) /* Ignore ephemeral values - they don't contribute to the final cost */ /* Bail out from the analysis if loop contains CallInst */ Reviewers: mzolotukhin, evstupac, sanjoy Reviewed By: evstupac Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D43931 llvm-svn: 327617
* [ELF] - Fix build bot after rL327612.George Rimar2018-03-151-1/+1
| | | | | | Missed this one. llvm-svn: 327616
* [SCEV][NFC] Remove TBB, FBB parameters from exit limit computationsMax Kazantsev2018-03-152-59/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Methods `computeExitLimitFromCondCached` and `computeExitLimitFromCondImpl` take true and false branches as parameters and only use them for asserts and for identifying whether true/false branch belongs to the loop (which can be done once earlier). This fact complicates generalization of exit limit computation logic on guards because the guards don't have blocks to which they go in case of failure explicitly. The motivation of this patch is that currently this part of SCEV knows nothing about guards and only works with explicit branches. As result, it fails to prove that a loop for (i = 0; i < 100; i++) guard(i < 10); exits after 10th iteration, while in the equivalent example for (i = 0; i < 100; i++) if (i >= 10) break; SCEV easily proves this fact. We are going to change it in near future, and this is why we need to make these methods operate on more abstract level. This patch refactors this code to get rid of these parameters as meaningless and prepare ground for teaching these methods to work with guards as well as they work with explicit branching instructions. Differential Revision: https://reviews.llvm.org/D44419 llvm-svn: 327615
* [ELF] - Simplify test case. NFCI.George Rimar2018-03-151-2/+1
| | | | llvm-svn: 327614
* [ELF] - Fix build bot after rL327612.George Rimar2018-03-151-2/+2
| | | | | | | Error was: error: field 'Size' will be initialized after field 'CommandString' [-Werror,-Wreorder] llvm-svn: 327613
* [ELF] - Show data and assignment commands in the map file.George Rimar2018-03-155-14/+100
| | | | | | | | | Patch teaches LLD to print BYTE/SHORT/LONG/QUAD and location move commands to the map file. Differential revision: https://reviews.llvm.org/D44004 llvm-svn: 327612
* @skipUnlessDarwin TestTargetSourceMapPavel Labath2018-03-151-0/+1
| | | | | | Our MachO parser works only on darwin. llvm-svn: 327611
* [clang-tidy] rename_check.py misc-unused-raii bugprone-unused-raii ↵Alexander Kornienko2018-03-1510-27/+31
| | | | | | --check_class_name=UnusedRAIICheck llvm-svn: 327610
* Fixed filename in a comment. NFCAlexander Kornienko2018-03-151-1/+1
| | | | llvm-svn: 327609
* [clang-tidy] rename_check.py misc-sizeof-container bugprone-sizeof-containerAlexander Kornienko2018-03-1510-17/+21
| | | | llvm-svn: 327608
* [clang-tidy] rename_check.py misc-sizeof-expression bugprone-sizeof-expressionAlexander Kornienko2018-03-1510-17/+20
| | | | llvm-svn: 327607
* [clang-tidy] rename_check.py {misc,bugprone}-macro-parenthesesAlexander Kornienko2018-03-1511-25/+28
| | | | llvm-svn: 327606
* [X86] Add test cases for 512-bit addsub from build_vector.Craig Topper2018-03-151-30/+260
| | | | | | | | There is no 512 bit addsub instruction, but we partially match it handle fmaddsub matching. We explicitly bail out for 512 bit vectors after failing the fmaddsub match, but we had no test coverage for that bail out. We might want to consider splitting and using 256 bit instructions instead of the long sequence seen here. llvm-svn: 327605
* [X86] Add support for matching FMSUBADD from build_vector.Craig Topper2018-03-152-446/+64
| | | | llvm-svn: 327604
* [X86] Remove old TODO. We have coverage for this now.Craig Topper2018-03-151-2/+0
| | | | | | Coverage was added in r320950. llvm-svn: 327603
* [X86] Use MVT in a couple places where we know the type is legal.Craig Topper2018-03-151-2/+2
| | | | llvm-svn: 327602
* [DebugInfo] Add a new method IPDBSession::findLineNumbersBySectOffsetAaron Smith2018-03-156-1/+36
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: Some PDB symbols do not have a valid VA or RVA but have Addr by Section and Offset. For example, a variable in thread-local storage has the following properties: get_addressOffset: 0 get_addressSection: 5 get_lexicalParentId: 2 get_name: g_tls get_symIndexId: 12 get_typeId: 4 get_dataKind: 6 get_symTag: 7 get_locationType: 2 This change provides a new method to locate line numbers by Section and Offset from those symbols. Reviewers: zturner, rnk, llvm-commits Subscribers: asmith, JDevlieghere Differential Revision: https://reviews.llvm.org/D44407 llvm-svn: 327601
* Fix a bug in "target.source-map" where we would resolve unmapped paths ↵Greg Clayton2018-03-153-1/+438
| | | | | | | | | | | | | | | | | | incorrectly When using: (lldb) settings set target.source-map ./ /path/to/source LLDB would fail to set a source file and line breakpoint with: (lldb) breakpoint set --file /path/to/source/main.c --line 2 Because code in the target was undoing the remapping of "/path/to/source/main.c" to "./main.c" and then it would resolve this path, which would append the current working directory to the path. We don't want to resolve paths that we unmap. Test case added. Differential Revision: https://reviews.llvm.org/D44502 llvm-svn: 327600
* [PowerPC][NFC] formatting-only fixLei Huang2018-03-151-16/+15
| | | | llvm-svn: 327599
* Refactoring code around move/copy initialization. NFC.Richard Trieu2018-03-154-60/+94
| | | | | | | | | | | | Use an enum parameter instead of a bool for more control on how the copy elision functions work. Extract the move initialization code from the move or copy initialization block. Patch by: Arthur O'Dwyer Differential Revision: https://reviews.llvm.org/D43898 llvm-svn: 327598
* Remove unused variable; NFCGeorge Burgess IV2018-03-151-1/+0
| | | | llvm-svn: 327597
* [sanitizer] Fix off type in mmap64 interceptorVitaly Buka2018-03-151-1/+1
| | | | llvm-svn: 327596
* [test] cmake: Ensure liblldb builds before tests runVedant Kumar2018-03-151-0/+4
| | | | | | | Without liblldb as a test dependency, tests which link it in from an lldb framework (via Base.buildDriver()) won't work. llvm-svn: 327595
* [ORC] Re-apply r327566 with a fix for test-global-ctors.ll.Lang Hames2018-03-1519-145/+140
| | | | | | Also clang-formats the patch, which I should have done the first time around. llvm-svn: 327594
* [CFG] Allow CallExpr's to be looked up in CFG'sRichard Trieu2018-03-152-0/+27
| | | | | | | | r327343 changed the handling for CallExpr in a CFG, which prevented lookups for CallExpr while other Stmt kinds still worked. This change carries over the necessary bits from Stmt function to CallExpr function. llvm-svn: 327593
* [Dictionary] Rewrite the test added in r327587 as an inline test.Davide Italiano2018-03-156-20/+13
| | | | | | | | | | | | | | | Until we have a better story for putting commands and check lines in the same file (they're currently ignored), it seems that inline tests are actually more concise and easier to understand. Too bad we have still some python boilerplate, but that's not really substantial so we can live with it. Thanks to Fred for pointing out and Jim for explaining me how to use the inline test format. <rdar://problem/34806516> llvm-svn: 327592
* [analyzer] Explicitly set an -std level for the analyzer test.George Karpenkov2018-03-141-1/+1
| | | | llvm-svn: 327591
* [clang-tidy] Add Zircon module to clang-tidyJulie Hockett2018-03-1412-0/+334
| | | | | | | | | | Adding a Zircon module to clang-tidy for checks specific to the Zircon kernel, and adding a checker to fuchsia-zx (for zircon) to flag instances where specific objects are temporarily created. Differential Revision: https://reviews.llvm.org/D44346 llvm-svn: 327590
* [CleanUp] Remove NumInstructions field from LoopVectorizer's RegisterUsage ↵Matt Davis2018-03-141-7/+0
| | | | | | | | | | | | | | | | | | | | | struct. Summary: This variable is largely going unused; aside from reporting number of instructions for in DEBUG builds. The only use of NumInstructions is in debug output to represent the LoopSize. That value can be can be misleading as it also includes metadata instructions (e.g., DBG_VALUE) which have no real impact. If we do choose to keep this around, we probably should guard it by a DEBUG macro, as it's not used in production builds. Reviewers: majnemer, congh, rengolin Reviewed By: rengolin Subscribers: llvm-commits, rengolin Differential Revision: https://reviews.llvm.org/D44495 llvm-svn: 327589
* [X86][Btver2] Add support for multiple pipelines stages for fpu schedules. NFCI.Simon Pilgrim2018-03-141-98/+41
| | | | | | This allows us to use JWriteResFpuPair for complex schedule classes as well as single pipe instructions. llvm-svn: 327588
* [DataFormatters] Implement summary for __NSDictionary0.Davide Italiano2018-03-145-0/+24
| | | | | | | | | | | | | | | | | | | Before the patch: (lldb) frame var emptyDictionary (__NSDictionary0 *) emptyDictionary = 0x0000000100304420 After: (lldb) frame var emptyDictionary (__NSDictionary0 *) emptyDictionary = 0x0000000100304420 0 key/value pairs There's nothing much else we can do, as this is always empty by definition. <rdar://problem/34806516> llvm-svn: 327587
* [test] Skip more lldb-mi tests which occasionally time out on DarwinVedant Kumar2018-03-141-1/+6
| | | | llvm-svn: 327586
* [InstSimplify] add tests for frem and vectors with undef; NFCSanjay Patel2018-03-141-3/+88
| | | | | | | | | These should all be folded. The vector tests need to have m_AnyZero updated to ignore undef elements, but we need to be careful not to return the existing value in that case and unintentionally propagate undef. llvm-svn: 327585
* Update Error MessageRumeet Dhindsa2018-03-1413-15/+16
| | | | | | | | | | | | | | Summary: Updates error message for dynamic relocation attempt for read only segments. Reviewers: ruiu Reviewed By: ruiu Subscribers: emaste, javed.absar, arichardson, llvm-commits Differential Revision: https://reviews.llvm.org/D44453 llvm-svn: 327584
OpenPOWER on IntegriCloud