summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
* Second patch of patch series that improves MergeFunctions performance time ↵Stepan Dyatkovskiy2014-05-071-4/+278
| | | | | | | | | | | | | | | | | from O(N*N) to O(N*log(N)). The idea is to introduce total ordering among functions set. It allows to build binary tree and perform function look-up procedure in O(log(N)) time. This patch description: Introduced total ordering among constants implemented in cmpConstants method. Method performs lexicographical comparison between constants represented as hypothetical numbers of next format: <bitcastability-trait><raw-bit-contents> Please, read cmpConstants declaration comments for more details. llvm-svn: 208173
* Work-around MSVS build breakage due to r208148Timur Iskhodzhanov2014-05-071-2/+4
| | | | llvm-svn: 208171
* [asan] Add a flag to control asm instrumentation.Evgeniy Stepanov2014-05-071-1/+8
| | | | | | With this change, asm instrumentation is disabled by default. llvm-svn: 208167
* Allow using normal .eh_frame based unwinding on ARM. Use the sameJoerg Sonnenberger2014-05-073-1/+17
| | | | | | encodings as x86. Use this exception model for NetBSD. llvm-svn: 208166
* PR19562: DebugInfo temporary MDNode leak: Don't include a temporary node to ↵David Blaikie2014-05-071-2/+1
| | | | | | | | | | replace with a variable list for methods, since they're always declarations and thus never include variables This field is used for a list of variables to ensure they are not lost during optimization (they're only included when optimizations are enabled). llvm-svn: 208159
* [C++11] Add NArySCEV->Operands iterator rangeTobias Grosser2014-05-071-8/+6
| | | | llvm-svn: 208158
* ARM: mark additional instructions as MachineFrameSetupSaleem Abdulrasool2014-05-071-5/+10
| | | | | | | | Mark up additional instructions which are part of the function prologue as MachineFrameSetup. These instructions are part of the function prologue, emitted by the PEI pass to setup the stack for use in the activating frame. llvm-svn: 208153
* ARM: fix WoA PEI instruction selectionSaleem Abdulrasool2014-05-071-1/+2
| | | | | | | | | | | The ARM::BLX instruction is an ARM mode instruction. The Windows on ARM target is limited to Thumb instructions. Correctly use the thumb mode tBLXr instruction. This would manifest as an errant write into the object file as the instruction is 4-bytes in length rather than 2. The result would be a corrupted object file that would eventually result in an executable that would crash at runtime. llvm-svn: 208152
* llvm-cov: Handle missing source files as GCOV doesJustin Bogner2014-05-071-13/+29
| | | | | | | | | | | If the source files referenced by a gcno file are missing, gcov outputs a coverage file where every line is simply /*EOF*/. This also occurs for lines in the coverage that are past the end of a file that is found. This change mimics gcov. llvm-svn: 208149
* llvm-cov: Implement --no-outputJustin Bogner2014-05-071-15/+43
| | | | | | | | In gcov, there's a -n/--no-output option, which disables the writing of any .gcov files, so that it emits only the summary info on stdout. This implements the same behaviour in llvm-cov. llvm-svn: 208148
* [Support/MemoryBuffer] Remove the assertion that the file size did not shrink.Argyrios Kyrtzidis2014-05-061-3/+0
| | | | | | This can happen in practice with the user changing files and we can recover from it. llvm-svn: 208143
* Fix ASan init function detection after clang r208128.Nico Weber2014-05-061-3/+24
| | | | llvm-svn: 208141
* Special case aliases in GlobalValue::getSection.Rafael Espindola2014-05-062-1/+6
| | | | | | | | This is similar to the getAlignment patch, but is done just for completeness. It looks like we never call getSection on an alias. All the tests still pass if the if is replaced with an assert. llvm-svn: 208139
* Update an embarassing out-of-date comment.Andrew Trick2014-05-061-5/+6
| | | | llvm-svn: 208137
* Use a range based for loop for the SubtargetFeatures print function.Eric Christopher2014-05-061-2/+2
| | | | llvm-svn: 208132
* Revert "Try simplifying LexicalScopes ownership again."David Blaikie2014-05-061-32/+28
| | | | | | | | | Speculatively reverting due to a suspicious failure on a Windows buildbot. This reverts commit 10c37a012ea11596d44cd9059fe09c959caf30c8. llvm-svn: 208131
* Fix odd formatting that snuck into last patch.Eric Christopher2014-05-061-3/+3
| | | | llvm-svn: 208130
* If a function needs a frame pointer, but r11 (aka fp) has not been used,Joerg Sonnenberger2014-05-061-0/+4
| | | | | | | | remove it from the list of unspilled registers. Otherwise the following attempt to keep the stack aligned by picking an extra GPR register to spill will not work as it picks up r11. llvm-svn: 208129
* ArrayRef-ize the Feature and Processor tables for SubtargetFeatures.Eric Christopher2014-05-062-71/+52
| | | | | | | | This removes arguments passed everywhere and allows the use of standard iteration over lists. Should be no functional change. llvm-svn: 208127
* Copy the full TailCallKind in CallInst::clone_implReid Kleckner2014-05-061-1/+1
| | | | | | | Split from the musttail inliner change. This will be covered by an opt test when the inliner change lands. llvm-svn: 208126
* Do not make -pass-remarks additive.Diego Novillo2014-05-061-11/+1
| | | | | | | | | | | | | | | | | | | | | | | | Summary: When I initially introduced -pass-remarks, I thought it would be a neat idea to make it additive. So, if one used it as: $ llc -pass-remarks=inliner --pass-remarks=loop.* the compiler would build the regular expression '(inliner)|(loop.*)'. The more I think about it, the more I regret it. This is not how other flags work. The standard semantics are right-to-left overrides. This is how clang interprets -Rpass. And I think the two should be compatible in this respect. Reviewers: qcolombet Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D3614 llvm-svn: 208122
* TTI: Estimate @llvm.fmuladd cost as fmul + fadd when FMA's aren't legal on ↵Benjamin Kramer2014-05-061-1/+7
| | | | | | the target. llvm-svn: 208115
* [X86] Improve the lowering of BITCAST dag nodes from type f64 to type v2i32 ↵Andrea Di Biagio2014-05-061-1/+41
| | | | | | | | | | | | | | | | | | | | (and vice versa). Before this patch, the backend always emitted a store+load sequence to bitconvert from f64 to i64 the input operand of a ISD::BITCAST dag node that performed a bitconvert from type MVT::f64 to type MVT::v2i32. The resulting i64 node was then used to build a v2i32 vector. With this patch, the backend now produces a cheaper SCALAR_TO_VECTOR from MVT::f64 to MVT::v2f64. That SCALAR_TO_VECTOR is then followed by a "free" bitcast to type MVT::v4i32. The elements of the resulting v4i32 are then extracted to build a v2i32 vector (which is illegal and therefore promoted to MVT::v2i64). This is in general cheaper than emitting a stack store+load sequence to bitconvert the operand from type f64 to type i64. llvm-svn: 208107
* Implememting named register intrinsicsRenato Golin2014-05-0612-0/+109
| | | | | | | | | | | This patch implements the infrastructure to use named register constructs in programs that need access to specific registers (bare metal, kernels, etc). So far, only the stack pointer is supported as a technology preview, but as it is, the intrinsic can already support all non-allocatable registers from any architecture. llvm-svn: 208104
* Special case aliases in GlobalValue::getAlignment.Rafael Espindola2014-05-062-1/+7
| | | | | | | | | An alias has the address of what it points to, so it also has the same alignment. This allows a few optimizations to see past aliases for free. llvm-svn: 208103
* Have the SubtargetFeature help routine just not return a number andEric Christopher2014-05-061-6/+4
| | | | | | | | fall back to the normal path without a cpu. While doing this fix llc to just exit when we don't have a module to process instead of asserting. llvm-svn: 208102
* Be more strict about not allowing setSection on aliases.Rafael Espindola2014-05-061-0/+5
| | | | llvm-svn: 208095
* Be more strict about not calling setAlignment on global aliases.Rafael Espindola2014-05-062-6/+15
| | | | | | | The fact that GlobalAlias::setAlignment exists at all is a side effect of how the classes are organized, it should never be used. llvm-svn: 208094
* AArch64/ARM64: implement diagnosis of unpredictable loads & storesTim Northover2014-05-061-17/+62
| | | | llvm-svn: 208091
* AArch64/ARM64: make NEON vector list parsing a bit more robustTim Northover2014-05-061-2/+5
| | | | | | | It doesn't change the results, but it seems silly not to diagnose obvious problems early on. llvm-svn: 208083
* AArch64/ARM64: add more specific diagnostic for floating imm 0.0.Tim Northover2014-05-061-4/+5
| | | | llvm-svn: 208082
* AArch64/ARM64: add more specific diagnostic for invalid vector lanesTim Northover2014-05-062-4/+21
| | | | llvm-svn: 208081
* AArch64/ARM64: produce more informative diagnostic assembling some immediatesTim Northover2014-05-062-32/+38
| | | | | | | No tests here, they'll be added when the entire neon-diagnostics.s test from AArch64 is enabled. llvm-svn: 208079
* ARM: For thumb fixups store halfwords high first and low secondChristian Pirker2014-05-061-37/+46
| | | | llvm-svn: 208076
* [ARM64] Enable alignment control option in front-end for ARM64.Kevin Qin2014-05-061-4/+15
| | | | | | This is the modification in llvm part. llvm-svn: 208074
* Use X86 memory operand enums instead of hardcoding.Craig Topper2014-05-061-16/+20
| | | | llvm-svn: 208064
* PR19598: Provide the ability to RAUW a declaration with itself, creating a ↵David Blaikie2014-05-062-20/+53
| | | | | | | | | | | | | non-temporary copy and using that to RAUW. Also, provide the ability to create temporary and non-temporary declarations, as not all declarations may be replaced by definitions later on. This provides the necessary infrastructure for Clang to fix PR19598, leaking temporary MDNodes in Clang's debug info generation. llvm-svn: 208054
* Revert "Walk back commits for unused function parameters - they're still being"Eric Christopher2014-05-061-19/+5
| | | | | | this reapplies 208012 and 208002. llvm-svn: 208037
* blockfreq: Move include to .cppDuncan P. N. Exon Smith2014-05-061-0/+1
| | | | llvm-svn: 208035
* Re-commit r208025, reverted in r208030, with a fix for a conformance issueRichard Smith2014-05-064-17/+15
| | | | | | which GCC detects and Clang does not! llvm-svn: 208033
* Revert r208025, which made buildbots unhappy for unknown reasons.Richard Smith2014-05-064-15/+17
| | | | llvm-svn: 208030
* Fix i128 div/mod on mingw64Reid Kleckner2014-05-062-0/+72
| | | | | | | | | | The Win64 docs are very clear that anything larger than 8 bytes is passed by reference, and GCC MinGW64 honors that for __modti3 and friends. Patch by Jameson Nash! llvm-svn: 208029
* [Support/MemoryBuffer] Rename IsVolatile -> IsVolatileSize and add a comment ↵Argyrios Kyrtzidis2014-05-061-22/+23
| | | | | | about the use case for the new parameter. llvm-svn: 208026
* Add llvm::function_ref (and a couple of uses of it), representing a ↵Richard Smith2014-05-064-17/+15
| | | | | | type-erased reference to a callable object. llvm-svn: 208025
* Include intrin.h before windows.h as a workaround for the x64 self-hostReid Kleckner2014-05-061-0/+1
| | | | | | | | | On x64, windows.h doesn't include intrin.h for intrinsics. It just declares them in the global namespace and uses them, expecting the compiler to lower it as a builtin. We basically need to do this in clang, eventually. llvm-svn: 208023
* [Support/MemoryBuffer] Move the IsVolatile check inside shouldUseMmap() and ↵Argyrios Kyrtzidis2014-05-061-7/+13
| | | | | | | | make sure to zero-initialize the rest of the buffer if we unexpectedly reach end-of-file while reading. llvm-svn: 208021
* Detabify.Nick Lewycky2014-05-061-2/+2
| | | | llvm-svn: 208019
* Improve 'tail' call marking in TRE. A bootstrap of clang goes from 375k ↵Nick Lewycky2014-05-051-73/+241
| | | | | | | | | | calls marked tail in the IR to 470k, however this improvement does not carry into an improvement of the call/jmp ratio on x86. The most common pattern is a tail call + br to a block with nothing but a 'ret'. The number of tail call to loop conversions remains the same (1618 by my count). The new algorithm does a local scan over the use-def chains to identify local "alloca-derived" values, as well as points where the alloca could escape. Then, a visit over the CFG marks blocks as being before or after the allocas have escaped, and annotates the calls accordingly. llvm-svn: 208017
* Walk back commits for unused function parameters - they're still beingEric Christopher2014-05-051-5/+19
| | | | | | used via dragonegg for now. llvm-svn: 208016
* Reapply: Add slp vectorization to LTO passes. The bug it exposed has been ↵Yi Jiang2014-05-051-0/+3
| | | | | | fixed by r207983. <radar://16641956> llvm-svn: 208013
OpenPOWER on IntegriCloud