summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
* Add more DWARF 5 language constants.Bruce Mitchener2015-02-072-1/+25
| | | | | | Differential Revision: http://reviews.llvm.org/D7430 llvm-svn: 228487
* Resubmit unittests for DebugInfoPDB.Zachary Turner2015-02-071-3/+2
| | | | | | | | | | | | | | | These were originally submitted as part of r228428, but this part caused a build breakage in LLVMConfig. The library portion was resubmitted independently since it was not causing breakage. There were two reasons this was causing the build to fail. The first is that there were no Makefiles added for the PDB tests. And the second is that the DebugInfoPDB library was only being built by CMake behind an "if (MSVC)" check. This is wrong since this the library hides platform specific details, and it was causing LLVM-Config to not find the library when trying to build unittests. llvm-svn: 228482
* Support: Add dwarf::getVirtuality()Duncan P. N. Exon Smith2015-02-071-0/+8
| | | | llvm-svn: 228474
* Support: Use Dwarf.def for DW_VIRTUALITY, NFCDuncan P. N. Exon Smith2015-02-071-4/+6
| | | | | | | Use definition file for `DW_VIRTUALITY_*`. Add a `DW_VIRTUALITY_max` both for ease of testing and for future use by the `LLParser`. llvm-svn: 228473
* Support: Add dwarf::getAttributeEncoding()Duncan P. N. Exon Smith2015-02-061-0/+7
| | | | llvm-svn: 228470
* Support: Rewrite AttributeEncodingString(), NFCDuncan P. N. Exon Smith2015-02-061-17/+5
| | | | llvm-svn: 228469
* Support: Stop stringifying DW_ATE_{lo,hi}_userDuncan P. N. Exon Smith2015-02-061-2/+0
| | | | llvm-svn: 228468
* [AArch64] Use the source location of the IR branch when creating BccAhmed Bougacha2015-02-061-2/+2
| | | | | | | | | | | | | | | | | | from a conditional branch fed by an add/sub/mul-with-overflow node. We previously used the SDLoc of the overflow node, for no good reason. In some cases, this led to the Bcc and B terminators having different source orders, and DBG_VALUEs being inserted between them. The real issue is with the code that can't handle DBG_VALUEs between terminators: the few places affected by this will be fixed soon. In the meantime, fixing the SDLoc is a positive change no matter what. No tests, as I have no idea how to get .loc emitted for branches? rdar://19347133 llvm-svn: 228463
* Revert "r227976 - [PowerPC] Yet another approach to __tls_get_addr" and ↵Hal Finkel2015-02-0611-234/+108
| | | | | | | | | | | | | | related fixups Unfortunately, even with the workaround of disabling the linker TLS optimizations in Clang restored (which has already been done), this still breaks self-hosting on my P7 machine (-O3 -DNDEBUG -mcpu=native). Bill is currently working on an alternate implementation to address the TLS issue in a way that also fully elides the linker bug (which, unfortunately, this approach did not fully), so I'm reverting this now. llvm-svn: 228460
* Support: Add dwarf::getLanguage()Duncan P. N. Exon Smith2015-02-061-0/+7
| | | | llvm-svn: 228458
* Support: Rewrite dwarf::LanguageString(), NFCDuncan P. N. Exon Smith2015-02-061-29/+6
| | | | llvm-svn: 228457
* IR: Allow 32-bits for lines in debug locationDuncan P. N. Exon Smith2015-02-062-10/+2
| | | | | | | | | | | | Remove unnecessary restriction of 24-bits for line numbers in `MDLocation`. The rest of the debug info schema (with the exception of local variables) uses 32-bits for line numbers. As I introduce the specialized nodes, it makes sense to canonicalize on one size or the other. llvm-svn: 228455
* use local variables; NFCSanjay Patel2015-02-061-3/+2
| | | | llvm-svn: 228452
* Support: Stop stringifying DW_LANG_{lo,hi}_userDuncan P. N. Exon Smith2015-02-061-2/+0
| | | | llvm-svn: 228451
* AsmParser: Use DW_TAG_hi_user instead of magic constant, NFCDuncan P. N. Exon Smith2015-02-061-1/+1
| | | | llvm-svn: 228448
* AsmWriter: Extract writeTag(), NFCDuncan P. N. Exon Smith2015-02-061-5/+9
| | | | llvm-svn: 228447
* AsmWriter: Extract writeMetadataAsOperand(), NFCDuncan P. N. Exon Smith2015-02-061-5/+12
| | | | llvm-svn: 228446
* [msan] Fix "missing origin" in atomic store.Evgeniy Stepanov2015-02-061-1/+1
| | | | | | | | | | An atomic store always make the target location fully initialized (in the current implementation). It should not store origin. Initialized memory can't have meaningful origin, and, due to origin granularity (4 bytes) there is a chance that this extra store would overwrite meaningfull origin for an adjacent location. llvm-svn: 228444
* Test commit to see if it triggers an email to llvm-commits. No change.Cameron Esfahani2015-02-061-0/+1
| | | | llvm-svn: 228442
* Try to fix Makefile build for LLVMDebugInfoPDB.Zachary Turner2015-02-062-1/+15
| | | | llvm-svn: 228437
* Resubmit "Create lib/DebugInfo/PDB" (r228428)Zachary Turner2015-02-069-2/+315
| | | | | | | | | | | | | | | | | | | | This change resubmits the patch that broke the build, this time without unittests. The unittests will be submitted separately after the problem has been addressed: --Original Commit Message-- Create lib/DebugInfo/PDB. This patch creates a platform-independent interface to a PDB reader. There is currently no implementation of this interface, which will be provided in future patches. This defines the basic object model which any implementation must conform to. Reviewed by: David Blaikie Differential Revision: http://reviews.llvm.org/D7356 llvm-svn: 228435
* Use estimated number of optimized insns in unroll-threshold computation.Michael Zolotukhin2015-02-061-2/+44
| | | | | | | | | | If complete-unroll could help us to optimize away N% of instructions, we might want to do this even if the final size would exceed loop-unroll threshold. However, we don't want to unroll huge loop, and we are add AbsoluteThreshold to avoid that - this threshold will never be crossed, even if we expect to optimize 99% instructions after that. llvm-svn: 228434
* [InstSimplify] Add SimplifyFPBinOp function.Michael Zolotukhin2015-02-063-2/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | It is a variation of SimplifyBinOp, but it takes into account FastMathFlags. It is needed in inliner and loop-unroller to accurately predict the transformation's outcome (previously we dropped the flags and were too conservative in some cases). Example: float foo(float *a, float b) { float r; if (a[1] * b) r = /* a lot of expensive computations */; else r = 1; return r; } float boo(float *a) { return foo(a, 0.0); } Without this patch, we don't inline 'foo' into 'boo'. llvm-svn: 228432
* Revert "Create lib/DebugInfo/PDB."Zachary Turner2015-02-069-315/+2
| | | | | | This reverts commit 21028, as it is causing failures in LLVMConfig. llvm-svn: 228431
* [fuzzer] move default sanitizer options to a separate fileKostya Serebryany2015-02-063-7/+19
| | | | llvm-svn: 228429
* Create lib/DebugInfo/PDB.Zachary Turner2015-02-069-2/+315
| | | | | | | | | | | | This patch creates a platform-independent interface to a PDB reader. There is currently no implementation of this interface, which will be provided in future patches. This defines the basic object model which any implementation must conform to. Reviewed by: David Blaikie Differential Revision: http://reviews.llvm.org/D7356 llvm-svn: 228428
* [Orc] Move SectionMemoryManager's implementation from MCJIT to ExecutionEngine.Lang Hames2015-02-063-1/+1
| | | | | | | This is a more sensible home for SectionMemoryManager, and allows the implementation to be shared between Orc and MCJIT. llvm-svn: 228427
* [LiveIntervalAnalysis] Speed up creation of live ranges for physical registersQuentin Colombet2015-02-062-143/+316
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | by using a segment set. The patch addresses a compile-time performance regression in the LiveIntervals analysis pass (see http://llvm.org/bugs/show_bug.cgi?id=18580). This regression is especially critical when compiling long functions. Our analysis had shown that the most of time is taken for generation of live intervals for physical registers. Insertions in the middle of the array of live ranges cause quadratic algorithmic complexity, which is apparently the main reason for the slow-down. Overview of changes: - The patch introduces an additional std::set<Segment>* member in LiveRange for storing segments in the phase of initial creation. The set is used if this member is not NULL, otherwise everything works the old way. - The set of operations on LiveRange used during initial creation (i.e. used by createDeadDefs and extendToUses) have been reimplemented to use the segment set if it is available. - After a live range is created the contents of the set are flushed to the segment vector, because the set is not as efficient as the vector for the later uses of the live range. After the flushing, the set is deleted and cannot be used again. - The set is only for live ranges computed in LiveIntervalAnalysis::computeLiveInRegUnits() and getRegUnit() but not in computeVirtRegs(), because I did not bring any performance benefits to computeVirtRegs() and for some examples even brought a slow down. Patch by Vaidas Gasiunas <vaidas.gasiunas@sap.com> Differential Revision: http://reviews.llvm.org/D6013 llvm-svn: 228421
* [LV] Move addRuntimeCheck to LoopAccessAnalysisAdam Nemet2015-02-062-104/+111
| | | | | | | | | | | | | This will allow it to be shared with the new Loop Distribution pass. getFirstInst is currently duplicated across LoopVectorize.cpp and LoopAccessAnalysis.cpp. This is a short-term work-around until we figure out a better solution. NFC. (The code moved is adjusted a bit for the name of the Loop member and that PtrRtCheck is now a reference rather than a pointer.) llvm-svn: 228418
* Don't dllexport declarationsReid Kleckner2015-02-061-2/+2
| | | | | | Fixes PR22488 llvm-svn: 228411
* Make helper functions/classes/globals static. NFC.Benjamin Kramer2015-02-068-18/+27
| | | | llvm-svn: 228410
* InstCombine: Combine select sequences into a single selectMatthias Braun2015-02-061-0/+18
| | | | | | | | | | | | | | Normalize select(C0, select(C1, a, b), b) -> select((C0 & C1), a, b) select(C0, a, select(C1, a, b)) -> select((C0 | C1), a, b) This normal form may enable further combines on the And/Or and shortens paths for the values. Many targets prefer the other but can go back easily in CodeGen. Differential Revision: http://reviews.llvm.org/D7399 llvm-svn: 228409
* LiveInterval: Fix SubRange memory leak.Matthias Braun2015-02-061-1/+16
| | | | llvm-svn: 228405
* AArch64PromoteConstant: Modernize and resolve some Use<->User confusion.Benjamin Kramer2015-02-061-87/+63
| | | | | | NFC. llvm-svn: 228399
* IRCE: Demote template to ArrayRef and SmallVector to array.Benjamin Kramer2015-02-061-26/+15
| | | | | | NFC. llvm-svn: 228398
* Whitespace.Chad Rosier2015-02-061-2/+0
| | | | llvm-svn: 228397
* [PBQP] Fix comment wording. NFCArnaud A. de Grandmaison2015-02-061-1/+1
| | | | llvm-svn: 228390
* R600/SI: Don't enable WQM for V_INTERP_* instructions v2Michel Danzer2015-02-061-6/+0
| | | | | | | | | Doesn't seem necessary anymore. I think this was mostly compensating for not enabling WQM for texture sampling instructions. v2: Add test coverage Reviewed-by: Tom Stellard <tom@stellard.net> llvm-svn: 228373
* R600/SI: Also enable WQM for image opcodes which calculate LOD v3Michel Danzer2015-02-066-56/+79
| | | | | | | | | | | | | If whole quad mode isn't enabled for these, the level of detail is calculated incorrectly for pixels along diagonal triangle edges, causing artifacts. v2: Use a TSFlag instead of lots of switch cases v3: Add test coverage Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=88642 Reviewed-by: Tom Stellard <tom@stellard.net> llvm-svn: 228372
* Introduce print-memderefs to test isDereferenceablePointerRamkumar Ramachandra2015-02-063-0/+63
| | | | | | | | | | Since testing the function indirectly is tricky, introduce a direct print-memderefs pass, in the same spirit as print-memdeps, which prints dereferenceability information matched by FileCheck. Differential Revision: http://reviews.llvm.org/D7075 llvm-svn: 228369
* Small cleanup of MachineLICM.cppDaniel Jasper2015-02-051-15/+12
| | | | | | | | | | | | | Specifically: - Calculate the loop pre-header once at the stat of HoistOutOfLoop, so: - We don't-DFS walk the MachineDomTree if we aren't going to do anything - Don't call getCurPreheader for each Scope - Don't needlessly use a do-while loop - Use early exit for Scopes.size() == 0 No functional changes intended. llvm-svn: 228350
* [Hexagon] Renaming v4 compare-and-jump instructions.Colin LeMahieu2015-02-053-46/+44
| | | | llvm-svn: 228349
* [Hexagon] Deleting unused patterns.Colin LeMahieu2015-02-051-188/+0
| | | | llvm-svn: 228348
* [Hexagon] Simplifying and formatting several patterns. Changing a pattern ↵Colin LeMahieu2015-02-052-154/+88
| | | | | | multiply to be expanded. llvm-svn: 228347
* [Hexagon] Factoring a class out of some store patterns, deleting unused ↵Colin LeMahieu2015-02-051-89/+53
| | | | | | definitions and reformatting some patterns. llvm-svn: 228345
* [Hexagon] Factoring out a class for immediate transfers and cleaning up ↵Colin LeMahieu2015-02-053-61/+70
| | | | | | formatting. llvm-svn: 228343
* [ASan] Enable -asan-stack-dynamic-alloca by default.Alexey Samsonov2015-02-051-1/+1
| | | | | | | | | | | By default, store all local variables in dynamic alloca instead of static one. It reduces the stack space usage in use-after-return mode (dynamic alloca will not be called if the local variables are stored in a fake stack), and improves the debug info quality for local variables (they will not be described relatively to %rbp/%rsp, which are assumed to be clobbered by function calls). llvm-svn: 228336
* Remove the use of getSubtarget in the creation of the X86Eric Christopher2015-02-051-6/+3
| | | | | | | | | PassManager instance. In one case we can make the determination from the Triple, in the other (execution dependency pass) the pass will avoid running if we don't have any code that uses that register class so go ahead and add it to the pipeline. llvm-svn: 228334
* Use cached subtargets inside X86FixupLEAs.Eric Christopher2015-02-051-3/+2
| | | | llvm-svn: 228333
* Migrate the X86 AsmPrinter away from using the subtarget whenEric Christopher2015-02-052-14/+20
| | | | | | | | dealing with module level emission. Currently this is using the Triple to determine, but eventually the logic should probably migrate to TLOF. llvm-svn: 228332
OpenPOWER on IntegriCloud