summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
* Use a smallvector for inactiveCounts and initialize it lazily Chris Lattner2008-02-261-4/+10
| | | | | | | | instead of init'ing it maximally to zeros on entry. getFreePhysReg is pretty hot and only a few elements are typically used. This speeds up linscan by 5% on 176.gcc. llvm-svn: 47631
* Rename PrintableName to Name.Bill Wendling2008-02-2613-40/+39
| | | | llvm-svn: 47629
* Change "Name" to "AsmName" in the target register info. Gee, a refactoring toolBill Wendling2008-02-2613-41/+44
| | | | | | would have been a Godsend here! llvm-svn: 47625
* Enable -coalescer-commute-instrs by default.Evan Cheng2008-02-261-1/+1
| | | | llvm-svn: 47623
* Avoid aborting on invalid shift counts.Dan Gohman2008-02-261-4/+18
| | | | llvm-svn: 47612
* Fix PR2096, a regression introduced with my patch last night. ThisChris Lattner2008-02-261-1/+1
| | | | | | also fixes cfrac, flops, and 175.vpr llvm-svn: 47605
* Fix a nasty bug in LegalizeTypes (spotted inDuncan Sands2008-02-266-60/+70
| | | | | | | | | | | | | | | | | CodeGen/PowerPC/illegal-element-type.ll): suppose a node X is processed, and processing maps it to a node Y. Then X continues to exist in the DAG, but with no users. While processing some other node, a new node may be created that happens to be equal to X, and thus X will be reused rather than a truly new node. This can cause X to "magically reappear", and since it is in the Processed state in will not be reprocessed, so at the end of type legalization the illegal node X can still be present. The solution is to replace X with Y whenever X gets resurrected like this. llvm-svn: 47601
* De-tabify.Bill Wendling2008-02-261-1/+1
| | | | llvm-svn: 47598
* This is possible:Evan Cheng2008-02-261-2/+8
| | | | | | | | | vr1 = extract_subreg vr2, 3 ... vr3 = extract_subreg vr1, 2 The end result is vr3 is equal to vr2 with subidx 2. llvm-svn: 47592
* Fix isNegatibleForFree to not return true for ConstantFP nodes Chris Lattner2008-02-261-33/+47
| | | | | | | | | after legalize. Just because a constant is legal (e.g. 0.0 in SSE) doesn't mean that its negated value is legal (-0.0). We could make this stronger by checking to see if the negated constant is actually legal post negation, but it doesn't seem like a big deal. llvm-svn: 47591
* Refactor inline asm constraint matching code out of SDIsel into TargetLowering.Evan Cheng2008-02-262-93/+17
| | | | llvm-svn: 47587
* Make some static variables const.Dan Gohman2008-02-251-3/+3
| | | | llvm-svn: 47566
* Convert MaskedValueIsZero and all its users to use APInt. Also addDan Gohman2008-02-257-68/+97
| | | | | | a SignBitIsZero function to simplify a common use case. llvm-svn: 47561
* All remat'ed loads cannot be folded into two-address code. Not just argument ↵Evan Cheng2008-02-251-4/+4
| | | | | | loads. This change doesn't really have any impact on codegen. llvm-svn: 47557
* In debug builds check that the key property holds: allDuncan Sands2008-02-251-12/+30
| | | | | | result and operand types are legal. llvm-svn: 47546
* Correctly determine whether a argument load can be folded into its uses.Evan Cheng2008-02-251-45/+52
| | | | llvm-svn: 47545
* Add support to LegalizeTypes for building legal vectorsDuncan Sands2008-02-243-1/+103
| | | | | | | | | out of illegal elements (BUILD_VECTOR). Uses and beefs up BUILD_PAIR, though it didn't really have to. Like most of LegalizeTypes, does not support soft-float. This cures all "make check" vector building failures. llvm-svn: 47537
* Some platforms use the same name for 32-bit and 64-bit registers (likeBill Wendling2008-02-241-4/+4
| | | | | | | | | %r3 on PPC) in their ASM files. However, it's hard for humans to read during debugging. Adding a new field to the register data that lets you specify a different name to be printed than the one that goes into the ASM file -- %x3 instead of %r3, for instance. llvm-svn: 47534
* Rematerialization logic was overly conservative when it comes to loads from ↵Evan Cheng2008-02-231-20/+6
| | | | | | fixed stack slots. llvm-svn: 47529
* If remating a machine instr with virtual register operand, make sure the vr ↵Evan Cheng2008-02-231-2/+1
| | | | | | is avaliable at all uses regardless of whether it would be folded. llvm-svn: 47526
* Recognize loads of arguments as re-materializable first. Therefore if ↵Evan Cheng2008-02-231-24/+26
| | | | | | isReallyTriviallyReMaterializable() returns true it doesn't confuse it as a "normal" re-materializable instruction. llvm-svn: 47520
* Fix spill weight updating bug.Evan Cheng2008-02-231-15/+27
| | | | llvm-svn: 47507
* Same isPhysRegAvailable bug as local register allocator.Evan Cheng2008-02-221-1/+1
| | | | llvm-svn: 47500
* Really really bad local register allocator bug. On X86, it was never using ↵Evan Cheng2008-02-221-1/+1
| | | | | | | | ESI, EDI, and EBP because of a bug in RALocal::isPhysRegAvailable(). For example, when it checks if ESI is available, it then looks at registers aliases to ESI. SIL is marked -2 (not allocatable) but isPhysRegAvailable() incorrectly assumes it is in use and returns false for ESI. llvm-svn: 47499
* Add debugging printfs.Evan Cheng2008-02-221-0/+2
| | | | llvm-svn: 47496
* Make sure reload of implicit uses are issued before remat's.Evan Cheng2008-02-221-3/+15
| | | | llvm-svn: 47492
* Pass alignment on ByVal parameters, from FE, allDale Johannesen2008-02-221-0/+9
| | | | | | the way through. It is now used for codegen. llvm-svn: 47484
* Enable re-materialization of instructions which have virtual register ↵Evan Cheng2008-02-222-39/+187
| | | | | | | | operands if the definition of the operand also reaches its uses. llvm-svn: 47475
* Fix compiler warning.Evan Cheng2008-02-221-1/+1
| | | | llvm-svn: 47468
* Fix a regression in 403.gcc and 186.crafty introduced in 47383. To testDan Gohman2008-02-222-28/+30
| | | | | | | that a value is >= 32, check that all of the high bits are zero, not just one or more. llvm-svn: 47467
* Make the clobber analysis a bit more smart: we only are careful about Chris Lattner2008-02-211-3/+13
| | | | | | | early clobbers if the clobber list contains a *register* not some thing like {memory}, {dirflag} etc. llvm-svn: 47457
* Treat clobber operands like early clobbers: if we haveChris Lattner2008-02-211-0/+16
| | | | | | | | | any, we force sdisel to do all regalloc for an asm. This leads to gross but correct codegen. This fixes the rest of PR2078. llvm-svn: 47454
* Clear PhysRegPartUse for the sub register as well.Bill Wendling2008-02-211-1/+1
| | | | llvm-svn: 47453
* Adjust the MaxAlignment for the special register scavenging spill slot.Bill Wendling2008-02-211-0/+3
| | | | llvm-svn: 47452
* Help testing.Evan Cheng2008-02-211-0/+7
| | | | llvm-svn: 47448
* Better names as per Evan's requestAndrew Lenharth2008-02-211-9/+10
| | | | llvm-svn: 47435
* Atomic op support. If any gcc test uses __sync builtins, it might start ↵Andrew Lenharth2008-02-213-1/+120
| | | | | | failing on archs that haven't implemented them yet llvm-svn: 47430
* Add support for matching mem operands. This fixes PR1133, patch byChris Lattner2008-02-211-1/+7
| | | | | | Eli Friedman. This implements CodeGen/Generic/2008-02-20-MatchingMem.ll. llvm-svn: 47428
* Fix a (harmless) but where vregs were added to the used reg lists for Chris Lattner2008-02-211-9/+26
| | | | | | | | | | inline asms. Fix PR2078 by marking aliases of registers used when a register is marked used. This prevents EAX from being allocated when AX is listed in the clobber set for the asm. llvm-svn: 47426
* Clean up some spilling code using MachineRegisterInfo.Evan Cheng2008-02-211-22/+51
| | | | llvm-svn: 47416
* Remove one of the fixmes that I put in there. From Evan:Bill Wendling2008-02-201-2/+3
| | | | | | | | No need to go up more levels. A def of a register also sets its sub-registers (so if PhysRegInfo[SuperReg] is NULL, it means SuperReg's super registers are not previously defined). llvm-svn: 47399
* Improve some comments explaining the "handle kills" stuff better.Bill Wendling2008-02-201-2/+4
| | | | llvm-svn: 47395
* Fix comment.Bill Wendling2008-02-201-2/+1
| | | | llvm-svn: 47389
* assert is more effective reminder then FIXME tag for unimplemented features.Devang Patel2008-02-201-1/+1
| | | | llvm-svn: 47388
* LegalizeTypes support for scalarizing a vector storeDuncan Sands2008-02-204-8/+46
| | | | | | | | | and splitting extract_subvector. This fixes nine "make check" testcases, for example 2008-02-04-ExtractSubvector.ll and (partially) CodeGen/Generic/vector.ll. llvm-svn: 47384
* Convert Legalize to use the APInt form of ComputeMaskedBits.Dan Gohman2008-02-202-14/+19
| | | | llvm-svn: 47383
* Add explicit keywords.Dan Gohman2008-02-201-1/+1
| | | | llvm-svn: 47382
* Convert DAGCombiner to use the APInt form of ComputeMaskedBits.Dan Gohman2008-02-201-12/+13
| | | | llvm-svn: 47381
* Use APInt::intersects.Dan Gohman2008-02-201-4/+4
| | | | llvm-svn: 47380
* Fix newly-introduced 4.3 warningsAnton Korobeynikov2008-02-202-3/+6
| | | | llvm-svn: 47375
OpenPOWER on IntegriCloud