6c18d1aac0 
								
							 
						 
						
							
							
								
								Get rid of static constructors for pass registration.  Instead, every pass exposes an initializeMyPassFunction(), which  
							
							... 
							
							
							
							must be called in the pass's constructor.  This function uses static dependency declarations to recursively initialize
the pass's dependencies.
Clients that only create passes through the createFooPass() APIs will require no changes.  Clients that want to use the
CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h
before parsing commandline arguments.
I have tested this with all standard configurations of clang and llvm-gcc on Darwin.  It is possible that there are problems
with the static dependencies that will only be visible with non-standard options.  If you encounter any crash in pass
registration/creation, please send the testcase to me directly.
llvm-svn: 116820 
							
						 
						
							2010-10-19 17:21:58 +00:00  
				
					
						
							
							
								 
						
							
								df7a4f2515 
								
							 
						 
						
							
							
								
								Now with fewer extraneous semicolons!  
							
							... 
							
							
							
							llvm-svn: 115996 
							
						 
						
							2010-10-07 22:25:06 +00:00  
				
					
						
							
							
								 
						
							
								a7aed18624 
								
							 
						 
						
							
							
								
								Reapply r110396, with fixes to appease the Linux buildbot gods.  
							
							... 
							
							
							
							llvm-svn: 110460 
							
						 
						
							2010-08-06 18:33:48 +00:00  
				
					
						
							
							
								 
						
							
								bda59bd247 
								
							 
						 
						
							
							
								
								Revert r110396 to fix buildbots.  
							
							... 
							
							
							
							llvm-svn: 110410 
							
						 
						
							2010-08-06 00:23:35 +00:00  
				
					
						
							
							
								 
						
							
								755aceb5d0 
								
							 
						 
						
							
							
								
								Don't use PassInfo* as a type identifier for passes.  Instead, use the address of the static  
							
							... 
							
							
							
							ID member as the sole unique type identifier.  Clean up APIs related to this change.
llvm-svn: 110396 
							
						 
						
							2010-08-05 23:42:04 +00:00  
				
					
						
							
							
								 
						
							
								a57b97e7e7 
								
							 
						 
						
							
							
								
								Fix batch of converting RegisterPass<> to INTIALIZE_PASS().  
							
							... 
							
							
							
							llvm-svn: 109045 
							
						 
						
							2010-07-21 22:09:45 +00:00  
				
					
						
							
							
								 
						
							
								b5d9c8c708 
								
							 
						 
						
							
							
								
								cleanups, switch GlobalDCE to SmallPtrSet instead of std::set  
							
							... 
							
							
							
							llvm-svn: 85730 
							
						 
						
							2009-11-01 19:03:42 +00:00  
				
					
						
							
							
								 
						
							
								ee8b951e73 
								
							 
						 
						
							
							
								
								teach various passes about blockaddress.  We no longer  
							
							... 
							
							
							
							crash on any clang tests.
llvm-svn: 85465 
							
						 
						
							2009-10-29 01:21:20 +00:00  
				
					
						
							
							
								 
						
							
								974e12b2d3 
								
							 
						 
						
							
							
								
								Remove includes of Support/Compiler.h that are no longer needed after the  
							
							... 
							
							
							
							VISIBILITY_HIDDEN removal.
llvm-svn: 85043 
							
						 
						
							2009-10-25 06:57:41 +00:00  
				
					
						
							
							
								 
						
							
								02d5f77d26 
								
							 
						 
						
							
							
								
								Remove VISIBILITY_HIDDEN from class/struct found inside anonymous namespaces.  
							
							... 
							
							
							
							Chris claims we should never have visibility_hidden inside any .cpp file but
that's still not true even after this commit.
llvm-svn: 85042 
							
						 
						
							2009-10-25 06:33:48 +00:00  
				
					
						
							
							
								 
						
							
								27e0be274e 
								
							 
						 
						
							
							
								
								Derive metadata hierarchy from Value instead of User.  
							
							... 
							
							
							
							llvm-svn: 84801 
							
						 
						
							2009-10-21 23:57:35 +00:00  
				
					
						
							
							
								 
						
							
								1d7f7d21dc 
								
							 
						 
						
							
							
								
								Do not remove dead metadata for now.  
							
							... 
							
							
							
							llvm-svn: 84731 
							
						 
						
							2009-10-21 02:21:34 +00:00  
				
					
						
							
							
								 
						
							
								c5aa8c6d29 
								
							 
						 
						
							
							
								
								Remove dead metadata.  
							
							... 
							
							
							
							llvm-svn: 78651 
							
						 
						
							2009-08-11 06:31:57 +00:00  
				
					
						
							
							
								 
						
							
								47db941fd3 
								
							 
						 
						
							
							
								
								Get rid of the Pass+Context magic.  
							
							... 
							
							
							
							llvm-svn: 76702 
							
						 
						
							2009-07-22 00:24:57 +00:00  
				
					
						
							
							
								 
						
							
								20b34ac794 
								
							 
						 
						
							
							
								
								Move the ConstantInt uniquing table into LLVMContextImpl.  This exposed a number of issues in  
							
							... 
							
							
							
							our current context-passing stuff, which is also fixed here
