summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
* Replace LDriu*[bhdw]_indexed_V4 instructions with "def Pats".Jyotsna Verma2013-02-013-504/+33
| | | | llvm-svn: 174193
* Add appropriate TSFlags to the instructions that must be always extended.Jyotsna Verma2013-02-011-148/+147
| | | | llvm-svn: 174186
* InstSimplify: stripAndComputeConstantOffsets can be called with vectors of ↵Benjamin Kramer2013-02-011-10/+18
| | | | | | | | | | pointers too. Prepare it for vectors of pointers and handle simple cases. We don't handle complicated cases because accumulateConstantOffset bails on pointer vectors. Fixes selfhost on i386. llvm-svn: 174179
* Remove currently unused register decoder from AArch64.Tim Northover2013-02-011-14/+0
| | | | | | This should fix a warning when building this backend. llvm-svn: 174177
* Revert r174152. The shift amount may overflow and in that case this ↵Nadav Rotem2013-02-011-6/+0
| | | | | | transformation is illegal. llvm-svn: 174156
* Optimize shift lefts of a constant by a value plus constant into a single shift.Nadav Rotem2013-02-011-0/+6
| | | | llvm-svn: 174152
* Remove some dead code, improve some asserts, and other assorted changes. No ↵Bill Wendling2013-02-012-29/+13
| | | | | | functionality change. llvm-svn: 174132
* Add a comment explaining an unavailable optimization.Dan Gohman2013-02-011-0/+28
| | | | llvm-svn: 174131
* Remove one of the odious 'Raw' methods.Bill Wendling2013-02-012-13/+3
| | | | llvm-svn: 174130
* Use iterators instead of relying upon a bitmask of attributes to remove ↵Bill Wendling2013-02-011-11/+17
| | | | | | attributes from an AttrBuilder. llvm-svn: 174123
* Rewrite instsimplify's handling if icmp on pointer values to remove theDan Gohman2013-02-011-56/+88
| | | | | | | | | | | | remaining use of AliasAnalysis concepts such as isIdentifiedObject to prove pointer inequality. @external_compare in test/Transforms/InstSimplify/compare.ll shows a simple case where a noalias argument can be equal to a global variable address, and while AliasAnalysis can get away with saying that these pointers don't alias, instsimplify cannot say that they are not equal. llvm-svn: 174122
* Fix another typo in the classof definitions that doesn't (currently)Chandler Carruth2013-02-011-1/+1
| | | | | | have any effect. Spotted by Eli in review, thanks!!! llvm-svn: 174121
* Add iterators to the AttributeSet class so that we can access the Attributes ↵Bill Wendling2013-01-311-0/+12
| | | | | | in a nice way. llvm-svn: 174120
* An alloca can be equal to an argument. It can't *alias* an alloca, but it couldDan Gohman2013-01-311-12/+0
| | | | | | | be equal, since there's nothing preventing a caller from correctly predicting the stack location of an alloca. llvm-svn: 174119
* Switch the code added in r173885 to use the new, shiny RTTIChandler Carruth2013-01-312-9/+5
| | | | | | | | | | | | | | | | | | | | | | | infrastructure on MCStreamer to test for whether there is an MCELFStreamer object available. This is just a cleanup on the AsmPrinter side of things, moving ad-hoc tests of random APIs to a direct type query. But the AsmParser completely broken. There were no tests, it just blindly cast its streamer to an MCELFStreamer and started manipulating it. I don't have a test case -- this actually failed on LLVM's own regression test suite. Unfortunately the failure only appears when the stars, compilers, and runtime align to misbehave when we read a pointer to a formatted_raw_ostream as-if it were an MCAssembler. =/ UBSan would catch this immediately. Many thanks to Matt for doing about 80% of the debugging work here in GDB, Jim for helping to explain how exactly to fix this, and others for putting up with the hair pulling that ensued during debugging it. llvm-svn: 174118
* s/AttrBuilder::addAttributes/AttrBuilder::addAttribute/g because that's more ↵Bill Wendling2013-01-311-15/+15
| | | | | | descriptive of what it actually is. llvm-svn: 174116
* Give the MCStreamer class hierarchy LLVM RTTI facilities for use withChandler Carruth2013-01-318-40/+57
| | | | | | | | | | | | | | | | isa<> and dyn_cast<>. In several places, code is already hacking around the absence of this, and there seem to be several interfaces that might be lifted and/or devirtualized using this. This change was based on a discussion with Jim Grosbach about how best to handle testing for specific MCStreamer subclasses. He said that this was the correct end state, and everything else was too hacky so I decided to just make it so. No functionality should be changed here, this is just threading the kind through all the constructors and setting up the classof overloads. llvm-svn: 174113
* Remove the AttrBuilder form of the Attribute::get creators.Bill Wendling2013-01-312-34/+38
| | | | | | | | | | | | | The AttrBuilder is for building a collection of attributes. The Attribute object holds only one attribute. So it's not really useful for the Attribute object to have a creator which takes an AttrBuilder. This has two fallouts: 1. The AttrBuilder no longer holds its internal attributes in a bit-mask form. 2. The attributes are now ordered alphabetically (hence why the tests have changed). llvm-svn: 174110
* Update AMDGPURegisterInfo::eliminateFrameIndex() corresponding to r174083.NAKAMURA Takumi2013-01-312-0/+2
| | | | llvm-svn: 174106
* R600: Fold clamp, neg, absTom Stellard2013-01-311-3/+48
| | | | | | | Patch by: Vincent Lejeune Reviewed-by: Tom Stellard <thomas.stellard@amd.com> llvm-svn: 174099
* R600: Consider bitcast when folding const_address node.Tom Stellard2013-01-312-0/+11
| | | | | | | Patch by: Vincent Lejeune Reviewed-by: Tom Stellard <thomas.stellard@amd.com> llvm-svn: 174098
* R600: Make store_dummy intrinsic more general by passing export typeTom Stellard2013-01-312-4/+9
| | | | | | | Patch by: Vincent Lejeune Reviewed-by: Tom Stellard <thomas.stellard@amd.com> llvm-svn: 174097
* Remove unused variable, which should have been removed with r174083.Chad Rosier2013-01-311-1/+0
| | | | llvm-svn: 174094
* Linker: correctly link in dbg.declareManman Ren2013-01-311-2/+17
| | | | | | | | | | | | | | | | | | | This is a re-worked version of r174048. Given source IR: call void @llvm.dbg.declare(metadata !{i32* %argc.addr}, metadata !14), !dbg !15 we used to generate call void @llvm.dbg.declare(metadata !27, metadata !28), !dbg !29 !27 = metadata !{null} With this patch, we will correctly generate call void @llvm.dbg.declare(metadata !{i32* %argc.addr}, metadata !27), !dbg !28 Looking up %argc.addr in ValueMap will return null, since %argc.addr is already correctly set up, we can use identity mapping. rdar://problem/13089880 llvm-svn: 174093
* Add support for emitting a string attribute.Bill Wendling2013-01-312-45/+77
| | | | | | | | | | Attributes that are strings are typically target-dependent attributes. They are of this form in the IR: "attr" "attr" = "val" llvm-svn: 174090
* Add braces, so my head doesn't explode.Chad Rosier2013-01-311-1/+2
| | | | llvm-svn: 174088
* Update AArch64 backend to changed eliminateFrameIndex interface.Tim Northover2013-01-312-13/+10
| | | | llvm-svn: 174086
* When lowering memcpys to loads and stores, make sure we don't promote alignmentsLang Hames2013-01-311-0/+9
| | | | | | past the natural stack alignment. llvm-svn: 174085
* [Dwarf] early exit to avoid creating dangling DIEsManman Ren2013-01-311-1/+6
| | | | | | | | | | | | We used to create children DIEs for a scope, then check whether ScopeDIE is null. If ScopeDIE is null, the children DIEs will be dangling. Other DIEs can link to those dangling DIEs, which are not emitted at all, causing dwarf error. The current testing case is 4k lines, from MultiSource/BenchMark/McCat/09-vor. rdar://problem/13071959 llvm-svn: 174084
* [PEI] Pass the frame index operand number to the eliminateFrameIndex function.Chad Rosier2013-01-3124-173/+135
| | | | | | | Each target implementation was needlessly recomputing the index. Part of rdar://13076458 llvm-svn: 174083
* interpreter: Fix errant fallthrough.Jim Grosbach2013-01-311-1/+3
| | | | llvm-svn: 174080
* Object: Fix errant fallthrough.Jim Grosbach2013-01-311-0/+1
| | | | llvm-svn: 174079
* RuntimeDyld: Fix errant fallthrough.Jim Grosbach2013-01-311-0/+1
| | | | llvm-svn: 174078
* [MC] bundle alignment: prevent padding instructions from crossing bundle ↵Derek Schuff2013-01-311-4/+20
| | | | | | boundaries llvm-svn: 174067
* Add AArch64 as an experimental target.Tim Northover2013-01-3172-2/+22640
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for AArch64 (ARM's 64-bit architecture) to LLVM in the "experimental" category. Currently, it won't be built unless requested explicitly. This initial commit should have support for: + Assembly of all scalar (i.e. non-NEON, non-Crypto) instructions (except the late addition CRC instructions). + CodeGen features required for C++03 and C99. + Compilation for the "small" memory model: code+static data < 4GB. + Absolute and position-independent code. + GNU-style (i.e. "__thread") TLS. + Debugging information. The principal omission, currently, is performance tuning. This patch excludes the NEON support also reviewed due to an outbreak of batshit insanity in our legal department. That will be committed soon bringing the changes to precisely what has been approved. Further reviews would be gratefully received. llvm-svn: 174054
* Annotate BumpPtrAllocator for MemorySanitizer.Evgeniy Stepanov2013-01-311-0/+7
| | | | | | | This change adds MemorySanitizer annotations to BumpPtrAllocator to improve report quality. llvm-svn: 174051
* Revert r173946. This breaks compilation of googletest with ClangAlexey Samsonov2013-01-311-11/+2
| | | | llvm-svn: 174048
* Remove the Attribute::hasAttributes() function.Bill Wendling2013-01-312-10/+1
| | | | | | | That function doesn't make sense anymore because there's only one attribute per Attribute object now. llvm-svn: 174044
* Revert r174026, "Remove Attribute::hasAttributes() and make ↵NAKAMURA Takumi2013-01-312-6/+15
| | | | | | | | Attribute::hasAttribute() private." It broke many hosts to crash. llvm-svn: 174035
* Change stripAndComputeConstantOffsets to accept a NULL DataLayout pointerDan Gohman2013-01-311-10/+15
| | | | | | as well. llvm-svn: 174030
* Add a comment.Dan Gohman2013-01-311-0/+4
| | | | llvm-svn: 174028
* Move isKnownNonNull out of AliasAnalysis.h and into ValueTracking.cpp sinceDan Gohman2013-01-313-17/+16
| | | | | | | it isn't really an AliasAnalysis concept, and ValueTracking has similar things that it could plausibly share code with some day. llvm-svn: 174027
* Remove Attribute::hasAttributes() and make Attribute::hasAttribute() private.Bill Wendling2013-01-312-15/+6
| | | | | | | | The Attribute::hasAttributes() is kind of meaningless since an Attribute can have only one attribute. And we would rather people use the 'operator==' instead of Attribute::hasAttribute(). llvm-svn: 174026
* Change GetPointerBaseWithConstantOffset's DataLayout argument from aDan Gohman2013-01-316-56/+55
| | | | | | | reference to a pointer, so that it can handle the case where DataLayout is not available and behave conservatively. llvm-svn: 174024
* Make the AttrBuilder creation method of Attribute private so that people ↵Bill Wendling2013-01-311-1/+3
| | | | | | won't use it. llvm-svn: 174023
* Revert for now:Bill Wendling2013-01-312-15/+20
| | | | | | | | | --- Reverse-merging r174010 into '.': U include/llvm/IR/Attributes.h U lib/IR/Verifier.cpp U lib/IR/Attributes.cpp llvm-svn: 174012
* Remove the AttrBuilder version of the Attribute::get function.Bill Wendling2013-01-312-20/+15
| | | | | | | | The AttrBuilder is there to build up multiple attributes. The Attribute class represents only one attribute at a time. So remove this unnecessary builder creator method. llvm-svn: 174010
* Whitespace.Eric Christopher2013-01-311-9/+9
| | | | llvm-svn: 174009
* Check and allow floating point registers to select the size of theEric Christopher2013-01-311-2/+2
| | | | | | | register for inline asm. This conforms to how gcc allows for effective casting of inputs into gprs (fprs is already handled). llvm-svn: 174008
* Minor code simplification.Dan Gohman2013-01-311-1/+1
| | | | llvm-svn: 174005
OpenPOWER on IntegriCloud