summaryrefslogtreecommitdiffstats
path: root/llvm
Commit message (Collapse)AuthorAgeFilesLines
* Remove the IsStreamed member variable.Rafael Espindola2015-06-221-15/+9
| | | | | | | | | | | | | | | | | | Having different code paths for streamed and regular bitcode reading was a source of bugs in the past and this defines them away. It has a small but noticeable impact on performance. I timed running "opt -disable-output -disable-verify" on a ltoed clang. It goes from 14.752845231 seconds time elapsed ( +- 0.16% ) to 15.012463721 seconds time elapsed ( +- 0.11% ) Extracted from a patch by Karl Schimpf. llvm-svn: 240305
* [FaultMaps] Add a parser for the __llvm__faultmaps section.Sanjoy Das2015-06-225-1/+286
| | | | | | | | | | | | | | | Summary: The parser is exercised by llvm-objdump using -print-fault-maps. As is probably obvious, the code itself was "heavily inspired" by http://reviews.llvm.org/D10434. Reviewers: reames, atrick, JosephTremoulet Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D10491 llvm-svn: 240304
* [NFC] Capitalization in documentation.Sanjoy Das2015-06-221-1/+1
| | | | llvm-svn: 240303
* Bring r240130 back.Rafael Espindola2015-06-2225-130/+125
| | | | | | | | | | | | | | | | | | | | | | Now that pr23900 is fixed, we can bring it back with no changes. Original message: Make all temporary symbols unnamed. What this does is make all symbols that would otherwise start with a .L (or L on MachO) unnamed. Some of these symbols still show up in the symbol table, but we can just make them unnamed. In order to make sure we produce identical results when going thought assembly, all .L (not just the compiler produced ones), are now unnamed. Running llc on llvm-as.opt.bc, the peak memory usage goes from 208.24MB to 205.57MB. llvm-svn: 240302
* Avoid a Symbol -> Name -> Symbol conversion.Rafael Espindola2015-06-2217-46/+103
| | | | | | | | | | | | | | Before this we were producing a TargetExternalSymbol from a MCSymbol. That meant extracting the symbol name and fetching the symbol again down the pipeline. This patch adds a DAG.getMCSymbol that lets the MCSymbol pass unchanged on the DAG. Doing so removes the need for MO_NOPREFIX and fixes the root cause of pr23900, allowing r240130 to be committed again. llvm-svn: 240300
* MIR Serialization: Serialize machine instruction names.Alex Lorenz2015-06-229-4/+236
| | | | | | | | | | | | | | | | This commit implements initial machine instruction serialization. It serializes machine instruction names. The instructions are represented using a YAML sequence of string literals and are a part of machine basic block YAML mapping. This commit introduces a class called 'MIParser' which will be used to parse the machine instructions and operands. Reviewers: Duncan P. N. Exon Smith Differential Revision: http://reviews.llvm.org/D10481 llvm-svn: 240295
* Fix shl folding in DAG combiner.Pawel Bylica2015-06-222-1/+9
| | | | | | | | | | | | | | | | Summary: The code responsible for shl folding in the DAGCombiner was assuming incorrectly that all constants are less than 64 bits. This patch simply changes the way values are compared. Test Plan: A regression test included. Reviewers: andreadb Reviewed By: andreadb Subscribers: andreadb, test, llvm-commits Differential Revision: http://reviews.llvm.org/D10602 llvm-svn: 240291
* Add a triple to the test to fix it on some hosts.Rafael Espindola2015-06-221-1/+1
| | | | | | | | The slp vectorizer doesn't optimize this case in 32 bits. Fixes PR23453. llvm-svn: 240289
* [ORC] Add NullResolverJoseph Tremoulet2015-06-223-12/+76
| | | | | | | | | | | | | | | | | Summary: This is an implementation of RuntimeDyld::SymbolResolver that simply rejects all resolution requests; useful for clients that do not have any cross-object symbol references. Reviewers: lhames Reviewed By: lhames Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D10455 llvm-svn: 240288
* Support Solaris unused sections' gc link syntax.Rafael Espindola2015-06-221-0/+3
| | | | | | | | | It is not clear if this would work or not with LLVM_NO_DEAD_STRIP binaries, so be conservative for now. Patch by Xan López. llvm-svn: 240287
* [mips] [IAS] Add support for LAReg with identical source and destination ↵Toma Tabacu2015-06-222-15/+31
| | | | | | | | | | | | | | | | register operands. Summary: In this case, we're supposed to load the immediate in AT and then ADDu it with the source register and put it in the destination register. Reviewers: dsanders Reviewed By: dsanders Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9367 llvm-svn: 240278
* AVX-512: added VPSHUFB instruction - all SKX formsElena Demikhovsky2015-06-227-0/+184
| | | | | | Added intrinsics and encoding tests. llvm-svn: 240277
* Do not pass optimization flags to Solaris' linker.Rafael Espindola2015-06-221-1/+1
| | | | | | | | It is not supported. Patch by Xan López. llvm-svn: 240276
* Use right syntax to pass version script to Solaris' ld.Rafael Espindola2015-06-221-2/+7
| | | | | | Patch by Xan Lopez! llvm-svn: 240275
* [mips] [IAS] Add support for LASym with identical source and destination ↵Toma Tabacu2015-06-222-8/+26
| | | | | | | | | | | | | | | | | | register operands. Summary: In this case, we're supposed to load the address of the symbol in AT and then ADDu it with the source register and put it in the destination register. Reviewers: dsanders Reviewed By: dsanders Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9366 llvm-svn: 240273
* AVX-512: All forms of VCOPMRESS VEXPAND instructions,Elena Demikhovsky2015-06-225-79/+535
| | | | | | encoding tests. llvm-svn: 240272
* Fixed/added namespace ending comments using clang-tidy. NFCAlexander Kornienko2015-06-224-4/+4
| | | | | | A few more files that were fixed while preparing r240270. llvm-svn: 240271
* Reverted AVX-512 vector shuffleElena Demikhovsky2015-06-224-789/+570
| | | | llvm-svn: 240258
* [X86] Allow more call sequences to use push instructions for argument passingMichael Kuperstein2015-06-222-66/+144
| | | | | | | | | This allows more call sequences to use pushes instead of movs when optimizing for size. In particular, calling conventions that pass some parameters in registers (e.g. thiscall) are now supported. Differential Revision: http://reviews.llvm.org/D10500 llvm-svn: 240257
* AVX-512: Added intrinsics for VPERMT2W/D/Q/PS/PD andElena Demikhovsky2015-06-227-8/+718
| | | | | | | VPERMI2W/D/Q/PS/PD instructions. Added tests. llvm-svn: 240256
* [PM/AA] Hoist the AliasResult enum out of the AliasAnalysis class.Chandler Carruth2015-06-2220-137/+138
| | | | | | | | | | | | | | | | | | | | | | | | | | | This will allow classes to implement the AA interface without deriving from the class or referencing an internal enum of some other class as their return types. Also, to a pretty fundamental extent, concepts such as 'NoAlias', 'MayAlias', and 'MustAlias' are first class concepts in LLVM and we aren't saving anything by scoping them heavily. My mild preference would have been to use a scoped enum, but that feature is essentially completely broken AFAICT. I'm extremely disappointed. For example, we cannot through any reasonable[1] means construct an enum class (or analog) which has scoped names but converts to a boolean in order to test for the possibility of aliasing. [1]: Richard Smith came up with a "solution", but it requires class templates, and lots of boilerplate setting up the enumeration multiple times. Something like Boost.PP could potentially bundle this up, but even that would be quite painful and it doesn't seem realistically worth it. The enum class solution would probably work without the need for a bool conversion. Differential Revision: http://reviews.llvm.org/D10495 llvm-svn: 240255
* [PM/AA] Rework the names and comments in AliasSetTracker to moreChandler Carruth2015-06-222-44/+50
| | | | | | | | | | | | | | | | | | | | accurately describe what is being tracked. While these two enums do track mod/ref information and aliasing information, they don't represent the exact same things as either the mod/ref enums or the alias result enum in AA. They're definitions are dominated by the structure of their lattice and the bit's various semantics. This patch just calls them what they are and tries to spell out usefully distinct names for these things. This will clear the path for using a raw unscoped enum to represent some of these concepts across LLVM's analysis library. No functionality changed here. Differential Revision: http://reviews.llvm.org/D10494 llvm-svn: 240254
* Add the testcase from pr23900.Rafael Espindola2015-06-221-0/+29
| | | | llvm-svn: 240253
* [X86] Code tidyup - Use SDValue bool operator. NFC.Simon Pilgrim2015-06-211-47/+25
| | | | llvm-svn: 240249
* AsmPrinter: Don't emit empty .debug_loc entriesDuncan P. N. Exon Smith2015-06-216-14/+188
| | | | | | | | | | | If we don't know how to represent a .debug_loc entry, skip the entry entirely rather than emitting an empty one. Similarly, if a .debug_loc list has no entries, don't create the list. We still want to create the variables, just in an optimized-out form that doesn't have a DW_AT_location. llvm-svn: 240244
* AsmPrinter: Rewrite initialization of DbgVariable, NFCDuncan P. N. Exon Smith2015-06-213-64/+85
| | | | | | | | | | | | | | | | | | | | | | | There are three types of `DbgVariable`: - alloca variables, created based on the MMI table, - register variables, created based on DBG_VALUE instructions, and - optimized-out variables. This commit reconfigures `DbgVariable` to make it easier to tell which kind we have, and make initialization a little clearer. For MMI/alloca variables, `FrameIndex.size()` must always equal `Expr.size()`, and there shouldn't be an `MInsn`. For register variables (with a `MInsn`), `FrameIndex` must be empty, and `Expr` should have 0 or 1 element depending on whether it has a complex expression (registers with multiple locations use `DebugLocListIndex`). Optimized-out variables shouldn't have any of these fields. Moreover, this separates DBG_VALUE initialization until after the variable is created, simplifying logic in a future commit that changes `collectVariableInfo()` to stop creating empty .debug_loc entries/lists. llvm-svn: 240243
* [X86][SSE] Added missing stack folding test for CVTSD2SS instruction.Simon Pilgrim2015-06-211-1/+7
| | | | llvm-svn: 240241
* OptTable.h: Prune a couple of \param(s), since Arg has been ArrayRef-ized. ↵NAKAMURA Takumi2015-06-211-2/+0
| | | | | | [-Wdocumentation] llvm-svn: 240240
* Devirtualize ArgList's dtor now that -Wvirtual-dtor and C++11 allow a better ↵David Blaikie2015-06-212-14/+7
| | | | | | way to describe this situation llvm-svn: 240238
* ArrayRef-ify libDriverMainDavid Blaikie2015-06-214-10/+16
| | | | llvm-svn: 240234
* ArrayRef-ify ParseArgsDavid Blaikie2015-06-214-29/+19
| | | | llvm-svn: 240233
* Object: Add load configuration structure for 64 bit PE/COFF.Rui Ueyama2015-06-211-0/+23
| | | | llvm-svn: 240230
* Switch lowering: add heuristic for filling leaf nodes in the weight-balanced ↵Hans Wennborg2015-06-203-4/+136
| | | | | | | | | | | | | | | | | | binary search tree Sparse switches with profile info are lowered as weight-balanced BSTs. For example, if the node weights are {1,1,1,1,1,1000}, the right-most node would end up in a tree by itself, bringing it closer to the top. However, a leaf in this BST can contain up to 3 cases, and having a single case in a leaf node as in the example means the tree might become unnecessarily high. This patch adds a heauristic to the pivot selection algorithm that moves more cases into leaf nodes unless that would lower their rank. It still doesn't yield the optimal tree in every case, but I believe it's conservatibely correct. llvm-svn: 240224
* [X86][SSE] Fix PerformSExtCombine bug that accessed the wrong return value ↵Simon Pilgrim2015-06-202-3/+53
| | | | | | | | of an aggregate type. Fix to rL237885 to ensure that it accesses the correct return value of an aggregate type. llvm-svn: 240223
* [PPC] Factor vector removal into a function and remove O(n^2) behavior.Benjamin Kramer2015-06-201-25/+17
| | | | | | No functionality change intended. llvm-svn: 240222
* [SwitchLowering] Remove quadratic vector removal.Benjamin Kramer2015-06-201-12/+12
| | | | | | | This can be triggered with giant switches. No functionality change intended. llvm-svn: 240221
* [X86][SSE][CostModel] Added full set of sitofp/uitofp costings for ↵Simon Pilgrim2015-06-202-126/+755
| | | | | | | | | | | | SSE2/AVX/AVX2/AVX512F. Merged separate (but equivalent) SSE2/AVX512F tests. Removed codegen tests since these are already done better in test/CodeGen/X86. The actual cost values still need to be updated to match recent codegen improvements. llvm-svn: 240219
* Update ELFObjectWriter::reset() following r238073.Yaron Keren2015-06-201-0/+1
| | | | llvm-svn: 240218
* Rangify for loops in Inliner::runOnSCC(), NFC.Yaron Keren2015-06-201-11/+9
| | | | llvm-svn: 240215
* IndVarSimplify: Avoid UB from binding a reference to a null pointerJustin Bogner2015-06-201-3/+4
| | | | | | | | | | Calling operator* on a WeakVH whose Value is null hits undefined behaviour, since we bind the value to a reference. Instead, go through `operator Value*` so that we work with the pointer itself. Found by ubsan. llvm-svn: 240214
* Reformat.NAKAMURA Takumi2015-06-201-7/+12
| | | | llvm-svn: 240213
* Revert r240040, "[BranchFolding] Replace custom MachineInstr with ↵NAKAMURA Takumi2015-06-201-6/+46
| | | | | | | | MachineInstrExpressionTrait" It caused different emission between stage2 and stage3. Investigating. llvm-svn: 240212
* TargetInstrInfo.h: Fix r240192. [-Wdocumentation]NAKAMURA Takumi2015-06-201-2/+2
| | | | llvm-svn: 240210
* Revert "InstrProf: When reading, copy the data instead of taking a ↵Justin Bogner2015-06-203-87/+87
| | | | | | | | | | | | reference. NFC" Seems like MSVC doesn't like this: InstrProf.h(49) : error C2614: 'llvm::InstrProfRecord' : illegal member initialization: 'Hash' is not a base or member This reverts r240206. llvm-svn: 240208
* Use correct escaping for semicolon on Windows.Peter Collingbourne2015-06-201-1/+1
| | | | llvm-svn: 240207
* InstrProf: When reading, copy the data instead of taking a reference. NFCJustin Bogner2015-06-203-87/+87
| | | | | | | | | | | This consolidates the logic to read instrprof records into the on disk hash table's lookup trait and makes us copy the counter data instead of taking references to it as we read. This will simplify further changes to the format. Patch by Betul Buyukkurt. llvm-svn: 240206
* LibDriver tests require x86 target.Peter Collingbourne2015-06-201-0/+3
| | | | llvm-svn: 240205
* LibDriver: implement /libpath and $LIB; ignore /ignore and /machine.Peter Collingbourne2015-06-205-2/+70
| | | | llvm-svn: 240203
* [MCJIT] Add a FindGlobalVariableNamed utilityKeno Fischer2015-06-205-6/+63
| | | | | | | | | | | | | | | | Summary: This adds FindGlobalVariableNamed to ExecutionEngine (plus implementation in MCJIT), which is an analog of FindFunctionNamed for GlobalVariables. Reviewers: lhames Reviewed By: lhames Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D10421 llvm-svn: 240202
* LowerSwitch: Avoid some undefined behaviourJustin Bogner2015-06-201-1/+2
| | | | | | | | | | | | When a case of INT64_MIN was followed by a case that was greater than zero, we were overflowing a signed integer here. Since we've sorted the cases here anyway (and thus currentValue must be greater than nextValue) it's simple enough to avoid this by using addition rather than subtraction. Found by UBSAN on existing tests. llvm-svn: 240201
OpenPOWER on IntegriCloud