summaryrefslogtreecommitdiffstats
path: root/llvm
Commit message (Collapse)AuthorAgeFilesLines
...
* [TTI] There is actually no realistic way to pop TTI implementations offChandler Carruth2014-03-109-41/+0
| | | | | | | | | | | | | | the stack of the analysis group because they are all immutable passes. This is made clear by Craig's recent work to use override systematically -- we weren't overriding anything for 'finalizePass' because there is no such thing. This is kind of a lame restriction on the API -- we can no longer push and pop things, we just set up the stack and run. However, I'm not invested in building some better solution on top of the existing (terrifying) immutable pass and legacy pass manager. llvm-svn: 203437
* ADT/PointerIntPairTest.cpp: Appease msc17.NAKAMURA Takumi2014-03-101-1/+3
| | | | | | | - Use constructor instead of initializer list. - Disable ManyUnusedBits for now. llvm-svn: 203436
* [LCG] Ran clang-format over this too and it pointed out some fixes.Chandler Carruth2014-03-101-4/+6
| | | | llvm-svn: 203435
* [PM] While I'm here, fix a few other clang-format issues. Pulls someChandler Carruth2014-03-102-6/+6
| | | | | | lines under 80-columns, etc. llvm-svn: 203434
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-1031-414/+407
| | | | | | class. llvm-svn: 203433
* [PM] Cleanup formatting and namespace commenting. Mostly done withChandler Carruth2014-03-101-36/+45
| | | | | | | clang-format, but with some modifications by me where it got things wrong or got confused. llvm-svn: 203432
* [PM] As Dave noticed in review, I had erroneously copied the moveChandler Carruth2014-03-101-7/+9
| | | | | | | | | | | | | | | | | | constructors from the classes which only have a single reference member to many other places. This resulted in them copying their single member instead of moving. =/ Fix this. There's really not a useful test to add sadly because these move constructors are only called when something deep inside some standard library implementation *needs* to move them. Many of the types aren't even user-impacting types. Or, the objects are copyable anyways and so the result was merely a performance problem rather than a correctness problem. Anyways, thanks for the review. And this is a great example of why I wish I colud have the compiler write these for me. llvm-svn: 203431
* MC: Appease the buildbotsDavid Majnemer2014-03-101-2/+2
| | | | | | This is fallout from r203429. llvm-svn: 203430
* MC: Cleanup MCSectionMachO::ParseSectionSpecifierDavid Majnemer2014-03-101-77/+43
| | | | | | | | | Split by comma once instead of multiple times. Moving this upfront makes the rest of the code considerably simpler. No functional change. llvm-svn: 203429
* [PM] Add a comment I missed and add the special members to one moreChandler Carruth2014-03-101-0/+14
| | | | | | class that might (at some point) need them. llvm-svn: 203428
* [PM] Comment on all of the totally pointless definitions of specialChandler Carruth2014-03-101-2/+28
| | | | | | members as being te workaround MSVC. llvm-svn: 203427
* [PM] I have been educated by several folks that MSVC will neverChandler Carruth2014-03-101-23/+152
| | | | | | | | | | | | | | | | | synthesize a move constructor. Thus, for any types where move semantics are important (yea, that's essentially every type...) you must explicitly define the special members. Do so systematically throughout the pass manager as the core of the design relies heavily on move semantics. This will hopefully fix the build with MSVC 2013. We still don't know why MSVC 2012 accepted this code, but it almost certainly wasn't doing the right thing. I've also added explicit to a few single-argument constructors spotted in passing. llvm-svn: 203426
* [Sparc] Add support for decoding 'swap' instruction.Venkatraman Govindaraju2014-03-093-1/+46
| | | | llvm-svn: 203424
* Fix inconsistent whitespace.Bob Wilson2014-03-091-1/+1
| | | | llvm-svn: 203423
* Work around FreeBSD rtld rpath $ORIGIN limitationEd Maste2014-03-091-0/+3
| | | | | | | | | FreeBSD's rtld requires the DF_ORIGIN flag set in order to process $ORIGIN in rpath. FreeBSD bug http://bugs.freebsd.org/187114 llvm-svn: 203419
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-0912-65/+62
| | | | | | class. llvm-svn: 203418
* StackColoring: Use range-based for loops.Benjamin Kramer2014-03-091-79/+47
| | | | | | No functionality change. llvm-svn: 203415
* MachineModuleInfo: Turn nested std::pairs into a proper struct.Benjamin Kramer2014-03-094-26/+24
| | | | llvm-svn: 203414
* SimplifyCFG: Simplify the weight scaling algorithm.Benjamin Kramer2014-03-091-15/+6
| | | | | | No change in functionality. llvm-svn: 203413
* [LCG] Simplify a bunch of the LCG code with range for loops and auto.Chandler Carruth2014-03-091-37/+29
| | | | | | | Still more work to be done here to leverage C++11, but this clears out the glaring issues. llvm-svn: 203395
* [C++11] Add range views for various parts of a Module.Chandler Carruth2014-03-091-0/+22
| | | | llvm-svn: 203394
* Change documentation based on feedback from Chandler.Ahmed Charles2014-03-091-26/+16
| | | | llvm-svn: 203393
* [C++11] Now that we have C++11 and I've replaced the use of thisChandler Carruth2014-03-093-241/+0
| | | | | | | horrible smart pointer by std::unique_ptr and strict move semantics, rip this out. llvm-svn: 203392
* [PM] Switch new pass manager from polymorphic_ptr to unique_ptr now thatChandler Carruth2014-03-094-69/+67
| | | | | | | it is available. Also make the move semantics sufficiently correct to tolerate move-only passes, as the PassManagers *are* move-only passes. llvm-svn: 203391
* [C++11] Add llvm::make_unique, according to N3656.Ahmed Charles2014-03-093-0/+246
| | | | llvm-svn: 203387
* Revert r203230, "CodeGenPrep: sink extends of illegal types into use block."NAKAMURA Takumi2014-03-094-136/+82
| | | | | | It choked i686 stage2. llvm-svn: 203386
* De-virtualize some methods since they don't override anything.Craig Topper2014-03-091-13/+13
| | | | llvm-svn: 203379
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-0921-310/+314
| | | | | | class. llvm-svn: 203378
* IR: Change inalloca's grammar a bitDavid Majnemer2014-03-0912-40/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The grammar for LLVM IR is not well specified in any document but seems to obey the following rules: - Attributes which have parenthesized arguments are never preceded by commas. This form of attribute is the only one which ever has optional arguments. However, not all of these attributes support optional arguments: 'thread_local' supports an optional argument but 'addrspace' does not. Interestingly, 'addrspace' is documented as being a "qualifier". What constitutes a qualifier? I cannot find a definition. - Some attributes use a space between the keyword and the value. Examples of this form are 'align' and 'section'. These are always preceded by a comma. - Otherwise, the attribute has no argument. These attributes do not have a preceding comma. Sometimes an attribute goes before the instruction, between the instruction and it's type, or after it's type. 'atomicrmw' has 'volatile' between the instruction and the type while 'call' has 'tail' preceding the instruction. With all this in mind, it seems most consistent for 'inalloca' on an 'inalloca' instruction to occur before between the instruction and the type. Unlike the current formulation, there would be no preceding comma. The combination 'alloca inalloca' doesn't look particularly appetizing, perhaps a better spelling of 'inalloca' is down the road. llvm-svn: 203376
* Revert "Clean up SmallString a bit"David Blaikie2014-03-095-49/+49
| | | | | | | | | This reverts commit r203374. Ambiguities in assign... oh well. I'm just going to revert this and probably not try to recommit it as it's not terribly important. llvm-svn: 203375
* Clean up SmallString a bitDavid Blaikie2014-03-095-49/+49
| | | | | | | | | | | Move a common utility (assign(iter, iter)) into SmallVector (some of the others could be moved there too, but this one seemed particularly generic) and replace repetitions overrides with using directives. And simplify SmallVector::assign(num, element) while I'm here rather than thrashing these files (that cause everyone to rebuild) again. llvm-svn: 203374
* [C++11] Fix break due to MSVC bug.Ahmed Charles2014-03-091-1/+2
| | | | | | | | | | | | | | | MSVC (2012, 2013, 2013 Nov CTP) fail on the following code: int main() { int arr[] = {1, 2}; for (int i : arr) do {} while (0); } The fix is to put {} around the for loop. I've reported this to the MSVC team. llvm-svn: 203371
* Fix build break.Ahmed Charles2014-03-091-0/+2
| | | | llvm-svn: 203366
* [C++11] Add range based accessors for the Use-Def chain of a Value.Chandler Carruth2014-03-09100-1075/+920
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This requires a number of steps. 1) Move value_use_iterator into the Value class as an implementation detail 2) Change it to actually be a *Use* iterator rather than a *User* iterator. 3) Add an adaptor which is a User iterator that always looks through the Use to the User. 4) Wrap these in Value::use_iterator and Value::user_iterator typedefs. 5) Add the range adaptors as Value::uses() and Value::users(). 6) Update *all* of the callers to correctly distinguish between whether they wanted a use_iterator (and to explicitly dig out the User when needed), or a user_iterator which makes the Use itself totally opaque. Because #6 requires churning essentially everything that walked the Use-Def chains, I went ahead and added all of the range adaptors and switched them to range-based loops where appropriate. Also because the renaming requires at least churning every line of code, it didn't make any sense to split these up into multiple commits -- all of which would touch all of the same lies of code. The result is still not quite optimal. The Value::use_iterator is a nice regular iterator, but Value::user_iterator is an iterator over User*s rather than over the User objects themselves. As a consequence, it fits a bit awkwardly into the range-based world and it has the weird extra-dereferencing 'operator->' that so many of our iterators have. I think this could be fixed by providing something which transforms a range of T&s into a range of T*s, but that *can* be separated into another patch, and it isn't yet 100% clear whether this is the right move. However, this change gets us most of the benefit and cleans up a substantial amount of code around Use and User. =] llvm-svn: 203364
* Update comment from r203315 based on reviewAdam Nemet2014-03-081-1/+1
| | | | llvm-svn: 203361
* Adding some includes to appease build bots. Amends r203354Aaron Ballman2014-03-081-3/+5
| | | | llvm-svn: 203356
* Adding range-based STL-like helper APIs. llvm::distance() is the range ↵Aaron Ballman2014-03-081-0/+22
| | | | | | version of std::distance. llvm::copy is the range version of std::copy. llvm-svn: 203354
* Make createObjectImage and createObjectImageFromFile static methods on theLang Hames2014-03-084-74/+70
| | | | | | | | relevant subclasses of RuntimeDyldImpl. This allows construction of RuntimeDyldImpl instances to be deferred until after the target architecture is known. llvm-svn: 203352
* Change else if => if after return, after r203265Duncan P. N. Exon Smith2014-03-081-8/+9
| | | | llvm-svn: 203347
* Fix 80 cols.Ahmed Charles2014-03-081-1/+1
| | | | llvm-svn: 203346
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-0822-204/+207
| | | | | | class. llvm-svn: 203345
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-0816-237/+229
| | | | | | class. llvm-svn: 203344
* [bugpoint] Don't ignore arg in -compile-commad="tool arg"Adam Nemet2014-03-081-1/+1
| | | | | | | Args is an output parameter of the function lexCommand but the reference operator was missed. llvm-svn: 203343
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-085-36/+36
| | | | | | class. llvm-svn: 203342
* De-virtualize a method since it doesn't override anything (yay 'override' ↵Craig Topper2014-03-081-1/+1
| | | | | | keyword) and its class is in an anonymous namespace. llvm-svn: 203341
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-0812-348/+343
| | | | | | class. llvm-svn: 203340
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-0819-114/+115
| | | | | | class. llvm-svn: 203339
* DebugInfo: further improvements to test following up on r203329David Blaikie2014-03-081-7/+7
| | | | llvm-svn: 203337
* DebugInfo: Fix test fallout from r203323David Blaikie2014-03-081-1/+1
| | | | | | Will fix this harder in a moment. llvm-svn: 203329
* DebugInfo: Use DW_FORM_data4 for DW_AT_high_pc in DW_TAG_lexical_blocksDavid Blaikie2014-03-082-2/+60
| | | | | | Suggested by Adrian Prantl in code review for r203187 llvm-svn: 203323
OpenPOWER on IntegriCloud