summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [CodeGen] Compute the objc EH vtable address point using inbounds GEP.Ahmed Bougacha2017-11-172-6/+7
| | | | | | | | | | | | | | | | The object is provided by the objc runtime and is never visible in the module itself, but even so, the address point we compute points into it, and "+16" is guaranteed not to overflow. This matches the c++ vtable IRGen. Note that I'm not entirely convinced the 'i8*' type is correct here: at the IR level, we're accessing memory that's outside the global object. But we don't control the allocation, so it's not obviously wrong either. But either way, this is only in a global initializer, so I don't think it's going to be mucked with. Filed PR35352 to discuss that. llvm-svn: 318545
* [clangd] Release the old preamble before building a new one.Ilya Biryukov2017-11-171-3/+10
| | | | llvm-svn: 318544
* MIRParser: Avoid reading uninitialized memory on generic vregsJustin Bogner2017-11-171-0/+1
| | | | | | | | | | | | | | If a vreg's bank is specified in the registers block and one of its defs or uses also specifies the bank, we end up checking that the RegBank is equal to diagnose conflicting banks. The problem comes up for generic vregs, where we weren't fully initializing the VRegInfo when parsing the registers block, so we'd end up comparing a null pointer to uninitialized memory. This fixes a non-deterministic failure when round tripping through MIR with generic vregs. llvm-svn: 318543
* [X86] Merge scheduling tests for SHLD/SHRDSimon Pilgrim2017-11-171-156/+93
| | | | | | Reduces spsce used and makes it easier to compare the 2 values for the equivalent instructions llvm-svn: 318541
* [ThinLTO] Remove too aggressive assertion in building function call graph.Volodymyr Sapsai2017-11-172-4/+17
| | | | | | | | | | | | | | | | The assertion was introduced in r317853 but there are cases when a call isn't handled either as direct or indirect. In this case we add a reference graph edge but not a call graph edge. Reviewers: tejohnson Reviewed By: tejohnson Subscribers: mehdi_amini, inglorion, eraman, hiraditya, efriedma, llvm-commits Differential Revision: https://reviews.llvm.org/D40056 llvm-svn: 318540
* [WebAssembly] Initial wasm linker implementationSam Clegg2017-11-1761-16/+5791
| | | | | | | | | | This linker backend is still a work in progress but is enough to link simple programs including linking against library archives. Differential Revision: https://reviews.llvm.org/D34851 llvm-svn: 318539
* [AST] Partially revert r318341 to fix two broken tests on ↵Eugene Zelenko2017-11-172-478/+293
| | | | | | llvm-clang-x86_64-expensive-checks-win (NFC). llvm-svn: 318538
* clang-format: remove trailing lines in lamdas and arrow functions.Martin Probst2017-11-174-4/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: clang-format already removes empty lines at the beginning & end of blocks: int x() { foo(); // lines before and after will be removed. } However because lamdas and arrow functions are parsed as expressions, the existing logic to remove empty lines in UnwrappedLineFormatter doesn't handle them. This change special cases arrow functions in ContinuationIndenter to remove empty lines: x = []() { foo(); // lines before and after will now be removed. }; Reviewers: djasper Subscribers: klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D40178 llvm-svn: 318537
* [OPENMP] Codegen for `target simd` construct.Alexey Bataev2017-11-178-86/+1323
| | | | | | Added codegen support for `target simd` directive. llvm-svn: 318536
* Try to fix the windows build.Rafael Espindola2017-11-171-2/+2
| | | | llvm-svn: 318535
* Use TempFile in dsymutil.Rafael Espindola2017-11-171-60/+49
| | | | | | | I don't think there is any functionality change, but the code is easier to understand IMHO. llvm-svn: 318534
* Revert "[MC] Fix regression tests on Windows when git “core.autocrlf” is ↵Rafael Espindola2017-11-174-32/+0
| | | | | | | | | | set to true." This reverts commit r318528. MC/AsmParser/preserve-comments-crlf.s fails on linux. llvm-svn: 318533
* [CMake] Allow for Solaris ld -V output on stdoutMichal Gorny2017-11-171-1/+2
| | | | | | | | | | | | | | | | | | In recent versions of Solaris 11.4 (previously 12), ld -V output went to stdout instead of stderr. Since AddLLVM.cmake only expects it on stderr, Solaris ld wasn't properly detected and options not understood by it are passed during the build. The following patch fixes this, allowing for both variants. Tested on i386-pc-solaris2.11.4 (on top of D35755 which is needed for proper Solaris support). Patch by Rainer Orth. Differential Revision: https://reviews.llvm.org/D39601 llvm-svn: 318532
* [AArch64] Adjust the cost model for Exynos M1 and M2Evandro Menezes2017-11-171-43/+78
| | | | | | Improve the accuracy of the model by specifying the proper number of uops. llvm-svn: 318531
* Indent code blocks so they are actually treated as suchStephan Bergmann2017-11-171-9/+9
| | | | llvm-svn: 318530
* Fix skipping of flags in getClangStripDependencyFileAdjusterDave Lee2017-11-172-5/+36
| | | | | | | | | | | | | | | | | | Summary: The ArgumentsAdjuster returned from `getClangStripDependencyFileAdjuster` will skip dependency flags, and also their associated values for those flags that take an argument. This change corrects the handling of the `-MD` and `-MMD` flags, which do not take an argument. Reviewers: saugustine, klimek, alexshap Reviewed By: alexshap Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D40024 llvm-svn: 318529
* [MC] Fix regression tests on Windows when git “core.autocrlf” is set to ↵Zhen Cao2017-11-174-0/+32
| | | | | | | | true. Differential Revision: https://reviews.llvm.org/D39737 llvm-svn: 318528
* [OMPT] Fix inaccuracies in worksharing testsJonas Hahnfeld2017-11-172-8/+7
| | | | | | | | | | | | | | | | | These tests were failing rarely on my MacBook when there was some activity in the background. Read: one of a thousand executions? * sections.c missed the sorting based on thread ids. This worked as long as the master thread finished its section before the worker thread started the second one but failed if the master thread was put to sleep by the OS. * The checks in single.c assumed that the master thread executes the single region which works most of the time because it is usually faster than the newly spawned worker thread. Differential Revision: https://reviews.llvm.org/D39853 llvm-svn: 318527
* [AMDGPU][MC][GFX9][disassembler] Corrected decoding of op_sel_hi for v_mad_mix*Dmitry Preobrazhensky2017-11-1710-104/+545
| | | | | | | | | | See bug 35148: https://bugs.llvm.org//show_bug.cgi?id=35148 Reviewers: tamazov, SamWot, arsenm Differential Revision: https://reviews.llvm.org/D39492 llvm-svn: 318526
* [clang-format] Add text proto filename detectionKrasimir Georgiev2017-11-171-0/+5
| | | | | | | | | | | | | | Summary: Adds text proto filename detection. Reviewers: klimek Reviewed By: klimek Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D40120 llvm-svn: 318525
* [Support][CachePruning] Fix regression in pruning intervalBen Dunbobbin2017-11-171-1/+1
| | | | | | | | | | | | | Fixed broken comparison. borked by: rL284966 (see: https://reviews.llvm.org/D25730). Differential Revision: https://reviews.llvm.org/D40119 This is a second attempt to commit this. The first attempt broke lld and gold tests that had been written against the incorrect behaivour. llvm-svn: 318524
* [clang-tidy] Fix an oversight after renaming a checkGabor Horvath2017-11-172-3/+3
| | | | llvm-svn: 318523
* [clang-tidy] Add a check for undelegated copy of base classesGabor Horvath2017-11-178-0/+384
| | | | | | | | | | | | | | | Finds copy constructors where the constructor don't call the copy constructor of the base class. ``` class X : public Copyable { X(const X &other) {} // Copyable(other) is missing }; ``` Differential Revision: https://reviews.llvm.org/D33722 llvm-svn: 318522
* [gold] Fix broken thin LTO cache test NFCAndrew Ng2017-11-171-3/+3
| | | | | | | | Fix test as it is assuming that the cache pruning is always being performed by default. Explicitly set prune interval to 0s to ensure pruning is always performed. llvm-svn: 318520
* [ELF] - Teach LLD to use information from .debug_str for error reporting.George Rimar2017-11-174-1/+214
| | | | | | | | | | | | Recently we teached LLD to report line numbers for duplicate variables definitions, though currently LLD is unable to do that for case when strings are not built in .debug_info, but stored in .debug_str instead. That is because out LLDDwarfObj does not handle .debug_str yet. Patch fixes that. Differential revision: https://reviews.llvm.org/D39542 llvm-svn: 318519
* [ELF] - Fix BB after r318516George Rimar2017-11-171-5/+5
| | | | | | | | | Test did not run under windows because uses zlib. Content of section changed because now strings merging is applied. llvm-svn: 318518
* [nfc] Iwyu: forward-declare/include raw_ostream in zone algoPhilip Pfaffe2017-11-172-0/+2
| | | | llvm-svn: 318517
* [ELF] - Allow applying SHF_MERGE optimization for relocatable output.George Rimar2017-11-174-18/+11
| | | | | | | | | | | This fixes PR35223. Here I enabled SHF_MERGE section content merging for -r like we do for regular linking. Differential revision: https://reviews.llvm.org/D40026 llvm-svn: 318516
* Implement more accurate penalty & trade-offs while breaking protruding tokens.Manuel Klimek2017-11-175-39/+233
| | | | | | | | For each line that we break in a protruding token, compute whether the penalty of breaking is actually larger than the penalty of the excess characters. Only break if that is the case. llvm-svn: 318515
* Use llvm-config.h instead of config.hIlya Biryukov2017-11-171-1/+1
| | | | | | To fix standalone builds broken by r318411 (config.h is private to llvm). llvm-svn: 318514
* Ignore -no-ctors-in-init-array.Rui Ueyama2017-11-172-0/+21
| | | | | | Patch by dxf@google.com. llvm-svn: 318513
* Add a missing #include.Rui Ueyama2017-11-171-0/+1
| | | | llvm-svn: 318512
* [MinGW] Define __ARM_DWARF_EH__ for MinGW/ARMMartin Storsjo2017-11-172-0/+5
| | | | | | | | | Since SVN r318510, the MinGW/ARM configuration defaults to dwarf exception handling. Differential Revision: https://reviews.llvm.org/D39533 llvm-svn: 318511
* [ARM] Use dwarf exception handling on MinGWMartin Storsjo2017-11-173-3/+59
| | | | | | | | | | | | | | | Enabling and using dwarf exceptions seems like an easier path to take, than to make the COFF/ARM backend output EHABI directives. Previously, no EH model was enabled at all on this target. There's no point in setting UseIntegratedAssembler to false since GNU binutils doesn't support Windows on ARM, and since we don't need to support external assembler, we don't need to use register numbers in cfi directives. Differential Revision: https://reviews.llvm.org/D39532 llvm-svn: 318510
* [SelectionDAG] Allow custom vector widening through ReplaceNodeResults to ↵Craig Topper2017-11-171-2/+7
| | | | | | | | | | handle nodes with chain outputs. Previously we were assuming all results were vectors and calling SetWidenedVector, but if its a chain result we should just replace uses instead. This fixes an error found by expensive checks after r318368. llvm-svn: 318509
* [IRCE] Remove folding of two range checks into RANGE_CHECK_BOTHMax Kazantsev2017-11-172-34/+20
| | | | | | | | | | | | | The logic of replacing of a couple `RANGE_CHECK_LOWER + RANGE_CHECK_UPPER` into `RANGE_CHECK_BOTH` in fact duplicates the logic of range intersection which happens when we calculate safe iteration space. Effectively, the result of intersection of these ranges doesn't differ from the range of merged range check. We chose to remove duplicating logic in favor of code simplicity. Differential Revision: https://reviews.llvm.org/D39589 llvm-svn: 318508
* Change path used in a test from r318503 to work on windowsBruno Cardoso Lopes2017-11-171-1/+1
| | | | | | http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/13565 llvm-svn: 318507
* AMDGPU: Replace list of SMEM buffer opcodesMatt Arsenault2017-11-172-10/+14
| | | | llvm-svn: 318506
* AMDGPU: Fix breaking SMEM clausesMatt Arsenault2017-11-177-39/+415
| | | | | | | | This was completely ignoring subregisters, so was not very useful. Also only break them if xnack is actually enabled. llvm-svn: 318505
* Fix LLDB build.Eugene Zemtsov2017-11-171-0/+1
| | | | | | It was broken by r318489. llvm-svn: 318504
* [PCH+Modules] Improve diagnosticts to help out users pass an extra header ↵Bruno Cardoso Lopes2017-11-173-2/+28
| | | | | | | | | | | | | | | search path When mixing PCH and Implicit Modules, missing a header search path can lead to the implicit built PCM to complaint about not finding its matching module map. Instead of adding more magic to implicit modules engine, add a note to help the user add the appropriate path. rdar://problem/33388847 llvm-svn: 318503
* [llvm-profdata] Fix a dangling reference to an error stringVedant Kumar2017-11-176-3/+43
| | | | llvm-svn: 318502
* [GISel]: DCE copy instructions during legalizationAditya Nandakumar2017-11-172-9/+71
| | | | | | | | We might have instructions such as ext(copy(trunc)), and while cleaning up legalization artifacts, we can also dce the copies that are in between legalization artifacts. llvm-svn: 318501
* Update xcode project file to build new ppc64le files.Jason Molenda2017-11-173-3/+27
| | | | llvm-svn: 318500
* [SelectionDAG] Consolidate (t|T)ransferDbgValues methods, NFC (reapply)Vedant Kumar2017-11-173-45/+35
| | | | | | | | | | | | | | | | | | TransferDbgValues (capital 'T') is wired into ReplaceAllUsesWith, and transferDbgValues (lowercase 't') is used elsewhere (e.g in Legalize). Both functions should be doing the exact same thing. This patch consolidates the logic into one place. This was reverted in r318455 because some newly introduced asserts, which I thought were NFC, were firing. I filed PR35338. For now I've weakened the asserts. Testing: check-llvm, check-clang, and a stage2 Rel+Deb build of clang Differential Revision: https://reviews.llvm.org/D40104 llvm-svn: 318498
* Remove IsLocal.Rafael Espindola2017-11-178-70/+61
| | | | | | | Since we always have Binding in the current symbol design IsLocal is redundant. llvm-svn: 318497
* Recognize another magic token sent in the LaunchInfo's EventData.Jim Ingham2017-11-171-29/+71
| | | | | | <rdar://problem/32505028> llvm-svn: 318496
* "source list -a" was calling DisplaySourceLinesWithNumbers incorrectly.Jim Ingham2017-11-171-4/+5
| | | | | | | | The parameters were just passed in the wrong order. <rdar://problem/35150446> llvm-svn: 318495
* [CUDA] Remove implementations of nexttoward.Justin Lebar2017-11-172-23/+8
| | | | | | | | | | | | | | | | | | Summary: __builtin_nexttoward lowers to a libcall, e.g. nexttowardf(), that CUDA does not have. Rather than try to implement it, we simply remove these functions -- nvcc doesn't support them either, and nextafter, which does work, does essentially the same thing on GPUs, because GPUs don't have long double. Reviewers: tra Subscribers: cfe-commits, sanjoy Differential Revision: https://reviews.llvm.org/D40152 llvm-svn: 318494
* [asan] Test ASan instrumentation for shadow scale value of 5Walter Lee2017-11-1710-14/+34
| | | | | | | | | Add additional RUN clauses to test for -asan-mapping-scale=5 in selective tests, with special CHECK statements where needed. Differential Revision: https://reviews.llvm.org/D39775 llvm-svn: 318493
OpenPOWER on IntegriCloud