summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [ConstnatFolding] Teach the folder how to fold ConstantVectorDavid Majnemer2016-07-2913-109/+114
| | | | | | | | | | | A ConstantVector can have ConstantExpr operands and vice versa. However, the folder had no ability to fold ConstantVectors which, in some cases, was an optimization barrier. Instead, rephrase the folder in terms of Constants instead of ConstantExprs and teach callers how to deal with failure. llvm-svn: 277099
* [AVX512] Remove the intrinsic forms of VMOVSS/VMOVSD. We don't need two ↵Craig Topper2016-07-293-31/+45
| | | | | | | | different forms of 'rr' and 'rm'. This matches SSE/AVX. I'm not convinced the patterns for the rm_Int was correct anyway. It had a tied source that should't exist for the unmasked version. The load form of MOVSS always zeros the most significant bits. I've left the patterns off the masked load instructions as I'm not sure what the correct pattern should be and we don't have any tests currently. Nor do we implement masked scalar load intrinsics in clang currently. llvm-svn: 277098
* [clang-tidy] Fixes to modernize-use-emplacePiotr Padlewski2016-07-295-45/+182
| | | | | | | | Not everything is valid, but it should works for 99.8% cases https://reviews.llvm.org/D22208 llvm-svn: 277097
* [CFLAA] Check for pointer types in more places.George Burgess IV2016-07-291-2/+4
| | | | | | | | | | | | | | This patch fixes an assertion that fires when we try to add non-pointer Values to the CFLGraph. Centralizing the check for whether something is/isn't a pointer type isn't completely trivial (and, in some cases, would end up being entirely redundant), but it may be beneficial to do so if this trips us up more in the future. Patch by Jia Chen. Differential Revision: https://reviews.llvm.org/D22947 llvm-svn: 277096
* [Parser] Fix bug where delayed typo in conditional expression was corrected ↵Erik Pilkington2016-07-292-3/+19
| | | | | | | | | | twice Patch by David Tarditi! Differential revision: https://reviews.llvm.org/D22930 llvm-svn: 277095
* Change a test to be less prone to random failures due toWolfgang Pieb2016-07-291-55/+55
| | | | | | | unintended matches of label numbers to debug metadata handles in release builds. llvm-svn: 277094
* Add LLVM_ENABLE_LLD option to use LLD as C/C++ linker.Eugene Zelenko2016-07-292-0/+7
| | | | | | Differential revision: https://reviews.llvm.org/D22896 llvm-svn: 277093
* Capture stderr when checking for gold versionTeresa Johnson2016-07-291-3/+5
| | | | | | | On MacOS the ld version is emitted to stderr, resulting in lots of messages in the ninja check output. llvm-svn: 277092
* Fixed commentPiotr Padlewski2016-07-291-3/+0
| | | | llvm-svn: 277091
* Simplify. readAssignment never returns a nullptr.Rui Ueyama2016-07-291-4/+3
| | | | llvm-svn: 277090
* Added ThinLTO inlining statisticsPiotr Padlewski2016-07-296-9/+445
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: copypasta doc of ImportedFunctionsInliningStatistics class \brief Calculate and dump ThinLTO specific inliner stats. The main statistics are: (1) Number of inlined imported functions, (2) Number of imported functions inlined into importing module (indirect), (3) Number of non imported functions inlined into importing module (indirect). The difference between first and the second is that first stat counts all performed inlines on imported functions, but the second one only the functions that have been eventually inlined to a function in the importing module (by a chain of inlines). Because llvm uses bottom-up inliner, it is possible to e.g. import function `A`, `B` and then inline `B` to `A`, and after this `A` might be too big to be inlined into some other function that calls it. It calculates this statistic by building graph, where the nodes are functions, and edges are performed inlines and then by marking the edges starting from not imported function. If `Verbose` is set to true, then it also dumps statistics per each inlined function, sorted by the greatest inlines count like - number of performed inlines - number of performed inlines to importing module Reviewers: eraman, tejohnson, mehdi_amini Subscribers: mehdi_amini, llvm-commits Differential Revision: https://reviews.llvm.org/D22491 llvm-svn: 277089
* Move the code which knows how to get information about the sharedJason Molenda2016-07-296-63/+188
| | | | | | | | | | cache from ObjectFileMachO (very wrong place) to the DynamicLoader plugins (better place). Not much change to the code itself, although the old ObjectFileMachO method would try both the new dyld SPI and reading the dyld_all_image_infos structure. In the new methods, I've separated those into the appropriate DynamicLoader plugins. llvm-svn: 277088
* Revert "Don't invoke getName() from Function::isIntrinsic().", rL276942.Justin Lebar2016-07-285-19/+12
| | | | | | | | | This broke some out-of-tree AMDGPU tests that relied on the old behavior wherein isIntrinsic() would return true for any function that starts with "llvm.". And in general that change will not play nicely with out-of-tree backends. llvm-svn: 277087
* [sanitizer] Simplify and future-proof maybeMarkSanitizerLibraryCallNoBuiltin().Evgeniy Stepanov2016-07-281-17/+6
| | | | | | | | | | | | | | | | | | | | Sanitizers set nobuiltin attribute on certain library functions to avoid a situation where such function is neither instrumented nor intercepted. At the moment the list of interesting functions is hardcoded. This change replaces it with logic based on TargetLibraryInfo::hasOptimizedCodegen and the presense of readnone function attribute (sanitizers are generally interested in memory behavior of library functions). This is expected to be a no-op change: the new logic matches exactly the same set of functions. r276771 (currently reverted) added mempcpy() to the list, breaking MSan tests. With this change, r276771 can be safely re-landed. llvm-svn: 277086
* [IR] Introduce a non-integral pointer typeSanjoy Das2016-07-285-0/+111
| | | | | | | | | | | | | | | Summary: This change adds a `ni` specifier in the `datalayout` string to denote pointers in some given address spaces as "non-integral", and adds some typing rules around these special pointers. Reviewers: majnemer, chandlerc, atrick, dberlin, eli.friedman, tstellarAMD, arsenm Subscribers: arsenm, mcrosier, llvm-commits Differential Revision: https://reviews.llvm.org/D22488 llvm-svn: 277085
* [BPI] Add new LazyBPI analysisAdam Nemet2016-07-289-18/+200
| | | | | | | | | | | | | | | | | | | | | | Summary: The motivation is the same as in D22141: In order to add the hotness attribute to optimization remarks we need BFI to be available in all passes that emit optimization remarks. BFI depends on BPI so unless we make this lazy as well we would still compute BPI unconditionally. The solution is to use the new LazyBPI pass in LazyBFI and only compute BPI when computation of BFI is requested by the client. I extended the laziness test using a LoopDistribute test to also cover BPI. Reviewers: hfinkel, davidxl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D22835 llvm-svn: 277083
* [docs] Coverage: Reference the new -output-dir optionVedant Kumar2016-07-281-1/+1
| | | | llvm-svn: 277081
* [docs] Mention some new options in llvm-covVedant Kumar2016-07-281-7/+7
| | | | llvm-svn: 277080
* [asan] Enable the rest of use-after-scope testsVitaly Buka2016-07-283-15/+13
| | | | | | | | | | | | | | | | Summary: Test where broken because of missing lifetime markers for temps and because of aggressive optimization which removed markers in some cases. PR27453 Reviewers: eugenis, kcc Subscribers: llvm-commits, kubabrecka Differential Revision: https://reviews.llvm.org/D22894 llvm-svn: 277074
* AMDGPU/SI: Don't handle a loop if there is no loop at all for a terminator BB.Changpeng Fang2016-07-282-0/+73
| | | | | | | | Differential Revision: http://reviews.llvm.org/D22021 Reviewed by: arsenm llvm-svn: 277073
* Do not remove empty lifetime.start/lifetime.end rangesVitaly Buka2016-07-282-0/+40
| | | | | | | | | | | | | | | | | | | | | | | Summary: Asan stack-use-after-scope check should poison alloca even if there is no access between start and end. This is possible for code like this: for (int i = 0; i < 3; i++) { int x; p = &x; } "Loop Invariant Code Motion" will move "p = &x;" out of the loop, making start/end range empty. PR27453 Reviewers: eugenis Differential Revision: https://reviews.llvm.org/D22842 llvm-svn: 277072
* Should be committed as one CL.Vitaly Buka2016-07-282-40/+0
| | | | | | This reverts commits r277068 r277067 r277066. llvm-svn: 277071
* Revert "[ObjC] Consider availability of context when emitting availability ↵Erik Pilkington2016-07-286-94/+21
| | | | | | | | | | warnings" Reverting r277058, while I fugure out why it broke internal bots. This reverts commit e514ffa8b657416c6784bbe6da9f5de19365103d. llvm-svn: 277070
* [asan] Add const into few methodsVitaly Buka2016-07-281-10/+10
| | | | | | | | | | | | Summary: No functional changes Reviewers: eugenis Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D22899 llvm-svn: 277069
* Do not remove empty lifetime.start/lifetime.end rangesVitaly Buka2016-07-282-18/+13
| | | | | | | | | | | | | | | | | | | | | | | Summary: Asan stack-use-after-scope check should poison alloca even if there is no access between start and end. This is possible for code like this: for (int i = 0; i < 3; i++) { int x; p = &x; } "Loop Invariant Code Motion" will move "p = &x;" out of the loop, making start/end range empty. PR27453 Reviewers: eugenis Differential Revision: https://reviews.llvm.org/D22842 llvm-svn: 277068
* manedVitaly Buka2016-07-282-6/+45
| | | | llvm-svn: 277067
* rangeVitaly Buka2016-07-281-0/+6
| | | | llvm-svn: 277066
* Small refinement on the memory segment support in core files thatJason Molenda2016-07-281-0/+17
| | | | | | | | | | | Greg added in r272276 -- when working with a non-user-process mach-o core file, force the permissions to readable + executable, else the unwinder can stop backtracing early if it gets a pc value in a segment that it thinks is non-executable. <rdar://problem/27138456> <rdar://problem/27462904> llvm-svn: 277065
* [CUDA] Unswitch enumerators in the selection of the offloading tool chain.Samuel Antao2016-07-281-2/+2
| | | | llvm-svn: 277064
* Rework CFG simplification in bugpointDaniel Berlin2016-07-281-48/+164
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: Depends on D22841 We now use a much simpler CFG simplification routine for bugpoint, because SimplifyCFG is no longer a good match for what bugpoint wants to do. At the same time, to make sure we don't lose anything valuable it was doing, SimplifyCFG is now run as a per-BB reduction pass. With this and D22841 combined, bugpoint operates both much faster on the large testcases i have, and reduces them to pretty much minimal testcases (in one case, bugpoint used to leave about 6000 useless blocks, and now it leaves 3 ...) Reviewers: chandlerc, majnemer Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D22845 llvm-svn: 277063
* [ELF] - Removed excessive check. NFC.George Rimar2016-07-281-1/+1
| | | | | | Thanks to Rui Ueyama who noticed that. llvm-svn: 277062
* Remove a duplicated block in cmake.Stephane Sezer2016-07-281-13/+0
| | | | | | | | | | | | | | Summary: This is supposed to find the python lib dir and seems like it's just been copied twice by mistake. Reviewers: tfiala Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D22891 llvm-svn: 277060
* [ELF] - Attempt to fix BB after 277042.George Rimar2016-07-281-1/+1
| | | | | | | | http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-ubuntu-fast/builds/17294 Change: std::make_unique -> llvm::make_unique llvm-svn: 277059
* [ObjC] Consider availability of context when emitting availability warningsErik Pilkington2016-07-286-21/+94
| | | | | | | | | | This means that a function marked with an availability attribute can safely refer to a declaration that is greater than the deployment target, but less then or equal to the context availability without -Wpartial-availability firing. Differential revision: https://reviews.llvm.org/D22697 llvm-svn: 277058
* [PM] Port LowerGuardIntrinsic to the new PM.Michael Kuperstein2016-07-287-10/+55
| | | | llvm-svn: 277057
* [ELF] - Cosmetic change. NFC.George Rimar2016-07-281-1/+1
| | | | | | peek()[0] == '*' changed to peek().startswith("*") llvm-svn: 277043
* [ELF] - Linkerscript: implemented filename specification.George Rimar2016-07-284-35/+89
| | | | | | | | | | | | | | | Scripts can contain something like: KEEP (*crtbegin.o(.ctors)) What means that "*crtbegin.o" is a wildcard of file to take the sections from. This is some kind of opposite to EXCLUDE_FILE and used in FreeBSD script: https://svnweb.freebsd.org/base/head/sys/conf/ldscript.amd64?revision=284870&view=markup#l122 Patch implements this. Differential revision: https://reviews.llvm.org/D22852 llvm-svn: 277042
* Fix some sign compare warnings breaking the -Werror buildDavid Blaikie2016-07-281-2/+2
| | | | llvm-svn: 277040
* Revert r277038 until clearing why tests fail.Alina Sbirlea2016-07-281-9/+10
| | | | llvm-svn: 277039
* Remove TargetBaseAlign. Keep alignment for stack adjustments.Alina Sbirlea2016-07-281-10/+9
| | | | | | | | | | | | | | Summary: TargetBaseAlign is no longer required since LSV checks if target allows misaligned accesses. A constant defining a base alignment is still needed for stack accesses where alignment can be adjusted. Reviewers: llvm-commits, jlebar Subscribers: mzolotukhin, arsenm Differential Revision: https://reviews.llvm.org/D22936 llvm-svn: 277038
* Really try to pacify the build bots :/David Majnemer2016-07-281-1/+1
| | | | llvm-svn: 277037
* Try to passify the buildersDavid Majnemer2016-07-281-0/+1
| | | | llvm-svn: 277036
* [ELF] - Linkerscript: implemented += operator.George Rimar2016-07-282-18/+42
| | | | | | | | | | | | | | | | | Sometimes += is used to move the location counter. Example from the wild is: .dbg_excpt _DBG_EXCPT_ADDR (NOLOAD) : { . += (DEFINED (_DEBUGGER) ? 0x8 : 0x0); https://github.com/chipKIT32/pic32-Arduino-USB-Bootloader-original/blob/master/boot-linkerscript.ld Patch implements it and opens way for others type of assignments (-= *= etc), though I think only += is actual to support. Differential revision: https://reviews.llvm.org/D22916 llvm-svn: 277035
* Make CommonInputSection singleton class.Rui Ueyama2016-07-285-26/+24
| | | | | | | | | All other singleton instances are accessible globally. CommonInputSection shouldn't be an exception. Differential Revision: https://reviews.llvm.org/D22935 llvm-svn: 277034
* [coroutines] Part 3 of N: Adding Boilerplate for Coroutine PassesDavid Majnemer2016-07-2816-3/+385
| | | | | | | | | | | | | This adds boilerplate code for all coroutine passes, the passes are no-ops for now. Also, a small test has been added to verify that passes execute in the expected order or not at all if coroutine support is disabled. Patch by Gor Nishanov! Differential Revision: https://reviews.llvm.org/D22847 llvm-svn: 277033
* [docs] Add sub-mod example by Chris to GitHub proposalRenato Golin2016-07-281-0/+5
| | | | llvm-svn: 277032
* Fix build breaks after r277028Krzysztof Parzyszek2016-07-282-1/+5
| | | | llvm-svn: 277031
* Missed updating a GlobalISel bit in my last commitMatthias Braun2016-07-281-1/+1
| | | | | | GlobalISel isn't built by default so I missed it. llvm-svn: 277030
* [analyzer] Update the web manual for checker developers.Artem Dergachev2016-07-281-70/+154
| | | | | | | | | | | | | | | | Fix the explanation of how to run tests after migration from autotools to cmake. Significantly expand the "debugging" section with more interesting stuff. Update the table of contents accordingly. Fix paragraphs in the overview section. Differential Revision: https://reviews.llvm.org/D22874 llvm-svn: 277029
* [Hexagon] Implement MI-level constant propagationKrzysztof Parzyszek2016-07-2813-2/+3402
| | | | llvm-svn: 277028
OpenPOWER on IntegriCloud