llvm-svn: 76089 
							
						 
						
							2009-07-16 18:04:31 +00:00  
				
					
						
							
							
								 
						
							
								edea37d801 
								
							 
						 
						
							
							
								
								Remove an unused function SafeToDestroyConstant(). Rename an almost  
							
							... 
							
							
							
							identical function ConstantIsDead() to SafeToDestroyConstant(), to
emphasise the connection with Constant::destroyConstant().
llvm-svn: 73149 
							
						 
						
							2009-06-09 21:37:11 +00:00  
				
					
						
							
							
								 
						
							
								7996339dd8 
								
							 
						 
						
							
							
								
								available_externall linkage is not local, this was confusing the codegenerator,  
							
							... 
							
							
							
							and it wasn't generating calls through @PLT for these functions.
hasLocalLinkage() is now false for available_externally,
I attempted to fix the inliner and dce to handle available_externally properly.
It passed make check.
llvm-svn: 72328 
							
						 
						
							2009-05-23 14:06:57 +00:00  
				
					
						
							
							
								 
						
							
								836e77d161 
								
							 
						 
						
							
							
								
								eliminate unneeded parens.  
							
							... 
							
							
							
							llvm-svn: 68939 
							
						 
						
							2009-04-13 05:38:23 +00:00  
				
					
						
							
							
								 
						
							
								bf3ba5a1e9 
								
							 
						 
						
							
							
								
								If an alias is dead and so is its aliasee, then globaldce would  
							
							... 
							
							
							
							crash because the alias would still be using the aliasee when the
aliasee was deleted.
llvm-svn: 64844 
							
						 
						
							2009-02-17 23:05:26 +00:00  
				
					
						
							
							
								 
						
							
								6de96a1b5d 
								
							 
						 
						
							
							
								
								Add the private linkage.  
							
							... 
							
							
							
							llvm-svn: 62279 
							
						 
						
							2009-01-15 20:18:42 +00:00  
				
					
						
							
							
								 
						
							
								187c5716b6 
								
							 
						 
						
							
							
								
								The verifier checks that the aliasee is not null.  
							
							... 
							
							
							
							llvm-svn: 61870 
							
						 
						
							2009-01-07 18:45:53 +00:00  
				
					
						
							
							
								 
						
							
								52e5deece5 
								
							 
						 
						
							
							
								
								Not having an aliasee is a theoretical possibility.  
							
							... 
							
							
							
							llvm-svn: 61745 
							
						 
						
							2009-01-05 20:47:56 +00:00  
				
					
						
							
							
								 
						
							
								821d13cf78 
								
							 
						 
						
							
							
								
								Format more neatly.  
							
							... 
							
							
							
							llvm-svn: 61744 
							
						 
						
							2009-01-05 20:39:50 +00:00  
				
					
						
							
							
								 
						
							
								f5dbbae4f4 
								
							 
						 
						
							
							
								
								Delete unused global aliases with internal linkage.  
							
							... 
							
							
							
							In fact this also deletes those with linkonce linkage,
however this is currently dead because for the moment
aliases aren't allowed to have this linkage type.
llvm-svn: 61742 
							
						 
						
							2009-01-05 20:37:33 +00:00  
				
					
						
							
							
								 
						
							
								95b18126ee 
								
							 
						 
						
							
							
								
								Use actual function name in comments.  
							
							... 
							
							
							
							llvm-svn: 59063 
							
						 
						
							2008-11-11 19:16:41 +00:00  
				
					
						
							
							
								 
						
							
								a79db30d28 
								
							 
						 
						
							
							
								
								Tidy up several unbeseeming casts from pointer to intptr_t.  
							
							... 
							
							
							
							llvm-svn: 55779 
							
						 
						
							2008-09-04 17:05:41 +00:00  
				
					
						
							
							
								 
						
							
								3707f1daba 
								
							 
						 
						
							
							
								
								Use find instead of lower_bound.  
							
							... 
							
							
							
							llvm-svn: 53474 
							
						 
						
							2008-07-11 20:58:19 +00:00  
				
					
						
							
							
								 
						
							
								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  
				
					
						
							
							
								 
						
							
								f3ebc3f3d2 
								
							 
						 
						
							
							
								
								Remove attribution from file headers, per discussion on llvmdev.  
							
							... 
							
							
							
							llvm-svn: 45418 
							
						 
						
							2007-12-29 20:36:04 +00:00  
				
					
						
							
							
								 
						
							
								e7da2d6ac3 
								
							 
						 
						
							
							
								
								Fix typo in comment.  
							
							... 
							
							
							
							llvm-svn: 36873 
							
						 
						
							2007-05-06 13:37:16 +00:00  
				
					
						
							
							
								 
						
							
								8c78a0bff0 
								
							 
						 
						
							
							
								
								Drop 'const'  
							
							... 
							
							
							
							llvm-svn: 36662 
							
						 
						
							2007-05-03 01:11:54 +00:00  
				
					
						
							
							
								 
						
							
								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  
				
					
						
							
							
								 
						
							
								09f162ca6a 
								
							 
						 
						
							
							
								
								Do not use typeinfo to identify pass in pass manager.  
							
							... 
							
							
							
							llvm-svn: 36632 
							
						 
						
							2007-05-01 21:15:47 +00:00  
				
					
						
							
							
								 
						
							
								546ea7ea88 
								
							 
						 
						
							
							
								
								Implement review feedback  
							
							... 
							
							
							
							llvm-svn: 36564 
							
						 
						
							2007-04-29 18:02:48 +00:00  
				
					
						
							
							
								 
						
							
								b18f8f85e9 
								
							 
						 
						
							
							
								
								Implement review feedback. Aliasees can be either GlobalValue's or  
							
							... 
							
							
							
							bitcasts of them.
