48f8222293 
								
							 
						 
						
							
							
								
								Re-apply 70645, converting ScalarEvolution to use  
							
							... 
							
							
							
							CallbackVH, with fixes. allUsesReplacedWith need to
walk the def-use chains and invalidate all users of a
value that is replaced. SCEVs of users need to be
recalcualted even if the new value is equivalent. Also,
make forgetLoopPHIs walk def-use chains, since any
SCEV that depends on a PHI should be recalculated when
more information about that PHI becomes available.
llvm-svn: 70927 
							
						 
						
							2009-05-04 22:30:44 +00:00  
				
					
						
							
							
								 
						
							
								351134ba93 
								
							 
						 
						
							
							
								
								Factor loop backedge finding out of CodeGenPrepare into a new  
							
							... 
							
							
							
							FindFunctionBackedges function.
llvm-svn: 70819 
							
						 
						
							2009-05-04 02:25:58 +00:00  
				
					
						
							
							
								 
						
							
								5036695c32 
								
							 
						 
						
							
							
								
								Revert r70645 for now; it's causing a variety of regressions.  
							
							... 
							
							
							
							llvm-svn: 70661 
							
						 
						
							2009-05-03 05:46:20 +00:00  
				
					
						
							
							
								 
						
							
								e9a38d16fe 
								
							 
						 
						
							
							
								
								Convert ScalarEvolution to use CallbackVH for its internal map. This  
							
							... 
							
							
							
							makes ScalarEvolution::deleteValueFromRecords, and it's code that
subtly needed to be called before ReplaceAllUsesWith, unnecessary.
It also makes ValueDeletionListener unnecessary.
llvm-svn: 70645 
							
						 
						
							2009-05-02 21:19:20 +00:00  
				
					
						
							
							
								 
						
							
								ff08995589 
								
							 
						 
						
							
							
								
								Previously, RecursivelyDeleteDeadInstructions provided an option  
							
							... 
							
							
							
							of returning a list of pointers to Values that are deleted. This was
unsafe, because the pointers in the list are, by nature of what
RecursivelyDeleteDeadInstructions does, always dangling. Replace this
with a simple callback mechanism. This may eventually be removed if
all clients can reasonably be expected to use CallbackVH.
Use this to factor out the dead-phi-cycle-elimination code from LSR
utility function, and generalize it to use the
RecursivelyDeleteTriviallyDeadInstructions utility function.
This makes LSR more aggressive about eliminating dead PHI cycles;
adjust tests to either be less trivial or to simply expect fewer
instructions.
llvm-svn: 70636 
							
						 
						
							2009-05-02 18:29:22 +00:00  
				
					
						
							
							
								 
						
							
								d71c20081c 
								
							 
						 
						
							
							
								
								Skip ptr-to-ptr bitcasts when counting in another case.  
							
							... 
							
							
							
							llvm-svn: 66000 
							
						 
						
							2009-03-04 02:06:53 +00:00  
				
					
						
							
							
								 
						
							
								09c3e8ec00 
								
							 
						 
						
							
							
								
								Instruction counters must skip the bitcasts that  
							
							... 
							
							
							
							feed into llvm.dbg.declare nodes, as well as
the debug directives themselves.
llvm-svn: 65976 
							
						 
						
							2009-03-03 22:36:47 +00:00  
				
					
						
							
							
								 
						
							
								77456b7ab4 
								
							 
						 
						
							
							
								
								When removing a store to an alloca that has only one  
							
							... 
							
							
							
							use, check also for the case where it has two uses,
the other being a llvm.dbg.declare.  This is needed so
debug info doesn't affect codegen.
llvm-svn: 65970 
							
						 
						
							2009-03-03 21:26:39 +00:00  
				
					
						
							
							
								 
						
							
								92b551bc2b 
								
							 
						 
						
							
							
								
								Fix a bunch of Doxygen syntax issues. Escape special characters,  
							
							... 
							
							
							
							and put @file  directives on their own comment line.
llvm-svn: 65920 
							
						 
						
							2009-03-03 02:55:14 +00:00  
				
					
						
							
							
								 
						
							
								e1bb2f86f9 
								
							 
						 
						
							
							
								
								When sinking an insn in InstCombine bring its debug  
							
							... 
							
							
							
							info with it.
