Dan Gohman
							
						 
						
							 
							
							
							
							
								
							
							
								a79db30d28 
								
							 
						 
						
							
							
								
								Tidy up several unbeseeming casts from pointer to intptr_t.  
							
							 
							
							... 
							
							
							
							llvm-svn: 55779 
							
						 
						
							2008-09-04 17:05:41 +00:00  
						
					 
				
					
						
							
							
								 
								Dan Gohman
							
						 
						
							 
							
							
							
							
								
							
							
								3b46030375 
								
							 
						 
						
							
							
								
								Pool-allocation for MachineInstrs, MachineBasicBlocks, and  
							
							 
							
							... 
							
							
							
							MachineMemOperands. The pools are owned by MachineFunctions.
This drastically reduces the number of calls to malloc/free made
during the "Emit" phase of scheduling, as well as later phases
in CodeGen. Combined with other changes, this speeds up the
"instruction selection" phase of CodeGen by 10% in some cases.
llvm-svn: 53212 
							
						 
						
							2008-07-07 23:14:23 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								7d98a48f15 
								
							 
						 
						
							
							
								
								- Remove calls to copyKillDeadInfo which is an N^2 function. Instead, propagate kill / dead markers as new instructions are constructed in foldMemoryOperand, convertToThressAddress, etc.  
							
							 
							
							... 
							
							
							
							- Also remove LiveVariables::instructionChanged, etc. Replace all calls with cheaper calls which update VarInfo kill list.
llvm-svn: 53097 
							
						 
						
							2008-07-03 09:09:37 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								18e46d455b 
								
							 
						 
						
							
							
								
								Cosmetic changes.  
							
							 
							
							... 
							
							
							
							llvm-svn: 52479 
							
						 
						
							2008-06-19 01:21:26 +00:00  
						
					 
				
					
						
							
							
								 
								Dan Gohman
							
						 
						
							 
							
							
							
							
								
							
							
								0479aa5c0b 
								
							 
						 
						
							
							
								
								Change class' public PassInfo variables to by initialized with the  
							
							 
							
							... 
							
							
							
							address of the PassInfo directly instead of calling getPassInfo.
This eliminates a bunch of dynamic initializations of static data.
Also, fold RegisterPassBase into PassInfo, make a bunch of its
data members const, and rearrange some code to initialize data
members in constructors instead of using setter member functions.
llvm-svn: 51022 
							
						 
						
							2008-05-13 02:05:11 +00:00  
						
					 
				
					
						
							
							
								 
								Dan Gohman
							
						 
						
							 
							
							
							
							
								
							
							
								d78c400b5b 
								
							 
						 
						
							
							
								
								Clean up the use of static and anonymous namespaces. This turned up  
							
							 
							
							... 
							
							
							
							several things that were neither in an anonymous namespace nor static
but not intended to be global.
llvm-svn: 51017 
							
						 
						
							2008-05-13 00:00:25 +00:00  
						
					 
				
					
						
							
							
								 
								Bill Wendling
							
						 
						
							 
							
							
							
							
								
							
							
								6b8bd513d4 
								
							 
						 
						
							
							
								
								Constify isSourceDefinedByImplicitDef function. Otherwise, just formatting  
							
							 
							
							... 
							
							
							
							changes that don't change functionality.
llvm-svn: 51004 
							
						 
						
							2008-05-12 22:15:05 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								bec201fa06 
								
							 
						 
						
							
							
								
								If all sources of a PHI node are defined by an implicit_def, just emit an implicit_def instead of a copy.  
							
							 
							
							... 
							
							
							
							llvm-svn: 50927 
							
						 
						
							2008-05-10 00:17:50 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								33281864c1 
								
							 
						 
						
							
							
								
								If a PHI node has a single implicit_def source, replace it with an implicit_def instead of a copy.  
							
							 
							
							... 
							
							
							
							llvm-svn: 49543 
							
						 
						
							2008-04-11 17:54:45 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								14bee50e06 
								
							 
						 
						
							
							
								
								Undo PHI elimination copy placement patch. This causes coalescing (performace) issues.  
							
							 
							
							... 
							
							
							
							llvm-svn: 49198 
							
						 
						
							2008-04-04 01:20:05 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								aacf4f15b3 
								
							 
						 
						
							
							
								
								- PHI elimination also eliminates implicit_def that fits into a PHI node rather than copying it.  
							
							 
							
							... 
							
							
							
							- Be (slightly) smarter about where to place the copies.
