summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* clang-format: Simplify and improve stop condition for formattingDaniel Jasper2015-11-022-4/+22
| | | | | | | | | | | | | | | | | | | | | | | | unaffected lines with incorrect initial indent. Starting from: namespace { int i; // There shouldn't be indentation here. int j; // <- call clang-format on this line. } Before: namespace { int i; int j; } After: namespace { int i; int j; } llvm-svn: 251824
* StringRef-ify DiagnosticInfoSampleProfile::FilenameDavid Blaikie2015-11-024-14/+14
| | | | llvm-svn: 251823
* Remove the __import__ hack of lldbtest_config.Zachary Turner2015-11-021-5/+2
| | | | | | | | I think the underlying problem was fixed by r251819, but I can't reproduce the problem. So this is to check whether it does in fact fix the problem. llvm-svn: 251822
* Fix va_arg on watchOS.Tim Northover2015-11-022-6/+15
| | | | | | As in other contexts, alignments can go up to 16 bytes in a va_list. llvm-svn: 251821
* Create an expression parser for Go.Ryan Brown2015-11-0229-397/+7215
| | | | | | | | | | | The Go interpreter doesn't JIT or use LLVM, so this also moves all the JIT related code from UserExpression to a new class LLVMUserExpression. Differential Revision: http://reviews.llvm.org/D13073 Fix merge llvm-svn: 251820
* Make dosep correctly invoke the top-level script when forking outZachary Turner2015-11-022-6/+6
| | | | | | | | | | | | | | | | | | | | packages/Python/lldbsuite is now a Python package, and it relies on its __init__.py being called to do package-level initialization. If you exec packages/Python/lldbsuite/dotest.py directly, you won't get this package level initialization, and things will fail. But without this patch, this is exactly what dosep itself does. To launch the multi-processing fork, it was hardcoding a path to dotest.py and exec'ing it from inside the package. The fix here is to get the path of the top-level script, and then exec'ing that instead. A more robust solution would involve refactoring the code so that dosep execs some internal script that imports lldbsuite, but that's a bit more involved. Differential Revision: http://reviews.llvm.org/D14157 Reviewed by: Todd Fiala llvm-svn: 251819
* ELF can handle some relocations of the form -sym + constant.Rafael Espindola2015-11-023-11/+3
| | | | | | | | Remove code that was assuming that this would never work. Thanks to Colin LeMahie for finding and diagnosing the bug. llvm-svn: 251818
* Convert tabs to spaces.Rafael Espindola2015-11-021-2/+2
| | | | llvm-svn: 251817
* Fix two issues in MergeConsecutiveStores:James Y Knight2015-11-024-13/+72
| | | | | | | | | | | | | | | | | | | | | | 1) PR25154. This is basically a repeat of PR18102, which was fixed in r200201, and broken again by r234430. The latter changed which of the store nodes was merged into from the first to the last. Thus, we now also need to prefer merging a later store at a given address into the target node, instead of an earlier one. 2) While investigating that, I also realized I'd introduced a bug in r236850. There, I removed a check for alignment -- not realizing that nothing except the alignment check was ensuring that none of the stores were overlapping! This is a really bogus way to ensure there's no aliased stores. A better solution to both of these issues is likely to always use the code added in the 'if (UseAA)' branches which rearrange the chain based on a more principled analysis. I'll look into whether that can be used always, but in the interest of getting things back to working, I think a minimal change makes sense. llvm-svn: 251816
* MachO: improve load command tests slightlyTim Northover2015-11-022-4/+22
| | | | llvm-svn: 251815
* WatchOS: update default CPU for triple after t2dsp -> dsp renameTim Northover2015-11-022-2/+6
| | | | llvm-svn: 251814
* Clang format a few prior patches (NFC)Teresa Johnson2015-11-022-2/+4
| | | | | | | I had clang formatted my earlier patches using the wrong style. Reformatted with the LLVM style. llvm-svn: 251813
* Clang format a few prior patches (NFC)Teresa Johnson2015-11-0212-299/+340
| | | | | | | I had clang formatted my earlier patches using the wrong style. Reformatted with the LLVM style. llvm-svn: 251812
* TvOS: add missing support for some libcalls.Tim Northover2015-11-023-32/+44
| | | | llvm-svn: 251811
* Sink some PTHManager includes out of Preprocessor.hReid Kleckner2015-11-025-1/+5
| | | | | | | This reduces the number of .cpp files needed to be rebuilt after touching OnDiskHashTable from 120 to 21 for me. llvm-svn: 251810
* Preserve load alignment and dereferenceable metadata during some transformationsArtur Pilipenko2015-11-0216-9/+327
| | | | | | | | Reviewed By: hfinkel Differential Revision: http://reviews.llvm.org/D13953 llvm-svn: 251809
* Make the modernize-loop-convert's const-detection smarter.Angel Garcia Gomez2015-11-027-69/+393
| | | | | | | | | | | | | | | | Summary: Now, it detects that several kinds of usages are can't modify the elements. Examples: -When an usage is a call to a const member function or operator of the element. -If the element is used as an argument to a function or constructor that takes a const-reference or a value. -LValue to RValue conversion, if the element is a fundamental type (which allows the use of most of the builtin operators). Reviewers: klimek Subscribers: cfe-commits, alexfh Differential Revision: http://reviews.llvm.org/D14198 llvm-svn: 251808
* Fix another crash in the redundant-void-arg check.Angel Garcia Gomez2015-11-022-3/+12
| | | | | | | | | | | | Summary: The check was assuming that a definition of a function always has a body, but a declaration that explicitly defaults or deletes a function is a definition too. Reviewers: alexfh Subscribers: klimek, cfe-commits Differential Revision: http://reviews.llvm.org/D14238 llvm-svn: 251807
* lit: Add '-a' option to display commands+output of all testsMatthias Braun2015-11-021-4/+9
| | | | | | | The existing -v option only displays commands and outputs for failed tests, the newly introduced -a displays it for all executed tests. llvm-svn: 251806
* Add missing override statements in ScalarEvolution.h. NFCSilviu Baranga2015-11-021-2/+2
| | | | llvm-svn: 251805
* Remove undefined behavior from some tests. Same pattern as the ↵Marshall Clow2015-11-022-10/+16
| | | | | | unitialized_copy tests llvm-svn: 251804
* Remove unreachable that was reached in modernize-use-nullptr.Angel Garcia Gomez2015-11-022-5/+18
| | | | | | | | | | | | Summary: When traversing the parent map, the check assumed that all the nodes would be either Stmt or Decl. After r251101, this is no longer true: there can be TypeLoc and NestedNameSpecifierLoc nodes. Reviewers: alexfh Subscribers: klimek, cfe-commits Differential Revision: http://reviews.llvm.org/D14229 llvm-svn: 251803
* Remove undefined behavior from some tests. Thanks to Walter Brown for the ↵Marshall Clow2015-11-022-10/+18
| | | | | | heads-up. llvm-svn: 251802
* Use static instead of anonymous namespace for helper functions. NFC.Pawel Bylica2015-11-022-9/+4
| | | | llvm-svn: 251801
* [SCEV][LV] Add SCEV Predicates and use them to re-implement stride versioningSilviu Baranga2015-11-027-132/+516
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: SCEV Predicates represent conditions that typically cannot be derived from static analysis, but can be used to reduce SCEV expressions to forms which are usable for different optimizers. ScalarEvolution now has the rewriteUsingPredicate method which can simplify a SCEV expression using a SCEVPredicateSet. The normal workflow of a pass using SCEVPredicates would be to hold a SCEVPredicateSet and every time assumptions need to be made a new SCEV Predicate would be created and added to the set. Each time after calling getSCEV, the user will call the rewriteUsingPredicate method. We add two types of predicates SCEVPredicateSet - implements a set of predicates SCEVEqualPredicate - tests for equality between two SCEV expressions We use the SCEVEqualPredicate to re-implement stride versioning. Every time we version a stride, we will add a SCEVEqualPredicate to the context. Instead of adding specific stride checks, LoopVectorize now adds a more generic SCEV check. We only need to add support for this in the LoopVectorizer since this is the only pass that will do stride versioning. Reviewers: mzolotukhin, anemet, hfinkel, sanjoy Subscribers: sanjoy, hfinkel, rengolin, jmolloy, llvm-commits Differential Revision: http://reviews.llvm.org/D13595 llvm-svn: 251800
* Make a method static. NFC.Rafael Espindola2015-11-022-6/+5
| | | | llvm-svn: 251799
* Fix for bootstrap bug introduced in r244921Nemanja Ivanovic2015-11-024-14/+30
| | | | | | | | | | This revision has introduced an issue that only affects bootstrapped compiler when it is printing the ASM. It turns out that the new code path taken due to legalizing a scalar_to_vector of i64 -> v2i64 exposes a missing check in a micro optimization to change a load followed by a scalar_to_vector into a load and splat instruction on PPC. llvm-svn: 251798
* [OPENMP] Add dependency to clang/clang-headers etc. for in-tree build of libomp.Alexey Bataev2015-11-024-7/+6
| | | | | | | Add additional dependency to clang/clang-headers/FileCheck to avoid possible troubles with in-tree build/test of libomp + allow parallel testing of libomp. Also includes bugfixes for tests + improvements to avoid possible race conditions. Differential Revision: http://reviews.llvm.org/D14055 llvm-svn: 251797
* This doesn't need a object::Archive::child_iterator.Rafael Espindola2015-11-021-2/+2
| | | | llvm-svn: 251796
* Avoid implicitly constructing a Archive::child_iterator.Rafael Espindola2015-11-021-10/+10
| | | | llvm-svn: 251794
* Handle the options and parameters separator in every MI commandHafiz Abid Qadeer2015-11-025-3/+8
| | | | | | | | | | | | | | | | | | | Summary: As per the following link, the "--" separator can appear between the options and parameters of any MI command. Previously this separator was only handled by the `-data-disassemble` MI command. I have moved the relevant code into `CMICmdBase` so that any MI command can handle the aforementioned separator. https://sourceware.org/gdb/onlinedocs/gdb/GDB_002fMI-Input-Syntax.html#GDB_002fMI-Input-Syntax Reviewers: ki.stfu Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D14197 llvm-svn: 251793
* Fix crash in redundant-void-arg check.Angel Garcia Gomez2015-11-022-10/+30
| | | | | | | | | | | | | | Summary: When applying this check to the unit tests, it would hit an assertion: llvm/tools/clang/lib/Lex/Lexer.cpp:1056: clang::SourceLocation clang::Lexer::getSourceLocation(const char*, unsigned int) const: Assertion `PP && "This doesn't work on raw lexers"' failed. Reviewers: klimek, LegalizeAdulthood, alexfh Subscribers: cfe-commits, alexfh Differential Revision: http://reviews.llvm.org/D14204 llvm-svn: 251792
* ScopInfo: Bail out in case of mismatching array dimension sizesTobias Grosser2015-11-023-11/+73
| | | | | | | | | | | In some cases different memory accesses access the very same array using a different multi-dimensional array layout where the same dimensions have different sizes. Instead of asserting when encountering this issue, we gracefully bail out for this scop. This fixes llvm.org/PR25252 llvm-svn: 251791
* Try to fix buildbots failure.Angel Garcia Gomez2015-11-022-2/+2
| | | | | | | | | | Summary: Add -fexceptions flag to enable exceptions. Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D14225 llvm-svn: 251790
* [ELF2] Ensure that .dynsym section is finalized before .gnu.hash.Igor Kudrin2015-11-022-4/+10
| | | | | | | | | It is required to fill up the GNU hash table section before its finalize() method is called. Differential Revision: http://reviews.llvm.org/D14196 llvm-svn: 251789
* modernize-use-default supports copy constructor and copy-assignment operator.Angel Garcia Gomez2015-11-023-90/+839
| | | | | | | | | | | | Summary: the check will now warn when the user provided definitions of this functions is equivalent to the explicitly defaulted ones. Reviewers: klimek Subscribers: klimek, cfe-commits, alexfh Differential Revision: http://reviews.llvm.org/D14145 llvm-svn: 251788
* Remove old and redundant optionsTobias Grosser2015-11-022-10/+0
| | | | | | | | | We remove -polly-detect-unprofitable and -polly-no-early-exit. Both have been superseeded by -polly-process-unprofitable and were only kept as aliases for our buildbots to continue to work. As all buildbots have been moved to the new options, we can now remove the old ones for good. llvm-svn: 251787
* [x86] Front-end part of MCU psABI supportAndrey Bokhanko2015-11-023-1/+16
| | | | | | | | | | | This patch implements two things in front-end for MCU psABI support: 1) "long double type is the same as double." 2) "New predefined C/C++ pre-processor symbols: iamcu and iamcu__. Differential Revision: http://reviews.llvm.org/D14205 llvm-svn: 251786
* [PatternMatch] Switch to use ValueTracking::matchSelectPatternJames Molloy2015-11-021-39/+24
| | | | | | | Instead of rolling our own min/max matching code (which is notoriously hard to get completely right), use ValueTracking's instead. llvm-svn: 251785
* [Support] Extend sys::path with user_cache_directory function.Pawel Bylica2015-11-025-21/+119
| | | | | | | | | | | | | | | | | | | | Summary: The new function sys::path::user_cache_directory tries to discover a directory suitable for cache storage for current system user. On Windows and Darwin it returns a path to system-specific user cache directory. On Linux it follows XDG Base Directory Specification, what is: - use non-empty $XDG_CACHE_HOME env var, - use $HOME/.cache. Reviewers: chapuni, aaron.ballman, rafael Subscribers: rafael, aaron.ballman, llvm-commits Differential Revision: http://reviews.llvm.org/D13801 llvm-svn: 251784
* [MS ABI] Don't zero-initialize vbptrs in basesDavid Majnemer2015-11-025-14/+108
| | | | | | | | | | | | Certain CXXConstructExpr nodes require zero-initialization before a constructor is called. We had a bug in the case where the constructor is called on a virtual base: we zero-initialized the base's vbptr field. A complementary bug is present in MSVC where no zero-initialization occurs for the subobject at all. This fixes PR25370. llvm-svn: 251783
* [ELF2] Revert of r251692George Rimar2015-11-021-10/+0
| | | | llvm-svn: 251782
* AVX512: Implemented encoding and intrinsics for VBROADCASTI32x2 and ↵Igor Breger2015-11-028-0/+542
| | | | | | | | VBROADCASTF32x2 instructions. Differential Revision: http://reviews.llvm.org/D14216 llvm-svn: 251781
* [X86] Remove assertions that check for valid scale values on scatter/gather ↵Craig Topper2015-11-021-8/+0
| | | | | | intrinsics. Nothing upstream prevented illegal values from getting here. llvm-svn: 251780
* [X86] Don't pass a scale value of 0 to scatter/gather intrinsics. This ↵Craig Topper2015-11-021-52/+52
| | | | | | causes the code emitter to throw an assertion if we try to encode it. Need to add a check to fail isel for this, but for now avoid testing it. llvm-svn: 251779
* [X86] Fold 'if' followed by just an llvm_unreachable into an assert.Craig Topper2015-11-021-8/+7
| | | | llvm-svn: 251778
* [X86] Use isa instead of dyn_cast in a bool context. NFCCraig Topper2015-11-021-2/+2
| | | | llvm-svn: 251777
* [X86] Remove some llvm_unreachables after switches that already have an ↵Craig Topper2015-11-021-5/+3
| | | | | | unreachable in their default case. llvm-svn: 251776
* [X86] Remove a 'break' after an llvm_unreachable.Craig Topper2015-11-021-3/+1
| | | | llvm-svn: 251775
* [X86] Use cast instead of dyn_cast and a null check marked unreachable.Craig Topper2015-11-021-8/+3
| | | | llvm-svn: 251774
OpenPOWER on IntegriCloud