Don't count debug info insns against the scan maximum
in FindAvailableLoadedValue (lest they affect codegen).
llvm-svn: 65910 
							
						 
						
							2009-03-03 01:09:07 +00:00  
				
					
						
							
							
								 
						
							
								e288082644 
								
							 
						 
						
							
							
								
								While folding unconditional return move DbgRegionEndInst into the predecessor, instead of removing it. This fixes following tests from llvmgcc42 testsuite.  
							
							... 
							
							
							
							gcc.c-torture/execute/20000605-3.c
gcc.c-torture/execute/20020619-1.c
gcc.c-torture/execute/20030920-1.c
gcc.c-torture/execute/loop-ivopts-1.c
llvm-svn: 65353 
							
						 
						
							2009-02-24 00:05:16 +00:00  
				
					
						
							
							
								 
						
							
								316705027b 
								
							 
						 
						
							
							
								
								If llvm.dbg.region.end is disappearing then remove corresponding llvm.dbg.func.start also.  
							
							... 
							
							
							
							llvm-svn: 64278 
							
						 
						
							2009-02-11 01:29:06 +00:00  
				
					
						
							
							
								 
						
							
								5a913d61e3 
								
							 
						 
						
							
							
								
								Rename getAnalysisToUpdate to getAnalysisIfAvailable.  
							
							... 
							
							
							
							llvm-svn: 63198 
							
						 
						
							2009-01-28 13:14:17 +00:00  
				
					
						
							
							
								 
						
							
								dc3f6f2c12 
								
							 
						 
						
							
							
								
								Factor some code into a new FoldSingleEntryPHINodes method.  
							
							... 
							
							
							
							llvm-svn: 60501 
							
						 
						
							2008-12-03 19:44:02 +00:00  
				
					
						
							
							
								 
						
							
								37e0136fef 
								
							 
						 
						
							
							
								
								third time is the charm.  
							
							... 
							
							
							
							llvm-svn: 60469 
							
						 
						
							2008-12-03 07:45:15 +00:00  
				
					
						
							
							
								 
						
							
								c04a1ffa9a 
								
							 
						 
						
							
							
								
								fix assertion.  
							
							... 
							
							
							
							llvm-svn: 60468 
							
						 
						
							2008-12-03 07:43:05 +00:00  
				
					
						
							
							
								 
						
							
								7eb270ed03 
								
							 
						 
						
							
							
								
								Rename DeleteBlockIfDead to DeleteDeadBlock and make it  
							
							... 
							
							
							
							unconditionally delete the block.  All likely clients will
do the checking anyway.
llvm-svn: 60464 
							
						 
						
							2008-12-03 06:40:52 +00:00  
				
					
						
							
							
								 
						
							
								bcc904a67c 
								
							 
						 
						
							
							
								
								Factor some code out of SimplifyCFG, forming a new  
							
							... 
							
							
							
							DeleteBlockIfDead method.
llvm-svn: 60463 
							
						 
						
							2008-12-03 06:37:44 +00:00  
				
					
						
							
							
								 
						
							
								e0d019def6 
								
							 
						 
						
							
							
								
								switch InstCombine::visitLoadInst to use  
							
							... 
							
							
							
							FindAvailableLoadedValue
llvm-svn: 60169 
							
						 
						
							2008-11-27 08:56:30 +00:00  
				
					
						
							
							
								 
						
							
								c6ae56d23f 
								
							 
						 
						
							
							
								
								enhance FindAvailableLoadedValue to make use of AliasAnalysis  
							
							... 
							
							
							
							if it has it.
llvm-svn: 60167 
							
						 
						
							2008-11-27 08:18:12 +00:00  
				
					
						
							
							
								 
						
							
								72f16e70f0 
								
							 
						 
						
							
							
								
								move FindAvailableLoadedValue from JumpThreading to Transforms/Utils.  
							
							... 
							
							
							
							llvm-svn: 60166 
							
						 
						
							2008-11-27 08:10:05 +00:00  
				
					
						
							
							
								 
						
							
								f33f8a8606 
								
							 
						 
						
							
							
								
								Fix unused variable warnings.  
							
							... 
							
							
							
							llvm-svn: 58651 
							
						 
						
							2008-11-03 23:14:09 +00:00  
				
					
						
							
							
								 
						
							
								cb4f156b6b 
								
							 
						 
						
							
							
								
								SplitBlock should only attempt to update LoopInfo if it is actually being used.  
							
							... 
							
							
							
							llvm-svn: 56994 
							
						 
						
							2008-10-03 06:55:35 +00:00  
				
					
						
							
							
								 
						
							
								0f7a3507cf 
								
							 
						 
						
							
							
								
								Fix simplifycfg crash in handing block merge.  
							
							... 
							
							
							
							llvm-svn: 55971 
							
						 
						
							2008-09-09 01:06:56 +00:00  
				
					
						
							
							
								 
						
							
								1468bec06e 
								
							 
						 
						
							
							
								
								Add some checks that got lost in the shuffle.  This fixes 464.h264ref.  
							
							... 
							
							
							
							llvm-svn: 53760 
							
						 
						
							2008-07-18 17:46:41 +00:00  
				
					
						
							
							
								 
						
							
								27405efdc0 
								
							 
						 
						
							
							
								
								Make MergeBlockIntoPredecessor more aggressive when the same successor appears  
							
							... 
							
							
							
							more than once.