llvm-svn: 49165 
							
						 
						
							2008-04-03 16:38:20 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								be3d44c3cb 
								
							 
						 
						
							
							
								
								Remove #include<map> from LiveVariables.h. Not referenced.  
							
							 
							
							... 
							
							
							
							llvm-svn: 49099 
							
						 
						
							2008-04-02 17:23:50 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								6325446666 
								
							 
						 
						
							
							
								
								Refactor code. Remove duplicated functions that basically do the same thing as  
							
							 
							
							... 
							
							
							
							findRegisterUseOperandIdx, findRegisterDefOperandIndx. Fix some naming inconsistencies.
llvm-svn: 47927 
							
						 
						
							2008-03-05 00:59:57 +00:00  
						
					 
				
					
						
							
							
								 
								Dan Gohman
							
						 
						
							 
							
							
							
							
								
							
							
								3a4be0fdef 
								
							 
						 
						
							
							
								
								Rename MRegisterInfo to TargetRegisterInfo.  
							
							 
							
							... 
							
							
							
							llvm-svn: 46930 
							
						 
						
							2008-02-10 18:45:23 +00:00  
						
					 
				
					
						
							
							
								 
								Owen Anderson
							
						 
						
							 
							
							
							
							
								
							
							
								1ba66e0cec 
								
							 
						 
						
							
							
								
								Remove DefInst from LiveVariables::VarInfo.  Use the facilities on MachineRegisterInfo instead.  
							
							 
							
							... 
							
							
							
							llvm-svn: 46016 
							
						 
						
							2008-01-15 22:02:46 +00:00  
						
					 
				
					
						
							
							
								 
								Bill Wendling
							
						 
						
							 
							
							
							
							
								
							
							
								0c209430b4 
								
							 
						 
						
							
							
								
								Don't recalculate the loop info and loop dominators analyses if they're  
							
							 
							
							... 
							
							
							
							preserved.
llvm-svn: 45596 
							
						 
						
							2008-01-04 20:54:55 +00:00  
						
					 
				
					
						
							
							
								 
								Owen Anderson
							
						 
						
							 
							
							
							
							
								
							
							
								7a73ae9a86 
								
							 
						 
						
							
							
								
								Move copyRegToReg from MRegisterInfo to TargetInstrInfo.  This is part of the  
							
							 
							
							... 
							
							
							
							Machine-level API cleanup instigated by Chris.
llvm-svn: 45470 
							
						 
						
							2007-12-31 06:32:00 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								a10fff51d9 
								
							 
						 
						
							
							
								
								Rename SSARegMap -> MachineRegisterInfo in keeping with the idea  
							
							 
							
							... 
							
							
							
							that "machine" classes are used to represent the current state of
the code being compiled.  Given this expanded name, we can start 
moving other stuff into it.  For now, move the UsedPhysRegs and
LiveIn/LoveOuts vectors from MachineFunction into it.
Update all the clients to match.
This also reduces some needless #includes, such as MachineModuleInfo
from MachineFunction.
llvm-svn: 45467 
							
						 
						
							2007-12-31 04:13:23 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								a5bb370aa4 
								
							 
						 
						
							
							
								
								Add new shorter predicates for testing machine operands for various types:  
							
							 
							
							... 
							
							
							
							e.g. MO.isMBB() instead of MO.isMachineBasicBlock().  I don't plan on 
switching everything over, so new clients should just start using the 
shorter names.
Remove old long accessors, switching everything over to use the short
accessor: getMachineBasicBlock() -> getMBB(), 
getConstantPoolIndex() -> getIndex(), setMachineBasicBlock -> setMBB(), etc.
llvm-svn: 45464 
							
						 
						
							2007-12-30 23:10:15 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								f3ebc3f3d2 
								
							 
						 
						
							
							
								
								Remove attribution from file headers, per discussion on llvmdev.  
							
							 
							
							... 
							
							
							
							llvm-svn: 45418 
							
						 
						
							2007-12-29 20:36:04 +00:00  
						
					 
				
					
						
							
							
								 
								Owen Anderson
							
						 
						
							 
							
							
							
							
								
							
							
								9d86ef12c8 
								
							 
						 
						
							
							
								
								Bring UsedBlocks back.  StrongPHIElimination needs this information.  
							
							 
							
							... 
							
							
							
							llvm-svn: 43866 
							
						 
						
							2007-11-08 01:20:48 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								c1e4e3743b 
								
							 
						 
						
							
							
								
								Allow copyRegToReg to emit cross register classes copies.  
							
							 
							
							... 
							
							
							
							Tested with "make check"!
