aboutsummaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Added serialization support for APInt.Ted Kremenek2007-10-262-0/+64
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43405 91177308-0d34-0410-b5e6-96231b3b80d8
* - Remove the hacky code that forces a memcpy. Alignment is taken care of in theBill Wendling2007-10-261-11/+3
| | | | | | | | | | FE. - Explicitly pass in the alignment of the load & store. - XFAIL 2007-10-23-UnalignedMemcpy.ll because llc has a bug that crashes on unaligned pointers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43398 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a crash. Make sure TLI is not null.Evan Cheng2007-10-261-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43384 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix off-by-one stack offset computations (dwarf information) for callee-savedAnton Korobeynikov2007-10-261-1/+2
| | | | | | | | | registers in case, when FP pointer was eliminated. This should fixes misc. random EH-related crahses, when stuff is compiled with -fomit-frame-pointer. Thanks Duncan for nailing this bug! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43381 91177308-0d34-0410-b5e6-96231b3b80d8
* clo/clz aren't supported on mips I. Keep them around for when we'llEric Christopher2007-10-261-105/+107
| | | | | | | want them later (mips32/64). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43380 91177308-0d34-0410-b5e6-96231b3b80d8
* Make a comment better.Owen Anderson2007-10-261-1/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43379 91177308-0d34-0410-b5e6-96231b3b80d8
* More fleshing out of docs/Passes.html, plus some typo fixes andGordon Henriksen2007-10-262-9/+9
| | | | | | improved wording in source files. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43377 91177308-0d34-0410-b5e6-96231b3b80d8
* Loosen up iv reuse to allow reuse of the same stride but a larger type when ↵Evan Cheng2007-10-264-36/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | truncating from the larger type to smaller type is free. e.g. Turns this loop: LBB1_1: # entry.bb_crit_edge xorl %ecx, %ecx xorw %dx, %dx movw %dx, %si LBB1_2: # bb movl L_X$non_lazy_ptr, %edi movw %si, (%edi) movl L_Y$non_lazy_ptr, %edi movw %dx, (%edi) addw $4, %dx incw %si incl %ecx cmpl %eax, %ecx jne LBB1_2 # bb into LBB1_1: # entry.bb_crit_edge xorl %ecx, %ecx xorw %dx, %dx LBB1_2: # bb movl L_X$non_lazy_ptr, %esi movw %cx, (%esi) movl L_Y$non_lazy_ptr, %esi movw %dx, (%esi) addw $4, %dx incl %ecx cmpl %eax, %ecx jne LBB1_2 # bb git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43375 91177308-0d34-0410-b5e6-96231b3b80d8
* Silenced a VC++ warning.Hartmut Kaiser2007-10-251-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43374 91177308-0d34-0410-b5e6-96231b3b80d8
* Updated backpatching during object deserialization to support "smart"Ted Kremenek2007-10-251-1/+3
| | | | | | | pointers that employ unused bits in a pointer to store extra data. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43373 91177308-0d34-0410-b5e6-96231b3b80d8
* Clarified operator precedence.Hartmut Kaiser2007-10-251-2/+2
| | | | | | Silenced VC++ warning. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43372 91177308-0d34-0410-b5e6-96231b3b80d8
* Disambiguated variable name to comply with VC++'s archaic variable scoping ↵Hartmut Kaiser2007-10-251-5/+5
| | | | | | rules. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43369 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not rewrite compare instruction using iv of a different stride if the newEvan Cheng2007-10-251-36/+80
| | | | | | | stride may be rewritten using the stride of the compare instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43367 91177308-0d34-0410-b5e6-96231b3b80d8
* Support non-POSIX hosts by removing use of strncasecmp.Dale Johannesen2007-10-251-44/+53
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43364 91177308-0d34-0410-b5e6-96231b3b80d8
* Changed XXX to FIXME, and added comment to the README fileBill Wendling2007-10-252-1/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43359 91177308-0d34-0410-b5e6-96231b3b80d8
* Added special treatment of serializing NULL pointers.Ted Kremenek2007-10-252-1/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43357 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove code that's commented out.Evan Cheng2007-10-251-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43356 91177308-0d34-0410-b5e6-96231b3b80d8
* Added comment explaining why we are doing this check.Bill Wendling2007-10-251-0/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43353 91177308-0d34-0410-b5e6-96231b3b80d8
* Small formatting changes. Add a sanity check.Duncan Sands2007-10-251-10/+6
| | | | | | | | Use NVT rather than looking it up, since we have it to hand. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43341 91177308-0d34-0410-b5e6-96231b3b80d8
* Promote SETCC operands.Duncan Sands2007-10-251-0/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43340 91177308-0d34-0410-b5e6-96231b3b80d8
* Correctly extract the ValueType from a VTSDNode.Duncan Sands2007-10-251-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43339 91177308-0d34-0410-b5e6-96231b3b80d8
* If a loop termination compare instruction is the only use of its stride,Evan Cheng2007-10-251-34/+163
| | | | | | | | | | | | | | | | | | | | and the compaison is against a constant value, try eliminate the stride by moving the compare instruction to another stride and change its constant operand accordingly. e.g. loop: ... v1 = v1 + 3 v2 = v2 + 1 if (v2 < 10) goto loop => loop: ... v1 = v1 + 3 if (v1 < 30) goto loop git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43336 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix for PR1741.Owen Anderson2007-10-251-2/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43326 91177308-0d34-0410-b5e6-96231b3b80d8
* Implemented prototype serialization of pointers, including supportTed Kremenek2007-10-252-3/+63
| | | | | | | | | for backpatching. Added Deserialize::ReadVal. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43319 91177308-0d34-0410-b5e6-96231b3b80d8
* Another expansion for i64 multiply, suitable for PPC.Dale Johannesen2007-10-241-0/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43314 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix off by 1 bug in printf->puts lowering.Dale Johannesen2007-10-241-1/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43309 91177308-0d34-0410-b5e6-96231b3b80d8
* Split Serialization.h into separate headers: Serialize.h andTed Kremenek2007-10-242-24/+49
| | | | | | | | Deserialize.h Serialization.h now includes trait speciailizations for unsigned long, etc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43307 91177308-0d34-0410-b5e6-96231b3b80d8
* simplify some code by using the new isNaN predicateChris Lattner2007-10-241-4/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43305 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement a couple of foldings for ordered and unordered comparisons,Chris Lattner2007-10-241-4/+44
| | | | | | | implementing cases related to PR1738. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43289 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix comment and use the "Size" variable that's already provided.Bill Wendling2007-10-231-10/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43271 91177308-0d34-0410-b5e6-96231b3b80d8
* If there's an unaligned memcpy to/from the stack, don't lower it. Just call theBill Wendling2007-10-231-0/+13
| | | | | | | memcpy library function instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43270 91177308-0d34-0410-b5e6-96231b3b80d8
* Disable a couple more things for ppcf128.Dale Johannesen2007-10-231-2/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43267 91177308-0d34-0410-b5e6-96231b3b80d8
* This broke lots. Reverting.Bill Wendling2007-10-231-4/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43264 91177308-0d34-0410-b5e6-96231b3b80d8
* Lowering a memcpy to the stack is killing PPC. The ARM and X86 backends alreadyBill Wendling2007-10-231-0/+4
| | | | | | | | | have their own custom memcpy lowering code. This code needs to be factored out into a target-independent lowering method with hooks to the backend. In the meantime, just call memcpy if we're trying to copy onto a stack. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43262 91177308-0d34-0410-b5e6-96231b3b80d8
* Added preliminary implementation of generic object serialization to bitcode.Ted Kremenek2007-10-232-0/+135
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43261 91177308-0d34-0410-b5e6-96231b3b80d8
* Make DomTree and PostDomTree thin wrappers around DomTreeBase, rather than ↵Owen Anderson2007-10-232-30/+2
| | | | | | inheriting from it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43259 91177308-0d34-0410-b5e6-96231b3b80d8
* It's possible to commute instrctions with more than 3 operands.Evan Cheng2007-10-231-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43256 91177308-0d34-0410-b5e6-96231b3b80d8
* isSubRegOf() is a dup of isSubRegister.Evan Cheng2007-10-231-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43249 91177308-0d34-0410-b5e6-96231b3b80d8
* Temporary solution: added a different set of BCTRL_Macho / BCTRL_ELF with ↵Evan Cheng2007-10-233-8/+18
| | | | | | right callee-saved defs set for ppc64. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43248 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix memcpy lowering when addresses are 4-byte aligned but size is not ↵Evan Cheng2007-10-223-40/+86
| | | | | | multiple of 4. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43234 91177308-0d34-0410-b5e6-96231b3b80d8
* The #include <iterator> isn't needed in this header.Dan Gohman2007-10-221-3/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43232 91177308-0d34-0410-b5e6-96231b3b80d8
* Strength reduction improvements.Dan Gohman2007-10-221-20/+61
| | | | | | | | | | | | | | | | | | | | | | | - Avoid attempting stride-reuse in the case that there are users that aren't addresses. In that case, there will be places where the multiplications won't be folded away, so it's better to try to strength-reduce them. - Several SSE intrinsics have operands that strength-reduction can treat as addresses. The previous item makes this more visible, as any non-address use of an IV can inhibit stride-reuse. - Make ValidStride aware of whether there's likely to be a base register in the address computation. This prevents it from thinking that things like stride 9 are valid on x86 when the base register is already occupied. Also, XFAIL the 2007-08-10-LEA16Use32.ll test; the new logic to avoid stride-reuse elimintes the LEA in the loop, so the test is no longer testing what it was intended to test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43231 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the folding of multiplication into addresses on x86, which was brokenDan Gohman2007-10-221-0/+5
| | | | | | | by the recent {U,S}MUL_LOHI changes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43230 91177308-0d34-0410-b5e6-96231b3b80d8
* Use ptr type in the immediate field of a BxA instruction so we don't end up ↵Evan Cheng2007-10-221-1/+2
| | | | | | selecting 32-bit call instruction for ppc64. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43228 91177308-0d34-0410-b5e6-96231b3b80d8
* Add missing paratheses.Evan Cheng2007-10-221-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43227 91177308-0d34-0410-b5e6-96231b3b80d8
* Support for expanding extending loads of integers withDuncan Sands2007-10-221-16/+71
| | | | | | | funky bit-widths. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43225 91177308-0d34-0410-b5e6-96231b3b80d8
* Move the SCEV object factors from being static members of the individualDan Gohman2007-10-224-254/+276
| | | | | | | | SCEV subclasses to being non-static member functions of the ScalarEvolution class. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43224 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix up the logic for result expanding the various extensionDuncan Sands2007-10-221-27/+95
| | | | | | | | | | | | | | | | | | | | operations so they work right for integers with funky bit-widths. For example, consider extending i48 to i64 on a 32 bit machine. The i64 result is expanded to 2 x i32. We know that the i48 operand will be promoted to i64, then also expanded to 2 x i32. If we had the expanded promoted operand to hand, then expanding the result would be trivial. Unfortunately at this stage we can only get hold of the promoted operand. So instead we kind of hand-expand, doing explicit shifting and truncating to get the top and bottom halves of the i64 operand into 2 x i32, which are then used to expand the result. This is harmless, because when the promoted operand is finally expanded all this bit fiddling turns into trivial operations which are eliminated either by the expansion code itself or the DAG combiner. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43223 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix an unfolding bug.Evan Cheng2007-10-221-1/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43212 91177308-0d34-0410-b5e6-96231b3b80d8
* - Only perform the unfolding optimization when the folding in question is ↵Evan Cheng2007-10-221-5/+2
| | | | | | | | | modref. - Remove a bogus assertion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43211 91177308-0d34-0410-b5e6-96231b3b80d8