llvm-svn: 36537 
							
						 
						
							2007-04-28 13:45:00 +00:00  
				
					
						
							
							
								 
						
							
								a97b694c82 
								
							 
						 
						
							
							
								
								Implement aliases. This fixes PR1017 and it's dependent bugs. CFE part  
							
							... 
							
							
							
							will follow.
llvm-svn: 36435 
							
						 
						
							2007-04-25 14:27:10 +00:00  
				
					
						
							
							
								 
						
							
								557ab15e71 
								
							 
						 
						
							
							
								
								Apply the VISIBILITY_HIDDEN field to the remaining anonymous classes in  
							
							... 
							
							
							
							the Transforms library. This reduces debug library size by 132 KB, debug
binary size by 376 KB, and reduces link time for llvm tools slightly.
llvm-svn: 33939 
							
						 
						
							2007-02-05 23:32:05 +00:00  
				
					
						
							
							
								 
						
							
								5301e7c605 
								
							 
						 
						
							
							
								
								For PR1136: Rename GlobalVariable::isExternal as isDeclaration to avoid  
							
							... 
							
							
							
							confusion with external linkage types.
llvm-svn: 33663 
							
						 
						
							2007-01-30 20:08:39 +00:00  
				
					
						
							
							
								 
						
							
								1631bcb1d4 
								
							 
						 
						
							
							
								
								Eliminate static ctors due to Statistic objects  
							
							... 
							
							
							
							llvm-svn: 32693 
							
						 
						
							2006-12-19 22:09:18 +00:00  
				
					
						
							
							
								 
						
							
								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  
				
					
						
							
							
								 
						
							
								c2d3d3112e 
								
							 
						 
						
							
							
								
								eliminate RegisterOpt.  It does the same thing as RegisterPass.  
							
							... 
							
							
							
							llvm-svn: 29925 
							
						 
						
							2006-08-27 22:42:52 +00:00  
				
					
						
							
							
								 
						
							
								b1c9317bb4 
								
							 
						 
						
							
							
								
								Remove trailing whitespace  
							
							... 
							
							
							
							llvm-svn: 21427 
							
						 
						
							2005-04-21 23:48:37 +00:00  
				
					
						
							
							
								 
						
							
								531f9e92d4 
								
							 
						 
						
							
							
								
								This mega patch converts us from using Function::a{iterator|begin|end} to  
							
							... 
							
							
							
							using Function::arg_{iterator|begin|end}.  Likewise Module::g* -> Module::global_*.
This patch is contributed by Gabor Greif, thanks!
llvm-svn: 20597 
							
						 
						
							2005-03-15 04:54:21 +00:00  
				
					
						
							
							
								 
						
							
								4f2cf030e8 
								
							 
						 
						
							
							
								
								'Pass' should now not be derived from by clients.  Instead, they should derive  
							
							... 
							
							
							
							from ModulePass.  Instead of implementing Pass::run, then should implement
ModulePass::runOnModule.
llvm-svn: 16436 
							
						 
						
							2004-09-20 04:48:05 +00:00  
				
					
						
							
							
								 
						
							
								7c16caa336 
								
							 
						 
						
							
							
								
								Changes For Bug 352  
							
							... 
							
							
							
							Move include/Config and include/Support into include/llvm/Config,
include/llvm/ADT and include/llvm/Support. From here on out, all LLVM
public header files must be under include/llvm/.
llvm-svn: 16137 
							
						 
						
							2004-09-01 22:55:40 +00:00  
				
					
						
							
							
								 
						
							
								9238d78dc3 
								
							 
						 
						
							
							
								
								Remove useless statistic, fix some slightly broken logic  
							
							... 
							
							
							
							llvm-svn: 14958 
							
						 
						
							2004-07-18 07:22:58 +00:00  
				
					
						
							
							
								 
						
							
								5f6815980b 
								
							 
						 
						
							
							
								
								bug 122:  
							
							... 
							
							
							
							- Replace ConstantPointerRef usage with GlobalValue usage
- Rename methods to get ride of ConstantPointerRef usage
llvm-svn: 14945 
							
						 
						
							2004-07-18 00:25:04 +00:00  
				
					
						
							
							
								 
						
							
								f52e03c79e 
								
							 
						 
						
							
							
								
								Finegrainify namespacification  
							
							... 
							
							
							
							llvm-svn: 10138 
							
						 
						
							2003-11-21 21:54:22 +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