summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
* Check that the function prototypes are correct before assuming that the Nick Lewycky2008-12-271-18/+28
| | | | | | parameters are pointers. llvm-svn: 61451
* - Remove Tilmann's custom truncate lowering: it completely hosed overScott Michel2008-12-2712-628/+1148
| | | | | | | | | | | | | | | | | | | | | | | | DAGcombine's ability to find reasons to remove truncates when they were not needed. Consequently, the CellSPU backend would produce correct, but _really slow and horrible_, code. Replaced with instruction sequences that do the equivalent truncation in SPUInstrInfo.td. - Re-examine how unaligned loads and stores work. Generated unaligned load code has been tested on the CellSPU hardware; see the i32operations.c and i64operations.c in CodeGen/CellSPU/useful-harnesses. (While they may be toy test code, it does prove that some real world code does compile correctly.) - Fix truncating stores in bug 3193 (note: unpack_df.ll will still make llc fault because i64 ult is not yet implemented.) - Added i64 eq and neq for setcc and select/setcc; started new instruction information file for them in SPU64InstrInfo.td. Additional i64 operations should be added to this file and not to SPUInstrInfo.td. llvm-svn: 61447
* Add a simple pattern for matching 'bt'.Chris Lattner2008-12-251-10/+46
| | | | llvm-svn: 61426
* Fix some JIT encodings.Chris Lattner2008-12-252-10/+10
| | | | llvm-svn: 61425
* BT memory operands load from their address operand.Chris Lattner2008-12-252-3/+3
| | | | llvm-svn: 61424
* translateX86CC can never fail. Simplify it based on this.Chris Lattner2008-12-241-42/+30
| | | | llvm-svn: 61423
* Darwin likes for the EH frame to be non-local.Bill Wendling2008-12-243-4/+18
| | | | llvm-svn: 61420
* GCC doesn't emit DW_EH_PE_sdata4 for the FDE encoding on Darwin. I'm not sureBill Wendling2008-12-243-4/+18
| | | | | | about other platforms. llvm-svn: 61415
* Fix a compiler-abort on a testcase where the stack-pointer is added toDan Gohman2008-12-241-6/+13
| | | | | | | a symbolic constant. This is unlikely to be intentional, but it shouldn't crash the compiler. llvm-svn: 61408
* indentationChris Lattner2008-12-241-9/+8
| | | | llvm-svn: 61407
* Change comments so everybody can understand them, hopefully.Dale Johannesen2008-12-231-2/+2
| | | | llvm-svn: 61405
* simplify some control flow and reduce indentation, no functionality change.Chris Lattner2008-12-231-63/+46
| | | | llvm-svn: 61404
* Revert 61362 and 61402 until SPEC breakage is fixed.Dale Johannesen2008-12-231-135/+43
| | | | llvm-svn: 61403
* This fixes the bug in 175.vpr. It doesn't fix theDale Johannesen2008-12-231-2/+9
| | | | | | | | other SPEC breakage. I'll be reverting all recent changes shortly, this checking is mostly so this change doesn't get lost. llvm-svn: 61402
* Add another permutation where we should get rid of a-a.Dale Johannesen2008-12-231-4/+11
| | | | llvm-svn: 61401
* Add instruction patterns and encodings for the x86 bt instructions.Dan Gohman2008-12-234-0/+42
| | | | llvm-svn: 61400
* Restore debug printingAnton Korobeynikov2008-12-231-23/+26
| | | | llvm-svn: 61398
* Sometimes APInt syntax is really ugly... :(Anton Korobeynikov2008-12-231-10/+21
| | | | llvm-svn: 61397
* Indent stuff properlyAnton Korobeynikov2008-12-231-25/+25
| | | | llvm-svn: 61396
* Initial checkin of APInt'ififcation of switch loweringAnton Korobeynikov2008-12-232-127/+126
| | | | llvm-svn: 61395
* Silence unused variable warnings.Devang Patel2008-12-232-0/+7
| | | | llvm-svn: 61392
* Fix typo.Devang Patel2008-12-231-1/+2
| | | | | | Silence unused variable warning. llvm-svn: 61391
* Silience unused warnings.Devang Patel2008-12-232-0/+4
| | | | llvm-svn: 61390
* Clean up the atomic opcodes in SelectionDAG.Dan Gohman2008-12-236-574/+166
| | | | | | | | | | | | | This removes all the _8, _16, _32, and _64 opcodes and replaces each group with an unsuffixed opcode. The MemoryVT field of the AtomicSDNode is now used to carry the size information. In tablegen, the size-specific opcodes are replaced by size-independent opcodes that utilize the ability to compose them with predicates. This shrinks the per-opcode tables and makes the code that handles atomics much more concise. llvm-svn: 61389
* add some notes for simplifylibcalls optimizationsChris Lattner2008-12-231-0/+25
| | | | llvm-svn: 61385
* Tweak --version to include the date and time.Steve Naroff2008-12-231-0/+1
| | | | llvm-svn: 61378
* Rename BuildSchedUnits to BuildSchedGraph, and refactor theDan Gohman2008-12-236-14/+24
| | | | | | code in ScheduleDAGSDNodes' BuildSchedGraph into separate functions. llvm-svn: 61376
* Use isTerminator() instead of isBranch()||isReturn() inDan Gohman2008-12-233-5/+4
| | | | | | | | several places. isTerminator() returns true for a superset of cases, and includes things like FP_REG_KILL, which are nither return or branch but aren't safe to move/remat/etc. llvm-svn: 61373
* Avoid an unnecessary call to allnodes_size(), which is linear.Dan Gohman2008-12-231-8/+11
| | | | llvm-svn: 61372
* Minor code simplifications.Dan Gohman2008-12-231-6/+6
| | | | llvm-svn: 61371
* revert r61368.Zhongxing Xu2008-12-231-1/+1
| | | | llvm-svn: 61369
* Remove dead code.Zhongxing Xu2008-12-231-1/+1
| | | | llvm-svn: 61368
* Fixed code generation for v8i16 and v16i8 splats on X86.Mon P Wang2008-12-231-3/+33
| | | | | | Fixed lowering of v8i16 shuffles for v8i16 when we fall back to extract/insert. llvm-svn: 61365
* Fix the time regression I introduced in 464.h264ref withDale Johannesen2008-12-231-41/+126
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | my last patch to this file. The issue there was that all uses of an IV inside a loop are actually references to Base[IV*2], and there was one use outside that was the same but LSR didn't see the base or the scaling because it didn't recurse into uses outside the loop; thus, it used base+IV*scale mode inside the loop instead of pulling base out of the loop. This was extra bad because register pressure later forced both base and IV into memory. Doing that recursion, at least enough to figure out addressing modes, is a good idea in general; the change in AddUsersIfInteresting does this. However, there were side effects.... It is also possible for recursing outside the loop to introduce another IV where there was only 1 before (if the refs inside are not scaled and the ref outside is). I don't think this is a common case, but it's in the testsuite. It is right to be very aggressive about getting rid of such introduced IVs (CheckForIVReuse and the handling of nonzero RewriteFactor in StrengthReduceStridedIVUsers). In the testcase in question the new IV produced this way has both a nonconstant stride and a nonzero base, neither of which was handled before. And when inserting new code that feeds into a PHI, it's right to put such code at the original location rather than in the PHI's immediate predecessor(s) when the original location is outside the loop (a case that couldn't happen before) (RewriteInstructionToUseNewBase); better to avoid making multiple copies of it in this case. Also, the mechanism for keeping SCEV's corresponding to GEP's no longer works, as the GEP might change after its SCEV is remembered, invalidating the SCEV, and we might get a bad SCEV value when looking up the GEP again for a later loop. This also couldn't happen before, as we weren't recursing into GEP's outside the loop. I owe some testcases for this, want to get it in for nightly runs. llvm-svn: 61362
* One more permutation of subtracting off a base value.Dale Johannesen2008-12-231-0/+6
| | | | llvm-svn: 61361
* Don't forget to remove phi nodes from the value numbering table after we ↵Owen Anderson2008-12-231-0/+2
| | | | | | collapse them. llvm-svn: 61358
* Make the fuse-failed debug output human-readable.Dan Gohman2008-12-231-1/+1
| | | | llvm-svn: 61356
* Comment clean-ups. No functionality change.Bill Wendling2008-12-221-5/+3
| | | | llvm-svn: 61354
* Check that the instruction isn't in the value numbering scope.Bill Wendling2008-12-221-6/+22
| | | | llvm-svn: 61353
* Simplification: Negate the operator== method instead of implementing a full ↵Bill Wendling2008-12-221-24/+1
| | | | | | operator!= method. llvm-svn: 61352
* Add verification that deleted instruction isn't hiding in the PHI map.Bill Wendling2008-12-221-4/+17
| | | | llvm-svn: 61350
* Verify removed in a few more places.Bill Wendling2008-12-221-0/+2
| | | | llvm-svn: 61349
* Add verification functions to GVN which check to see that an instruction wasBill Wendling2008-12-221-0/+18
| | | | | | | truely deleted. These will be expanded with further checks of all of the data structures. llvm-svn: 61347
* Refactor a bunch of code out of AsmPrinter::EmitGlobalConstant into separateDan Gohman2008-12-221-182/+207
| | | | | | functions. llvm-svn: 61345
* Optimize setDepthDirty and setHeightDirty a little, as they showedDan Gohman2008-12-221-10/+16
| | | | | | up on a profile. llvm-svn: 61344
* Turn strcmp into memcmp, such as strcmp(P, "x") --> memcmp(P, "x", 2).Nick Lewycky2008-12-211-2/+30
| | | | llvm-svn: 61297
* Fix fast-isel to not emit invalid assembly when presented with aDan Gohman2008-12-201-1/+1
| | | | | | | constant shift count that doesn't fit in the shift instruction's immediate field. This fixes PR3242. llvm-svn: 61281
* Remove redundant test for vector-nature. Scan the vector first to see whetherNick Lewycky2008-12-201-4/+10
| | | | | | our optz'n will apply to it, then build the replacement vector only if needed. llvm-svn: 61279
* Use SmallVector's pop_back_val.Dan Gohman2008-12-201-4/+2
| | | | llvm-svn: 61277
* Use the correct Preds and Succs lists in setHeightDirty()Dan Gohman2008-12-201-4/+4
| | | | | | and setDepthDirty(), respectively. This fixes PR3241. llvm-svn: 61276
OpenPOWER on IntegriCloud