summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [ThinLTO] Correct documentation on default number of threadsTeresa Johnson2018-08-171-1/+3
| | | | | | | | | | | | | | | | | | Summary: The number of threads used for ThinLTO backend parallelism was dropped to the number of cores in r284618 to avoid oversubscribing physical cores due to hyperthreading. This updates the documentation to reflect that change. Fixes PR38610. Reviewers: pcc Subscribers: mehdi_amini, inglorion, eraman, steven_wu, dexonsmith, cfe-commits Differential Revision: https://reviews.llvm.org/D50882 llvm-svn: 340021
* [TableGen] TypeSetByHwMode::insert - cache the default MVT. NFCI.Simon Pilgrim2018-08-171-3/+10
| | | | | | Avoids repeated count()/find() calls that we've already have the default values for. llvm-svn: 340020
* [AArch64] - return address signingLuke Cheeseman2018-08-177-0/+61
| | | | | | | | | | | | | | - Add a command line options -msign-return-address to enable return address signing - Armv8.3a added instructions to sign the return address to help mitigate against ROP attacks - This patch adds command line options to generate function attributes that signal to the back whether return address signing instructions should be added Differential revision: https://reviews.llvm.org/D49793 llvm-svn: 340019
* [AArch64] - Generate pointer authentication instructionsLuke Cheeseman2018-08-172-0/+145
| | | | | | | | | | | | | | | | - Generate pointer authentication instructions - The functions instrumented depend on function attribtues: all (all functions instrumentent) non-leaf (only those that spill LR) none - Function epilogues sign the LR before spilling to the stack and authenticate the LR once restored - If the target is v8.3a or greater than can use the combined authenticate and return instruction Differential revision: https://reviews.llvm.org/D49793 llvm-svn: 340018
* Revert extraneous directory added by accident in rL340016Nemanja Ivanovic2018-08-171-17/+0
| | | | | | | | | | It appears that the way this patch was produced ended up creating an extra 'llvm' directory where the test was placed. When I committed the patch, that directory ended up being created upstream. This commit should revert that. Sorry for the noise. llvm-svn: 340017
* [PowerPC] Generate Power9 extswsli extend sign and shift immediate instructionNemanja Ivanovic2018-08-176-3/+72
| | | | | | | | | | | Add a DAG combine for the PowerPC code generator to generate the Power9 extswsli extend sign and shift immediate instruction. Patch by RolandF. Differential revision: https://reviews.llvm.org/D49879 llvm-svn: 340016
* [DAGCombiner] extractShiftForRotate - fix out of range shift issueSimon Pilgrim2018-08-172-2/+15
| | | | | | | | | Don't just check for negative shift amounts. Fixes OSS Fuzz #9935 https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=9935 llvm-svn: 340015
* [InstCombine] Remove unused method FAddCombine::createFDiv(). NFCAndrea Di Biagio2018-08-171-8/+0
| | | | | | | | This commit fixes a (gcc 7.3.0) [-Wunused-function] warning caused by the presence of unused method FaddCombine::createFDiv(). The last use of that method was removed at r339519. llvm-svn: 340014
* [ARM/AArch64] Support FP16 +fp16fml instructionsBernard Ogden2018-08-1724-5/+821
| | | | | | | | | | | | | | | | | | Add +fp16fml feature for new FP16 instructions, which are a mandatory part of FP16 from v8.4-A and an optional part of FP16 from v8.2-A. It doesn't seem to be possible to model this in LLVM, but the relationship between the options is handled by the related clang patch. In keeping with what I think is the usual practice, the fp16fml extension is accepted regardless of base architecture version. Builds on/replaces Sjoerd Meijer's patch to add these instructions at https://reviews.llvm.org/D49839. Differential Revision: https://reviews.llvm.org/D50228 llvm-svn: 340013
* [ARM/AArch64] TargetParserTest fixesBernard Ogden2018-08-171-2/+21
| | | | | | | | | Adds some missing tests for the FP16 extension, fixes an existing test that misnames it. Differential Revision: https://reviews.llvm.org/D50227 llvm-svn: 340012
* [LLD][ELF] - Remove dead code. NFC.George Rimar2018-08-171-4/+0
| | | | | | These lines were unused. llvm-svn: 340011
* [DAGCombine] Improve (sra (sra x, c1), c2) -> (sra x, (add c1, c2)) foldingSimon Pilgrim2018-08-172-28/+18
| | | | | | | | Add support for cases where only some c1+c2 results exceed the max bitshift, clamping accordingly. Differential Revision: https://reviews.llvm.org/D35722 llvm-svn: 340010
* Fix clangd tests on older compilersSimon Pilgrim2018-08-171-10/+10
| | | | | | Old versions of gcc struggle with raw string literals inside macros. llvm-svn: 340009
* [Sparc] Get sret arg size from CallLoweringInfo.getArgs()Daniel Cederman2018-08-174-47/+33
| | | | | | | | | | | | | | | | | | | | Summary: Looking at the callee argument list, as is done now, might not work if the function has been typecasted into one that is expected to return a struct. This change also simplifies the code. The isFP128ABICall() function can be removed as it is no longer needed. The test in fp128.ll has been updated to verify this. Reviewers: jyknight, venkatra Reviewed By: jyknight Subscribers: fedor.sergeev, jrtc27, llvm-commits Differential Revision: https://reviews.llvm.org/D48117 llvm-svn: 340008
* [clangd] NFC: Mark Workspace Symbol feature complete in the documentationKirill Bobyrev2018-08-171-2/+2
| | | | | | | | | | | Workspace Symbol implementation was introduced in D44882 and should be complete now. Reviewed by: ioeric Differential Revision: https://reviews.llvm.org/D50703 llvm-svn: 340007
* Fix "control reaches end of non-void function" -Wreturn-type warning. NFCI.Simon Pilgrim2018-08-171-0/+1
| | | | llvm-svn: 340006
* [clangd] Fetch documentation from the Index during signature helpIlya Biryukov2018-08-174-69/+164
| | | | | | | | | | | | | | | | Summary: Sema can only be used for documentation in the current file, other doc comments should be fetched from the index. Reviewers: hokein, ioeric, kadircet Reviewed By: hokein, kadircet Subscribers: MaskRay, jkorous, mgrang, arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D50727 llvm-svn: 340005
* [clangd] Show function documentation in signature helpIlya Biryukov2018-08-173-40/+13
| | | | | | | | | | | | | | | | | | | | | | Summary: Previously, clangd was trying to show documentation for the active parameter instead, which is wrong per LSP specification. Moreover, the code path that attempts to get parameter comments never succeds, because no attempt is made to parse function doc comment and extract parameter-specific parts out of it. So we also remove the code that claims to fetch parameter comments: it is not used anymore and is incorrect. Reviewers: hokein, ioeric, kadircet Reviewed By: ioeric Subscribers: MaskRay, jkorous, arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D50726 llvm-svn: 340004
* [Sparc] Flush register windows for @llvm.returnaddress(1)Daniel Cederman2018-08-172-11/+24
| | | | | | | | | | | | | | | | | | Summary: When @llvm.returnaddress is called with a value higher than 0 it needs to read from the call stack to get the return address. This means that the register windows needs to be flushed to the stack to guarantee that the data read is valid. For values higher than 1 this is done indirectly by the call to getFRAMEADDR(), but not for the value 1. Reviewers: jyknight, venkatra Reviewed By: jyknight Subscribers: fedor.sergeev, jrtc27, llvm-commits Differential Revision: https://reviews.llvm.org/D48636 llvm-svn: 340003
* [clangd] Always use the latest preambleHaojian Wu2018-08-172-2/+46
| | | | | | | | | | | | | | | | | | | | | Summary: Fix an inconsistent behavior of using `LastBuiltPreamble`/`NewPreamble` in TUScheduler (see the test for details), AST should always use NewPreamble. This patch makes LastBuiltPreamble always point to NewPreamble. Preamble rarely fails to build, even there are errors in headers, so we assume it would not cause performace issue for code completion. Reviewers: ilya-biryukov Reviewed By: ilya-biryukov Subscribers: javed.absar, ioeric, MaskRay, jkorous, arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D50695 llvm-svn: 340001
* [MISC]Fix wrong usage of std::equal()Chen Zheng2018-08-174-19/+39
| | | | | | Differential Revision: https://reviews.llvm.org/D49958 llvm-svn: 340000
* [ARM][NFC] ARMCodeGenPrepare: some refactoring and algorithm descriptionSjoerd Meijer2018-08-171-33/+85
| | | | | | Differential Revision: https://reviews.llvm.org/D50846 llvm-svn: 339997
* [NFC] Some small test updates for Implicit Conversion sanitizer.Roman Lebedev2018-08-174-7/+84
| | | | | | Split off from D50251. llvm-svn: 339996
* [NFC] Some small test updates for Implicit Conversion sanitizer.Roman Lebedev2018-08-173-46/+288
| | | | | | Split off from D50250. llvm-svn: 339995
* Fix compiler warnings after rL339649.Aleksandr Urakov2018-08-172-10/+7
| | | | | | Differential Revision: https://reviews.llvm.org/D49980 llvm-svn: 339994
* [MustExecute] Fix algorithmic bug in isGuaranteedToExecute. PR38514Max Kazantsev2018-08-175-53/+125
| | | | | | | | | | | | | | | | | | | | | The description of `isGuaranteedToExecute` does not correspond to its implementation. According to description, it should return `true` if an instruction is executed under the assumption that its loop is *entered*. However there is a sophisticated alrogithm inside that tries to prove that the instruction is executed if the loop is *exited*, which is not the same thing for infinite loops. There is an attempt to protect from dealing with infinite loops by prohibiting loops without exit blocks, however an infinite loop can have exit blocks. As result of that, MustExecute can falsely consider some blocks that are never entered as mustexec, and LICM can hoist dangerous instructions out of them basing on this fact. This may introduce UB to programs which did not contain it initially. This patch removes the problematic algorithm and replaced it with a one which tries to prove what is required in description. Differential Revision: https://reviews.llvm.org/D50558 Reviewed By: reames llvm-svn: 339984
* [NFC] Add tests to ensure that improvement of MustThrow analysis will not ↵Max Kazantsev2018-08-171-0/+91
| | | | | | lead to problems in future llvm-svn: 339983
* Revert r339977: [GISel]: Add Opcodes for a few LLVM IntrinsicsChandler Carruth2018-08-174-51/+0
| | | | | | This is breaking ~all the bots. llvm-svn: 339982
* [llvm-mc-assemble-fuzzer] Update API - Pass MCObjectWriter instead of a streamBrian Cain2018-08-171-3/+4
| | | | | | | | Fixes build breakage of llvm-mc-assemble-fuzzer introduced by r332749. Fix provided by pbhatu (Pratik Bhatu) llvm-svn: 339981
* [Support] Add a public API to allow clearing all (static) timer groups.Graydon Hoare2018-08-172-5/+24
| | | | | | | | | | | | | | | | | | | | | | Summary: Formerly, all timer groups were automatically cleared when printed out. In https://reviews.llvm.org/rL324788 this behaviour was changed to not-clearing timers on printout, to allow printing timers more than once, but as a result clients (specifically Swift) that relied on the clear-on-print behaviour to inhibit duplicate timer printing on shutdown were broken. Rather than revert that change, this change adds a new API that enables clients that _want_ to clear all timers to do so explicitly. Reviewers: george.karpenkov, thegameg Reviewed By: george.karpenkov Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D50874 llvm-svn: 339980
* [hexagon] restore -fuse-cxa-atexit by defaultBrian Cain2018-08-172-2/+1
| | | | | | | | | | | | | "-fno-use-cxa-atexit" was a default provided by the initial commit offering hexagon support. This is no longer required. Reviewers: bcahoon, sidneym Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D50816 llvm-svn: 339979
* [XRay][compiler-rt] Avoid InternalAlloc(...) in Profiling ModeDean Michael Berris2018-08-172-102/+112
| | | | | | | | | | | | | | | | | | | | | | | | Summary: We avoid using dynamic memory allocated with the internal allocator in the profile collection service used by profiling mode. We use aligned storage for globals and in-struct storage of objects we dynamically initialize. We also remove the dependency on `Vector<...>` which also internally uses the dynamic allocator in sanitizer_common (InternalAlloc) in favour of the XRay allocator and segmented array implementation. This change addresses llvm.org/PR38577. Reviewers: eizan Reviewed By: eizan Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D50782 llvm-svn: 339978
* [GISel]: Add Opcodes for a few LLVM IntrinsicsAditya Nandakumar2018-08-174-0/+51
| | | | | | | | | | | https://reviews.llvm.org/D50401 Add opcodes for llvm.intrinsic.trunc, round, and update the IRTranslator for the same. Reviewed by: dsanders. llvm-svn: 339977
* Revert "[libFuzzer] Use std::discrete_distribution for input selection."Matt Morehouse2018-08-171-4/+7
| | | | | | | This reverts r339973 due to msan.test failing on sanitizer-x86_64-linux-fuzzer bot. llvm-svn: 339976
* [ADT] Replace a member initializer of a union with an explicitChandler Carruth2018-08-171-2/+6
| | | | | | | | | | constructor. This breaking an old/weird host compiler is my best bet for the current crashes I'm getting from bots since this functionality was added to this ADT. llvm-svn: 339975
* Add a relocation for R_AARCH64_ABS32 in ObjectFileELFStephane Sezer2018-08-171-4/+9
| | | | | | | | | | | | | | | | | | | | | | Summary: .rela.debug_info relocations are being done via ObjectFileELF::ApplyRelocations for aarch64. Currently, the switch case that iterates over the relocation type is only implemented for a few different types and `assert(false)`es over the rest. Implement the relocation for R_AARCH64_ABS32 in ApplyRelocations Reviewers: sas, xiaobai, javed.absar, espindola Reviewed By: sas Subscribers: emaste, arichardson, kristof.beyls Differential Revision: https://reviews.llvm.org/D50369 Change by Nathan Lanza <lanza@fb.com> llvm-svn: 339974
* [libFuzzer] Use std::discrete_distribution for input selection.Matt Morehouse2018-08-171-7/+4
| | | | | | | | | | | | | | | | | Summary: Since we're casting from double to size_t during input selection, we really want a discrete distribution over size_t rather than a piecewise distribution over doubles. Reviewers: kcc Reviewed By: kcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D50356 llvm-svn: 339973
* [WebAssembly] Modify LateEHPrepare one-line description (NFC)Heejin Ahn2018-08-171-1/+1
| | | | llvm-svn: 339972
* Revert "Establish the <bit> header. NFC yet. Reviewed as ↵Vitaly Buka2018-08-164-175/+136
| | | | | | | | | | https://reviews.llvm.org/D50815" Breaks build on sanitizer bots. This reverts commit r339943. llvm-svn: 339971
* DebugInfo: Remove command line (& target-based) disabling of pubnames in ↵David Blaikie2018-08-169-53/+10
| | | | | | | | | favor of metadata Now that Clang disables NVPTX pubnames via metadata there's no need for this fallback to target detection in the backend. llvm-svn: 339970
* [libc++] Use correct rand.eng.mers all-zeroes seed sequence fallbackHubert Tong2018-08-162-2/+83
| | | | | | | | | | | | | | | | | | | | | | | Summary: When a seed sequence would lead to having no non-zero significant bits in the initial state of a `mersenne_twister_engine`, the fallback is to flip the most significant bit of the first value that appears in the textual representation of the initial state. rand.eng.mers describes this as setting the value to be 2 to the power of one less than w; the previous value encoded in the implementation, namely one less than "2 to the power of w", is replaced by the correct value in this patch. Reviewers: mclow.lists, EricWF, jasonliu Reviewed By: mclow.lists Subscribers: mclow.lists, jasonliu, EricWF, christof, ldionne, cfe-commits Differential Revision: https://reviews.llvm.org/D50736 llvm-svn: 339969
* Disable pubnames in NVPTX debug info using metadataDavid Blaikie2018-08-162-2/+11
| | | | llvm-svn: 339968
* [WebAssembly] CFG stackify support for exception handlingHeejin Ahn2018-08-163-108/+868
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This adds support for exception handling to CFGStackify pass. This only adds TRY / END_TRY markers and DOES NOT yet fix unwind mismatches that can be created by the linearization of the CFG into the structural wasm format. The mismatch fix will be added by following patches. In detail, this patch - Added support for TRY / END_TRY markers to support EH - Changed many static functions into class member functions as they take too many arguments now - Added several more bookeeping data structures - Refactored routines that decide where to insert markers, because without refactoring this got too complicated as we added support for new kinds of markers (TRY/END_TRY). - Rewrote rethrow instructions' BB arguments to relative depths in EH pad stack. Reviewers: dschuff, sunfish Subscribers: sbc100, jgravelle-google, llvm-commits Differential Revision: https://reviews.llvm.org/D48273 llvm-svn: 339967
* Revert "Implement a (simple) Markdown generator"Julie Hockett2018-08-1613-732/+38
| | | | | | | This reverts commit r339948, as it's breaking a few bots in ways that I can't reproduce right now. llvm-svn: 339966
* Remove commented out constructor from ScalarAlex Langford2018-08-161-43/+0
| | | | | | | This appears to have been commented out since the initial checkin of lldb. llvm-svn: 339965
* Relax a CHECK line to allow for dso_localVedant Kumar2018-08-161-1/+1
| | | | | | | Fixes a bot failure: http://lab.llvm.org:8011/builders/llvm-clang-x86_64-expensive-checks-win/builds/11806 llvm-svn: 339964
* Revert "Revert "[hwasan] Add __hwasan_handle_longjmp.""Evgeniy Stepanov2018-08-165-7/+76
| | | | | | | | | | | This reapplies commit r339935 with the following changes: * make longjmp test C, not C++, to avoid dependency on libc++/libstdc++ * untag pointer in memset interceptor x86_64 does not have TBI, so hwasan barely works there. Tests must be carefully written in a way that does not leak tagged pointer to system libraries. llvm-svn: 339963
* [x86/MIR] Implement support for pre- and post-instruction symbols, asChandler Carruth2018-08-1610-42/+380
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | well as MIR parsing support for `MCSymbol` `MachineOperand`s. The only real way to test pre- and post-instruction symbol support is to use them in operands, so I ended up implementing that within the patch as well. I can split out the operand support if folks really want but it doesn't really seem worth it. The functional implementation of pre- and post-instruction symbols is now *completely trivial*. Two tiny bits of code in the (misnamed) AsmPrinter. It should be completely target independent as well. We emit these exactly the same way as we emit basic block labels. Most of the code here is to give full dumping, MIR printing, and MIR parsing support so that we can write useful tests. The MIR parsing of MC symbol operands still isn't 100%, as it forces the symbols to be non-temporary and non-local symbols with names. However, those names often can encode most (if not all) of the special semantics desired, and unnamed symbols seem especially annoying to serialize and de-serialize. While this isn't perfect or full support, it seems plenty to write tests that exercise usage of these kinds of operands. The MIR support for pre-and post-instruction symbols was quite straightforward. I chose to print them out in an as-if-operand syntax similar to debug locations as this seemed the cleanest way and let me use nice introducer tokens rather than inventing more magic punctuation like we use for memoperands. However, supporting MIR-based parsing of these symbols caused me to change the design of the symbol support to allow setting arbitrary symbols. Without this, I don't see any reasonable way to test things with MIR. Differential Revision: https://reviews.llvm.org/D50833 llvm-svn: 339962
* Add a basic integration test for C++ smart pointersVedant Kumar2018-08-161-0/+41
| | | | | | | | | Check that the debugger can pretty-print unique_ptr and shared_ptr when passed as a function argument. rdar://42314305 llvm-svn: 339961
* Remove outdated TODOs in RegisterValueAlex Langford2018-08-161-3/+0
| | | | | | | | | These TODOs were for setting m_type in RegisterValue::SetValueFromString in the case where reg_info's encoding was eEncodingUint or eEncodingSint. m_type is set by SetUInt{8,16,32,64.128} during the SetUInt call. llvm-svn: 339959
OpenPOWER on IntegriCloud