llvm-svn: 42346 
							
						 
						
							2007-09-26 06:25:56 +00:00  
						
					 
				
					
						
							
							
								 
								Nick Lewycky
							
						 
						
							 
							
							
							
							
								
							
							
								e7da2d6ac3 
								
							 
						 
						
							
							
								
								Fix typo in comment.  
							
							 
							
							... 
							
							
							
							llvm-svn: 36873 
							
						 
						
							2007-05-06 13:37:16 +00:00  
						
					 
				
					
						
							
							
								 
								Devang Patel
							
						 
						
							 
							
							
							
							
								
							
							
								8c78a0bff0 
								
							 
						 
						
							
							
								
								Drop 'const'  
							
							 
							
							... 
							
							
							
							llvm-svn: 36662 
							
						 
						
							2007-05-03 01:11:54 +00:00  
						
					 
				
					
						
							
							
								 
								Devang Patel
							
						 
						
							 
							
							
							
							
								
							
							
								e95c6ad802 
								
							 
						 
						
							
							
								
								Use 'static const char' instead of 'static const int'.  
							
							 
							
							... 
							
							
							
							Due to darwin gcc bug, one version of darwin linker coalesces
static const int, which defauts PassID based pass identification.
llvm-svn: 36652 
							
						 
						
							2007-05-02 21:39:20 +00:00  
						
					 
				
					
						
							
							
								 
								Devang Patel
							
						 
						
							 
							
							
							
							
								
							
							
								09f162ca6a 
								
							 
						 
						
							
							
								
								Do not use typeinfo to identify pass in pass manager.  
							
							 
							
							... 
							
							
							
							llvm-svn: 36632 
							
						 
						
							2007-05-01 21:15:47 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								4c53d321aa 
								
							 
						 
						
							
							
								
								VarInfo::UsedBlocks is no longer used. Remove.  
							
							 
							
							... 
							
							
							
							llvm-svn: 36250 
							
						 
						
							2007-04-18 05:04:38 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								a5a0c7c909 
								
							 
						 
						
							
							
								
								Increment use count of new virtuals created during PHI elimination.  
							
							 
							
							... 
							
							
							
							llvm-svn: 36233 
							
						 
						
							2007-04-18 00:36:11 +00:00  
						
					 
				
					
						
							
							
								 
								Evan Cheng
							
						 
						
							 
							
							
							
							
								
							
							
								5382426577 
								
							 
						 
						
							
							
								
								Keep UsedBlocks info accurate.  
							
							 
							
							... 
							
							
							
							llvm-svn: 35140 
							
						 
						
							2007-03-18 09:02:31 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								1003dc72b4 
								
							 
						 
						
							
							
								
								rename DenseMap to IndexedMap.  
							
							 
							
							... 
							
							
							
							llvm-svn: 33749 
							
						 
						
							2007-02-01 05:32:05 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								aee775a6b7 
								
							 
						 
						
							
							
								
								Eliminate static ctors from Statistics  
							
							 
							
							... 
							
							
							
							llvm-svn: 32698 
							
						 
						
							2006-12-19 22:41:21 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								700b873130 
								
							 
						 
						
							
							
								
								Detemplatize the Statistic class.  The only type it is instantiated with  
							
							 
							
							... 
							
							
							
							is 'unsigned'.
llvm-svn: 32279 
							
						 
						
							2006-12-06 17:46:33 +00:00  
						
					 
				
					
						
							
							
								 
								Bill Wendling
							
						 
						
							 
							
							
							
							
								
							
							
								5d409822d6 
								
							 
						 
						
							
							
								
								"Once more into the breach, dear friends, once more, or fill the wall up  
							
							 
							
							... 
							
							
							
							with our English dead."
No! Really! Serious this time...It was how the vreg uses were being
adjusted that was causing hte Olden tests to fail. I corrected this and
the Olden and Regression tests all passed.
llvm-svn: 30644 
							
						 
						
							2006-09-28 07:10:24 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								764caf6129 
								
							 
						 
						
							
							
								
								re-re-revert this, back to the right revision.  It currently breaks bisort/mst  
							
							 
							
							... 
							
							
							
							in olden among others.
llvm-svn: 30637 
							
						 
						
							2006-09-28 00:11:54 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								9f7d0d1dc5 
								
							 
						 
						
							
							
								
								re-revert this patch, bisort and mst are still broken in Olden.  
							
							 
							
							... 
							
							
							
							llvm-svn: 30634 
							
						 
						
							2006-09-28 00:04:21 +00:00  
						
					 
				
					
						
							
							
								 
								Bill Wendling
							
						 
						
							 
							
							
							
							
								
							
							
								1f29e6c5c5 
								
							 
						 
						
							
							
								
								Reapplying this patch. With the newest commits, the error in Olden/bisort  
							
							 
							
							... 
							
							
							
							has disappeared.
