summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Use SDValue bool check to tidyup some possible combines. NFC.Simon Pilgrim2015-03-151-5/+3
| | | | llvm-svn: 232325
* [SSE} Added tests for float4-float3 conversions (PR11580)Simon Pilgrim2015-03-151-0/+32
| | | | llvm-svn: 232324
* Implement PreprocessingRecord's and LazyVector's iterators on top of ↵Benjamin Kramer2015-03-153-241/+71
| | | | | | | | | | | | | iterator_adaptor_base This basically creates a wrapper around an 'int' that poses as an iterator. While that looks a bit counter-intuitive it works just fine because iterator operations and basic integer arithmetic works in exactly the same way. Remove the manual integer wrapping code and reduce the reliance on iterator internals in the implementation. No functionality change intended. llvm-svn: 232322
* clang-format: [JS] support cast syntax and type arguments.Daniel Jasper2015-03-152-0/+19
| | | | | | | | | Casts in TS syntax (foo = <type>bar;) should not be followed by whitespace. Patch by Martin Probst. Thank you. llvm-svn: 232321
* clang-format: [JS] more precisely detect enums.Daniel Jasper2015-03-152-6/+15
| | | | | | | | | | | | The current enum detection is overly aggressive. As NestingLevel only applies per line (?) it classifies many if not most object literals as enum declarations and adds superfluous line breaks into them. This change narrows the heuristic by requiring an assignment just before the open brace and requiring the line to start with an identifier. Patch by Martin Probst. Thank you. llvm-svn: 232320
* Factor the iterators of ImmutableSet/ImmutableMap into a common base classBenjamin Kramer2015-03-152-108/+47
| | | | | | | This simplifies code quite a bit and brings the iterators closer to C++'s iterator concept. No functional change intended. llvm-svn: 232319
* MS ABI: Don't use qualified pointee types for 'catch' EH TypeDescriptorsDavid Majnemer2015-03-155-32/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Qualifiers are located next to the TypeDescriptor in order to properly ensure that a pointer type can only be caught by a more qualified catch handler. This means that a catch handler of type 'const int *' requires an RTTI object for 'int *'. We got this correct for 'throw' but not for 'catch'. N.B. We don't currently have the means to store the qualifiers because LLVM's EH strategy is tailored to the Itanium scheme. The Itanium ABI stores qualifiers inside the type descriptor in such a way that the manner of qualification is stored in addition to the pointee type's descriptor. Perhaps the best way of modeling this for the MS ABI is using an aggregate type to bundle the qualifiers with the descriptor? This is tricky because we want to make it clear to the optimization passes which catch handlers invalidate other handlers. My current thoughts on a design for this is along the lines of: { { TypeDescriptor* TD, i32 QualifierFlags }, i32 MiscFlags } The idea is that the inner most aggregate is all that is needed to communicate that one catch handler might supercede another. The 'MiscFlags' field would be used to hold the bitpattern for the notion that the 'catch' handler does not need to invoke a copy-constructor because we are catching by reference. llvm-svn: 232318
* ImmutableSet: Rename Self to SelfTy to make it more clear it is a typeDavid Majnemer2015-03-151-10/+12
| | | | | | No functional change intended. llvm-svn: 232317
* PostOrderIterator: Remove stray semicolonDavid Majnemer2015-03-151-4/+1
| | | | llvm-svn: 232316
* IR: Default the Metadata::dump() argument "harder" after r232275Duncan P. N. Exon Smith2015-03-152-1/+11
| | | | | | | | | | Use an overload instead of a default argument for `Metadata::dump()`. The latter seems to require calling `dump(nullptr)` explicitly when using a debugger, where as the former doesn't. Other than utility for debugging, there's NFC here. llvm-svn: 232315
* Restore the gcc buildDavid Majnemer2015-03-151-17/+10
| | | | llvm-svn: 232314
* Remove iterator I accidentally left behindDavid Blaikie2015-03-151-1/+0
| | | | llvm-svn: 232312
* Remove use of reserved identifier _IteratorDavid Blaikie2015-03-151-5/+5
| | | | llvm-svn: 232311
* Remove use of reserved identifiers in TwineDavid Blaikie2015-03-151-15/+14
| | | | llvm-svn: 232310
* Remove use of reserved identifier and some excess 'inline' usageDavid Blaikie2015-03-151-58/+67
| | | | llvm-svn: 232309
* Remove reserved identifier & some unnecessary 'inline'David Blaikie2015-03-151-27/+29
| | | | llvm-svn: 232308
* Remove use of reserved identifierDavid Blaikie2015-03-151-18/+17
| | | | | | & some unnecessary 'inline' keywords llvm-svn: 232307
* [clang-tidy] Fix false positives in the misc-static-assert check ↵Alexander Kornienko2015-03-152-3/+19
| | | | | | | | | | | | | | | | http://llvm.org/PR22880 The misc-static-assert check will not warn on assert(false), assert(False), assert(FALSE); where false / False / FALSE are macros expanding to the false or 0 literals. Also added corresponding test cases. http://reviews.llvm.org/D8328 Patch by Szabolcs Sipos! llvm-svn: 232306
* [dsymutil] Add an way to iterate over a DebugMapObject symbols.Frederic Riss2015-03-151-0/+4
| | | | llvm-svn: 232305
* Remove use of unreserved identifier (_Self)David Blaikie2015-03-151-15/+36
| | | | | | And some unnecessary inline keywords llvm-svn: 232304
* Remove use of a reserved identifierDavid Blaikie2015-03-151-16/+17
| | | | | | (& some unnecessary 'inline' keywords, too) llvm-svn: 232303
* Remove use of reserved identifierDavid Blaikie2015-03-151-6/+9
| | | | | | | The C++ standard reserves all identifiers starting with an underscore followed by an uppercase letter for the implementation for any use. llvm-svn: 232302
* llvm-cxxdump: Rename llvm-vtabledump to llvm-cxxdumpDavid Majnemer2015-03-1516-54/+55
| | | | | | | llvm-vtabledump has grown enough functionality not related to vtables that it deserves a name which is more descriptive. llvm-svn: 232301
* [dsymutil] Add function size to the debug map.Frederic Riss2015-03-154-34/+49
| | | | | | | | | | | | The debug map embedded by ld64 in binaries conatins function sizes. These sizes are less precise than the ones given by the debug information (byte granularity vs linker atom granularity), but they might cover code that is referenced in the line table but not in the DIE tree (that might very well be a compiler bug that I need to investigate later). Anyway, extracting that information is necessary to be able to mimic dsymutil's behavior exactly. llvm-svn: 232300
* DbgIntrinsicInst: Downcast to specialized MDNodes in accessorsDuncan P. N. Exon Smith2015-03-153-6/+24
| | | | | | | Change accessors to downcast to `MDLocalVariable` and `MDExpression`, now that we have -verify checks in place to confirm that it's safe. llvm-svn: 232299
* Remove some unnecessary 'inline' keywordsDavid Blaikie2015-03-151-8/+8
| | | | llvm-svn: 232298
* IntervalIterator: Add move semantics rather than relying on broken implicit ↵David Blaikie2015-03-151-0/+6
| | | | | | | | copy ctor (found with -Wdeprecated) We were just getting lucky because the copy ctor would be elided by RVO. llvm-svn: 232297
* Verifier: Check debug info intrinsic argumentsDuncan P. N. Exon Smith2015-03-1530-88/+210
| | | | | | | | | | | | | | | | | | | Verify that debug info intrinsic arguments are valid. (These checks will not recurse through the full debug info graph, so they don't need to be cordoned of in `DebugInfoVerifier`.) With those checks in place, changing the `DbgIntrinsicInst` accessors to downcast to `MDLocalVariable` and `MDExpression` is natural (added isa specializations in `Metadata.h` to support this). Added tests to `test/Verifier` for the new -verify checks, and fixed the debug info in all the in-tree tests. If you have out-of-tree testcases that have started to fail to -verify, hopefully the verify checks are helpful. The most likely problem is that the expression argument is `!{}` (instead of `!MDExpression()`). llvm-svn: 232296
* -Wempty-body: fix false negative triggered by macrosDmitri Gribenko2015-03-152-1/+8
| | | | | | | | | | | | | When if statement condition ended in a macro: if (ptr == NULL); the check used to consider the definition location of NULL, instead of the current line. Patch by Manasij Mukherjee. llvm-svn: 232295
* [opaque pointer type] IRBuilder gep migration progressDavid Blaikie2015-03-154-18/+30
| | | | llvm-svn: 232294
* Made CFLAA agree with clang-format. NFC.George Burgess IV2015-03-151-9/+7
| | | | | | So everyone's lives are easier in the future llvm-svn: 232293
* Verifier: Remove unnecessary null checkDuncan P. N. Exon Smith2015-03-151-3/+3
| | | | | | | This is already assumed to be non-null above due to a dyn_cast<>. Also remove extraneous braces around statement. llvm-svn: 232292
* Verifier: Make the raw_ostream constructor argument requiredDuncan P. N. Exon Smith2015-03-151-2/+2
| | | | | | This was passed inconsistently; seems clearer to make it required anyway. llvm-svn: 232291
* Assembler: Rewrite test for function-local metadataDuncan P. N. Exon Smith2015-03-152-55/+20
| | | | | | | | | | | | | | | | | | | This test for function-local metadata did strange things, and never really sent in valid arguments for `llvm.dbg.declare` and `llvm.dbg.value` intrinsics. Those that might have once been valid have bitrotted. Rewrite it to be a targeted test for function-local metadata -- unrelated to debug info, which is tested elsewhere -- and rename it to better match other metadata-related tests. (Note: the scope of function-local metadata changed drastically during the metadata/value split, but I didn't properly clean up this testcase. Most of the IR in this file, while invalid for debug info intrinsics, used to provide coverage for various (now illegal) forms of function-local metadata.) llvm-svn: 232290
* MS ABI: Tidy up references to the ASTContextDavid Majnemer2015-03-141-20/+21
| | | | | | | CGCXXABI has a handy getContext() method. Use that instead of explicitly going through the CodeGenModule. llvm-svn: 232289
* Fix a bug related to arg escaping, and add unit tests.Zachary Turner2015-03-144-1/+80
| | | | | | | | | A recent refactor had introduced a bug where if you escaped a character, the rest of the string would get processed incorrectly. This patch fixes that bug and adds some unit tests for Args. llvm-svn: 232288
* [CMake] Make the unittests link against everything...Zachary Turner2015-03-144-6/+11
| | | | | | | | | | | | | | | | Sigh. There's really not a good alternative until we decouple python from lldb better. The only way the build works right now is by having every executable link against every LLDB library. This causes implicit transitive link dependencies on the union of everything that LLDB brings in. Which means that if all we want is one header file from interpreter, we have to bring in everything, including everything that everything depends on, which means python. There's outstanding efforts to address this, but it's not yet complete. So until then, this is all we can do. llvm-svn: 232287
* Simplified some stack folding tests.Simon Pilgrim2015-03-142-36/+36
| | | | | | Replaced explicit pmovzx* intrinsic tests with general shuffles llvm-svn: 232286
* CodeGen: Correctly initialize bitfields with non-constant initializersDavid Majnemer2015-03-142-4/+16
| | | | | | | | It is possible to construct an initializer for a bitfield which is not constant. Instead of emitting code to initialize the field before the execution of main, clang would crash. llvm-svn: 232285
* Update InstCombine to transform aggregate stores into scalar stores.Mehdi Amini2015-03-142-0/+59
| | | | | | | | | | | | | | | | | | | Summary: This is a first step toward getting proper support for aggregate loads and stores. Test Plan: Added unittests Reviewers: reames, chandlerc Reviewed By: chandlerc Subscribers: majnemer, joker.eph, chandlerc, llvm-commits Differential Revision: http://reviews.llvm.org/D7780 Patch by Amaury Sechet From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 232284
* Update LangRef now that a DataLayout is mandatory.Mehdi Amini2015-03-141-41/+42
| | | | | | | | | | | | | Reviewers: rafael, echristo Reviewed By: rafael Subscribers: rafael, llvm-commits Differential Revision: http://reviews.llvm.org/D8230 From: Mehdi Amini <mehdi.amini@apple.com> llvm-svn: 232283
* Use setVisibility() rather than assigning the value directly.Davide Italiano2015-03-142-4/+5
| | | | | | | We don't want to risk to override wrong st_other bits, and when we need to zero, we can do that explictly. llvm-svn: 232282
* Add some missed formattingDavid Blaikie2015-03-141-4/+7
| | | | llvm-svn: 232281
* [opaque pointer type] gep API migrationDavid Blaikie2015-03-143-21/+14
| | | | | | | This concludes the GetElementPtrInst::Create migration, thus marking the beginning of the IRBuilder::CreateGEP* migration to come. llvm-svn: 232280
* [opaque pointer type] gep API migrationDavid Blaikie2015-03-141-5/+6
| | | | llvm-svn: 232279
* A few minor updates based on feedback from Justin and a few things I thought ↵Chris Bieneman2015-03-142-25/+47
| | | | | | | | | | | | were missing. * Moved autotools configure & build example out of "Getting Started Quickly (A Summary)" and into BuildingLLVMWithAutoTools. * Removed the annotations that CMake is the recommended process and Autotools is alternate. * Added brief documentation about build targets under "Getting Started Quickly..." * Added Overview text to BuildingLLVMWithAutotools * Fixed up a broken link. llvm-svn: 232278
* [opaque pointer type] gep API migration, ArgPromoDavid Blaikie2015-03-141-16/+19
| | | | | | | | | This involved threading the type-to-gep through a data structure, since the code was relying on the pointer type to carry this information. I imagine there will be a lot of this work across the project... slow work chasing each use case, but the assertions will help keep me honest. llvm-svn: 232277
* [opaque pointer type] more gep API migrations (AsmParser)David Blaikie2015-03-141-1/+1
| | | | llvm-svn: 232276
* IR: Make Metadata::print() reliable and usefulDuncan P. N. Exon Smith2015-03-144-39/+190
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replumb the `AsmWriter` so that `Metadata::print()` is generally useful. (Similarly change `Metadata::printAsOperand()`.) - `SlotTracker` now has a mode where all metadata will be correctly numbered when initializing a `Module`. Normally, `Metadata` only referenced from within `Function`s gets numbered when the `Function` is incorporated. - `Metadata::print()` and `Metadata::printAsOperand()` (and `Metadata::dump()`) now take an optional `Module` argument. When provided, `SlotTracker` is initialized with the new mode, and the numbering will be complete and consistent for all calls to `print()`. - `Value::print()` uses the new `SlotTracker` mode when printing intrinsics with `MDNode` operands, `MetadataAsValue` operands, or the bodies of functions. Thus, metadata numbering will be consistent between calls to `Metadata::print()` and `Value::print()`. - `Metadata::print()` (and `Metadata::dump()`) now print the full definition of `MDNode`s: !5 = !{!6, !"abc", !7} This matches behaviour for `Value::print()`, which includes the name of instructions. - Updated call sites in `Verifier` to call `print()` instead of `printAsOperand()`. All this, so that `Verifier` can print out useful failure messages that involve `Metadata` for PR22777. Note that `Metadata::printAsOperand()` previously took an optional `bool` and `Module` operand. The former was cargo-culted from `Value::printAsOperand()` and wasn't doing anything useful. The latter didn't give consistent results (without the new `SlotTracker` mode). llvm-svn: 232275
* [opaque pointer type] more gep API migrationDavid Blaikie2015-03-145-19/+19
| | | | llvm-svn: 232274
OpenPOWER on IntegriCloud