llvm-svn: 53731 
							
						 
						
							2008-07-17 19:42:29 +00:00  
				
					
						
							
							
								 
						
							
								c062381c7b 
								
							 
						 
						
							
							
								
								Factor MergeBlockIntoPredecessor out into BasicBlockUtils.  
							
							... 
							
							
							
							llvm-svn: 53705 
							
						 
						
							2008-07-17 00:01:40 +00:00  
				
					
						
							
							
								 
						
							
								4d43d3c72c 
								
							 
						 
						
							
							
								
								Remove 'unwinds to' support from mainline. This patch undoes r47802 r47989  
							
							... 
							
							
							
							r48047 r48084 r48085 r48086 r48088 r48096 r48099 r48109 and r48123.
llvm-svn: 50265 
							
						 
						
							2008-04-25 16:53:59 +00:00  
				
					
						
							
							
								 
						
							
								a5b11705b6 
								
							 
						 
						
							
							
								
								Move SplitBlockPredecessors out of loopsimplify into BasicBlockUtils.h  
							
							... 
							
							
							
							as a global helper function.  At the same type, switch it from taking
a vector of predecessors to an arbitrary sequential input.  This allows
us to switch LoopSimplify to use a SmallVector for various temporary
vectors that it passed into SplitBlockPredecessors.
llvm-svn: 50020 
							
						 
						
							2008-04-21 01:28:02 +00:00  
				
					
						
							
							
								 
						
							
								e9ecc68d8f 
								
							 
						 
						
							
							
								
								API changes for class Use size reduction, wave 1.  
							
							... 
							
							
							
							Specifically, introduction of XXX::Create methods
for Users that have a potentially variable number of
Uses.
llvm-svn: 49277 
							
						 
						
							2008-04-06 20:25:17 +00:00  
				
					
						
							
							
								 
						
							
								cc24104703 
								
							 
						 
						
							
							
								
								Two things. Preserve the unwind_to when splitting a BB.  
							
							... 
							
							
							
							Add the ability to remove just one instance of a BB from a phi node. This fixes
the compile error in the tree now.
llvm-svn: 48085 
							
						 
						
							2008-03-09 05:04:48 +00:00  
				
					
						
							
							
								 
						
							
								f3ebc3f3d2 
								
							 
						 
						
							
							
								
								Remove attribution from file headers, per discussion on llvmdev.  
							
							... 
							
							
							
							llvm-svn: 45418 
							
						 
						
							2007-12-29 20:36:04 +00:00  
				
					
						
							
							
								 
						
							
								b0dd27ee91 
								
							 
						 
						
							
							
								
								Make LoopInfoBase more generic, in preparation for having MachineLoopInfo.  This involves a small interface change.  
							
							... 
							
							
							
							llvm-svn: 44348 
							
						 
						
							2007-11-27 03:43:35 +00:00  
				
					
						
							
							
								 
						
							
								186e0d8b0a 
								
							 
						 
						
							
							
								
								After a basic block is split into two parts,  
							
							... 
							
							
							
							second part dominates all the blocks dominated