llvm-svn: 30633 
							
						 
						
							2006-09-27 22:37:35 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								5f6c93701b 
								
							 
						 
						
							
							
								
								Temporarily revert this.  This breaks Olden/bisort on PPC  
							
							 
							
							... 
							
							
							
							llvm-svn: 30628 
							
						 
						
							2006-09-27 16:59:16 +00:00  
						
					 
				
					
						
							
							
								 
								Bill Wendling
							
						 
						
							 
							
							
							
							
								
							
							
								0a7f617a6c 
								
							 
						 
						
							
							
								
								PR878: Instead of calculating the vreg to PHI use count everytime we get  
							
							 
							
							... 
							
							
							
							a function, do it up front in linear time (going through all of the
instructions once). We create a map out of them. Then it's no problem to
use the information in it during elimination...
llvm-svn: 30624 
							
						 
						
							2006-09-27 09:04:15 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								3d27be1333 
								
							 
						 
						
							
							
								
								s|llvm/Support/Visibility.h|llvm/Support/Compiler.h|  
							
							 
							
							... 
							
							
							
							llvm-svn: 29911 
							
						 
						
							2006-08-27 12:54:02 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								167ea3eb5f 
								
							 
						 
						
							
							
								
								Fix an obvious bug, noticed by inspection.  No current targets trigger this.  
							
							 
							
							... 
							
							
							
							llvm-svn: 29648 
							
						 
						
							2006-08-12 05:41:39 +00:00  
						
					 
				
					
						
							
							
								 
								Andrew Lenharth
							
						 
						
							 
							
							
							
							
								
							
							
								c496b418b5 
								
							 
						 
						
							
							
								
								Reduce number of exported symbols  
							
							 
							
							... 
							
							
							
							llvm-svn: 29220 
							
						 
						
							2006-07-20 17:28:38 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								996795b0dd 
								
							 
						 
						
							
							
								
								Use hidden visibility to make symbols in an anonymous namespace get  
							
							 
							
							... 
							
							
							
							dropped.  This shrinks libllvmgcc.dylib another 67K
llvm-svn: 28975 
							
						 
						
							2006-06-28 23:17:24 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								227e936650 
								
							 
						 
						
							
							
								
								Add support for targets (like Alpha) that have terminator instructions which  
							
							 
							
							... 
							
							
							
							use virtual registers.  We now allow the first instruction in a block of
terminators to use virtual registers, and update phi elimination to correctly
update livevar when eliminating phi's.  This fixes a problem on a testcase
Andrew sent me.
llvm-svn: 25083 
							
						 
						
							2006-01-04 07:12:21 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								0511055276 
								
							 
						 
						
							
							
								
								Add an assertion, update DefInst even though no one uses it (dangling pointers  
							
							 
							
							... 
							
							
							
							don't help anyone)
llvm-svn: 25081 
							
						 
						
							2006-01-04 06:47:48 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								57b21f9f10 
								
							 
						 
						
							
							
								
								clean up this code a bit, no functionality change  
							
							 
							
							... 
							
							
							
							llvm-svn: 23609 
							
						 
						
							2005-10-03 07:22:07 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								5f096e2847 
								
							 
						 
						
							
							
								
								Break the body of the loop out into a new method  
							
							 
							
							... 
							
							
							
							llvm-svn: 23606 
							
						 
						
							2005-10-03 04:47:08 +00:00  
						
					 
				
					
						
							
							
								 
								Chris Lattner
							
						 
						
							 
							
							
							
							
								
							
							
								469652752c 
								
							 
						 
						
							
							
								
								adjust to new live variables interface  
							
							 
							
							... 
							
							
							
							llvm-svn: 22992 
							
						 
						
							2005-08-23 23:42:17 +00:00  
						
					 
				
					
						
							
							
								 
								Misha Brukman
							
						 
						
							 
							
							
							
							
								
							
							
								584ed83d4a 
								
							 
						 
						
							
							
								
								* Order #includes alphabetically  
							
							 
							
							... 
							
							
							
							* Remove commented-out debug printouts
llvm-svn: 21707 
							
						 
						
							2005-05-05 23:45:17 +00:00  
						
					 
				
					
						
							
							
								 
								Misha Brukman
							
						 
						
							 
							
							
							
							
								
							
							
								774511633d 
								
							 
						 
						
							
							
								
								Convert tabs to spaces  
							
							 
							
							... 
							
							
							
							llvm-svn: 21439 
							
						 
						
							2005-04-22 04:01:18 +00:00  
						
					 
				
					
						
							
							
								 
								Misha Brukman
							
						 
						
							 
							
							
							
							
								
							
							
								835702a094 
								
							 
						 
						
							
							
								
								Remove trailing whitespace  
							
							 
							
							... 
							
							
							
							llvm-svn: 21420 
							
						 
						
							2005-04-21 22:36:52 +00:00