by original basic block. And first part dominates
second part.
llvm-svn: 40035 
							
						 
						
							2007-07-19 02:29:24 +00:00  
				
					
						
							
							
								 
						
							
								d7767cc2a7 
								
							 
						 
						
							
							
								
								Add SplitEdge and SplitBlock utility routines.  
							
							... 
							
							
							
							llvm-svn: 37952 
							
						 
						
							2007-07-06 21:39:20 +00:00  
				
					
						
							
							
								 
						
							
								8dd4cae4f8 
								
							 
						 
						
							
							
								
								simplify code by using Value::takeName  
							
							... 
							
							
							
							llvm-svn: 34177 
							
						 
						
							2007-02-11 01:37:51 +00:00  
				
					
						
							
							
								 
						
							
								2452c94df4 
								
							 
						 
						
							
							
								
								Fix a doxygen problem and break lines at 80 columns  
							
							... 
							
							
							
							llvm-svn: 28395 
							
						 
						
							2006-05-19 19:09:46 +00:00  
				
					
						
							
							
								 
						
							
								b1c9317bb4 
								
							 
						 
						
							
							
								
								Remove trailing whitespace  
							
							... 
							
							
							
							llvm-svn: 21427 
							
						 
						
							2005-04-21 23:48:37 +00:00  
				
					
						
							
							
								 
						
							
								7ceb081f3f 
								
							 
						 
						
							
							
								
								Improve doxygen documentation, patch contributed by Evan Jones!  
							
							... 
							
							
							
							llvm-svn: 21393 
							
						 
						
							2005-04-21 16:04:49 +00:00  
				
					
						
							
							
								 
						
							
								6d0a24c608 
								
							 
						 
						
							
							
								
								second argument to Value::setName is now gone.  
							
							... 
							
							
							
							llvm-svn: 20463 
							
						 
						
							2005-03-05 19:05:20 +00:00  
				
					
						
							
							
								 
						
							
								63b38bd2ed 
								
							 
						 
						
							
							
								
								Fix #includes of i*.h => Instructions.h as per PR403.  
							
							... 
							
							
							
							llvm-svn: 15334 
							
						 
						
							2004-07-29 17:30:56 +00:00  
				
					
						
							
							
								 
						
							
								df3c342a4c 
								
							 
						 
						
							
							
								
								Finegrainify namespacification  
							
							... 
							
							
							
							llvm-svn: 10727 
							
						 
						
							2004-01-09 06:12:26 +00:00  
				
					
						
							
							
								 
						
							
								960707c335 
								
							 
						 
						
							
							
								
								Put all LLVM code into the llvm namespace, as per bug 109.  
							
							... 
							
							
							
							llvm-svn: 9903 
							
						 
						
							2003-11-11 22:41:34 +00:00  
				
					
						
							
							
								 
						
							
								482202a601 
								
							 
						 
						
							
							
								
								Added LLVM project notice to the top of every C++ source file.  
							
							... 
							
							
							
							Header files will be on the way.
llvm-svn: 9298 
							
						 
						
							2003-10-20 19:43:21 +00:00  
				
					
						
							
							
								 
						
							
								8b2bd4ed47 
								
							 
						 
						
							
							
								
								Fix spelling.  
							
							... 
							
							
							
							llvm-svn: 9027 
							
						 
						
							2003-10-10 17:57:28 +00:00  
				
					
						
							
							
								 
						
							
								7eb05a170a 
								
							 
						 
						
							
							
								
								Spell `necessary' correctly.  
							
							... 
							
							
							
							llvm-svn: 7944 
							
						 
						
							2003-08-18 14:43:39 +00:00  
				
					
						
							
							
								 
						
							
								98cf1f5d64 
								
							 
						 
						
							
							
								
								- Eliminated the deferred symbol table stuff in Module & Function, it really  
							
							... 
							
							
							
							wasn't an optimization and it was causing lots of bugs.
llvm-svn: 4779 
							
						 
						
							2002-11-20 18:36:02 +00:00  
				
					
						
							
							
								 
						
							
								632df28deb 
								
							 
						 
						
							
							
								
								Fix spelling of `propagate'.  
							
							... 
							
							
							
							llvm-svn: 4423 
							
						 
						
							2002-10-29 23:06:16 +00:00  
				
					
						
							
							
								 
						
							
								b17274ebf6 
								
							 
						 
						
							
							
								
								Implement a new RemoveSuccessor function  
							
							... 
							
							
							
							llvm-svn: 3131 
							
						 
						
							2002-07-29 22:32:08 +00:00  
				
					
						
							
							
								 
						
							
								fda72b1aad 
								
							 
						 
						
							
							
								
								*** empty log message ***  
							
							... 
							
							
							
							llvm-svn: 2777 
							
						 
						
							2002-06-25 16:12:52 +00:00