07bd69c446 
								
							 
						 
						
							
							
								
								bump pointer allocate LLVM IR types, since they are never deallocated.  
							
							... 
							
							
							
							llvm-svn: 135248 
							
						 
						
							2011-07-15 05:49:15 +00:00  
				
					
						
							
							
								 
						
							
								68ef694382 
								
							 
						 
						
							
							
								
								stop leaking all named struct types with an empty name.  Thanks  
							
							... 
							
							
							
							to Benjamin Kramer for steering me in the right direction here.
llvm-svn: 135031 
							
						 
						
							2011-07-13 04:22:39 +00:00  
				
					
						
							
							
								 
						
							
								e9bb9a0baa 
								
							 
						 
						
							
							
								
								TypeMap had a destructor that destroyed the types it held. DenseMap did not, so  
							
							... 
							
							
							
							destroy those types in ~LLVMContext.
llvm-svn: 134945 
							
						 
						
							2011-07-12 00:26:08 +00:00  
				
					
						
							
							
								 
						
							
								b1ed91f397 
								
							 
						 
						
							
							
								
								Land the long talked about "type system rewrite" patch.  This  
							
							... 
							
							
							
							patch brings numerous advantages to LLVM.  One way to look at it
is through diffstat:
 109 files changed, 3005 insertions(+), 5906 deletions(-)
Removing almost 3K lines of code is a good thing.  Other advantages
include:
1. Value::getType() is a simple load that can be CSE'd, not a mutating
   union-find operation.
2. Types a uniqued and never move once created, defining away PATypeHolder.
3. Structs can be "named" now, and their name is part of the identity that
   uniques them.  This means that the compiler doesn't merge them structurally
   which makes the IR much less confusing.
4. Now that there is no way to get a cycle in a type graph without a named
   struct type, "upreferences" go away.
5. Type refinement is completely gone, which should make LTO much MUCH faster
   in some common cases with C++ code.
6. Types are now generally immutable, so we can use "Type *" instead 
   "const Type *" everywhere.
Downsides of this patch are that it removes some functions from the C API,
so people using those will have to upgrade to (not yet added) new API.  
"LLVM 3.0" is the right time to do this.
There are still some cleanups pending after this, this patch is large enough
as-is.
llvm-svn: 134829 
							
						 
						
							2011-07-09 17:41:24 +00:00  
				
					
						
							
							
								 
						
							
								060d5ba248 
								
							 
						 
						
							
							
								
								More SmallVectorImpls.  
							
							... 
							
							
							
							llvm-svn: 116279 
							
						 
						
							2010-10-12 00:15:27 +00:00  
				
					
						
							
							
								 
						
							
								baa5d045c9 
								
							 
						 
						
							
							
								
								Add X86 MMX type to bitcode and Type.  
							
							... 
							
							
							
							(The Ada bindings probably need it too, but all the
obvious places to change say "do not edit this file".)
llvm-svn: 113618 
							
						 
						
							2010-09-10 20:55:01 +00:00  
				
					
						
							
							
								 
						
							
								8e89e41faf 
								
							 
						 
						
							
							
								
								Clarify the ownership model of LLVMContext and Module. Namely, contexts own  
							
							... 
							
							
							
							modules are instantiated in them.  If the context is deleted, all of its owned
modules are also deleted.
llvm-svn: 113374 
							
						 
						
							2010-09-08 18:03:32 +00:00  
				
					
						
							
							
								 
						
							
								13ee795c42 
								
							 
						 
						
							
							
								
								remove unions from LLVM IR.  They are severely buggy and not  
							
							... 
							
							
							
							being actively maintained, improved, or extended.
llvm-svn: 112356 
							
						 
						
							2010-08-28 04:09:24 +00:00  
				
					
						
							
							
								 
						
							
								b29cda9b3c 
								
							 
						 
						
							
							
								
								Fix a bunch of namespace polution.  
							
							... 
							
							
							
							llvm-svn: 101376 
							
						 
						
							2010-04-15 17:08:50 +00:00  
				
					
						
							
							
								 
						
							
								60955d42bd 
								
							 
						 
						
							
							
								
								give LLVMContext an inline asm diagnostic hook member.  
							
							... 
							
							
							
							llvm-svn: 100506 
							
						 
						
							2010-04-06 00:44:45 +00:00  
				
					
						
							
							
								 
						
							
								a6eedc3c03 
								
							 
						 
						
							
							
								
								Free all Constants in ~LLVMConstantImpl.  We avoid assertion failures  
							
							... 
							
							
							
							by dropping all references from all constants that can use other
constants before trying to destroy any of them.
I also had to free bugpoint's Module in ~BugDriver().
llvm-svn: 99160 
							
						 
						
							2010-03-22 05:23:37 +00:00  
				
					
						
							
							
								 
						
							
								cd3706cd1c 
								
							 
						 
						
							
							
								
								Re-add the Metadata.h include to LLVMContextImpl.h so that MDNode is complete  
							
							... 
							
							
							
							where FoldingSet<MDNode> is instantiated.  Clang and MSVC complain; gcc
doesn't.
llvm-svn: 99147 
							
						 
						
							2010-03-21 22:08:41 +00:00  
				
					
						
							
							
								 
						
							
								4cfb3a7656 
								
							 
						 
						
							
							
								
								Move the LLVMContextImpl implementation into a .cpp file.  
							
							... 
							
							
							
							llvm-svn: 99146 
							
						 
						
							2010-03-21 21:17:34 +00:00  
				
					
						
							
							
								 
						
							
								afd0c4cd56 
								
							 
						 
						
							
							
								
								Factor some of the constants+context related code out into a separate header, to make LLVMContextImpl.h  
							
							... 
							
							
							
							not hideous.  Also, fix some MSVC compile errors.
llvm-svn: 78115 
							
						 
						
							2009-08-04 22:41:48 +00:00  
				
					
						
							
							
								 
						
							
								1584a29536 
								
							 
						 
						
							
							
								
								Privatize the last bit of Constant-creation state.  
							
							... 
							
							
							
							llvm-svn: 78097 
							
						 
						
							2009-08-04 20:25:11 +00:00  
				
					
						
							
							
								 
						
							
								4bf58b8add 
								
							 
						 
						
							
							
								
								One two many newlines at end of file LLVMContextImpl.cpp  
							
							... 
							
							
							
							llvm-svn: 77911 
							
						 
						
							2009-08-02 20:06:26 +00:00  
				
					
						
							
							
								 
						
							
								2dd529c9ef 
								
							 
						 
						
							
							
								
								Fix no newline at end of LLVMContextImpl.cpp  
							
							... 
							
							
							
							llvm-svn: 77907 
							
						 
						
							2009-08-02 19:38:12 +00:00  
				
					
						
							
							
								 
						
							
								0087fe6e5c 
								
							 
						 
						
							
							
								
								Move the metadata constructors back to 2.5 syntax.  
							
							... 
							
							
							
							llvm-svn: 77733 
							
						 
						
							2009-07-31 21:35:40 +00:00  
				
					
						
							
							
								 
						
							
								b292b8ce70 
								
							 
						 
						
							
							
								
								Move more code back to 2.5 APIs.  
							
							... 
							
							
							
							llvm-svn: 77635 
							
						 
						
							2009-07-30 23:03:37 +00:00  
				
					
						
							
							
								 
						
							
								a4f43fb5dd 
								
							 
						 
						
							
							
								
								Rename MDNode.h header. It defines MDnode and other metadata classes.  
							
							... 
							
							
							
							New name is Metadata.h.
llvm-svn: 77370 
							
						 
						
							2009-07-28 21:49:47 +00:00  
				
					
						
							
							
								 
						
							
								4aa3295a65 
								
							 
						 
						
							
							
								
								Return ConstantVector to 2.5 API.  
							
							... 
							
							
							
							llvm-svn: 77366 
							
						 
						
							2009-07-28 21:19:26 +00:00  
				
					
						
							
							
								 
						
							
								c2c7932c64 
								
							 
						 
						
							
							
								
								Change ConstantArray to 2.5 API.  
							
							... 
							
							
							
							llvm-svn: 77347 
							
						 
						
							2009-07-28 18:32:17 +00:00  
				
					
						
							
							
								 
						
							
								45308b578b 
								
							 
						 
						
							
							
								
								Move ConstantStruct back to 2.5 API.  
							
							... 
							
							
							
							llvm-svn: 77266 
							
						 
						
							2009-07-27 22:29:26 +00:00  
				
					
						
							
							
								 
						
							
								69c464dec4 
								
							 
						 
						
							
							
								
								Move ConstantFP construction back to the 2.5-ish API.  
							
							... 
							
							
							
							llvm-svn: 77247 
							
						 
						
							2009-07-27 20:59:43 +00:00  
				
					
						
							
							
								 
						
							
								e03eecb75f 
								
							 
						 
						
							
							
								
								Remove Value::{isName, getNameRef}.  
							
							... 
							
							
							
							Also, change MDString to use a StringRef.
llvm-svn: 77098 
							
						 
						
							2009-07-25 23:55:21 +00:00  
				
					
						
							
							
								 
						
							
								edb4a70325 
								
							 
						 
						
							
							
								
								Revert the ConstantInt constructors back to their 2.5 forms where possible, thanks to contexts-on-types.  More to come.  
							
							... 
							
							
							
							llvm-svn: 77011 
							
						 
						
							2009-07-24 23:12:02 +00:00  
				
					
						
							
							
								 
						
							
								0348a13cc6 
								
							 
						 
						
							
							
								
								Privatize the ConstantVector tables.  
							
							... 
							
							
							
							llvm-svn: 76922 
							
						 
						
							2009-07-24 00:36:24 +00:00  
				
					
						
							
							
								 
						
							
								909f6001e9 
								
							 
						 
						
							
							
								
								Privatize the ConstantStruct table.  
							
							... 
							
							
							
							llvm-svn: 76912 
							
						 
						
							2009-07-23 23:25:33 +00:00  
				
					
						
							
							
								 
						
							
								5bf72e20eb 
								
							 
						 
						
							
							
								
								Convert StringMap to using StringRef for its APIs.  
							
							... 
							
							
							
							- Yay for '-'s and simplifications!
 - I kept StringMap::GetOrCreateValue for compatibility purposes, this can
   eventually go away. Likewise the StringMapEntry Create functions still follow
   the old style.
 - NIFC.
llvm-svn: 76888 
							
						 
						
							2009-07-23 18:17:34 +00:00  
				
					
						
							
							
								 
						
							
								6292003492 
								
							 
						 
						
							
							
								
								MDString  
							
							... 
							
							
							
							- Rename member function size(). New name is length().
- Store string beginning and length. Earlier it used to store string end.
llvm-svn: 76841 
							
						 
						
							2009-07-23 02:00:51 +00:00  
				
					
						
							
							
								 
						
							
								e059ba6ed2 
								
							 
						 
						
							
							
								
								Derive MDNode from MetadataBase instead of Constant. Emit MDNodes into METADATA_BLOCK in bitcode file.  
							
							... 
							
							
							
							llvm-svn: 76834 
							
						 
						
							2009-07-23 01:07:34 +00:00  
				
					
						
							
							
								 
						
							
								3d34492c1f 
								
							 
						 
						
							
							
								
								Privatize the ConstantArray table.  
							
							... 
							
							
							
							llvm-svn: 76639 
							
						 
						
							2009-07-21 20:55:28 +00:00  
				
					
						
							
							
								 
						
							
								39ede7b8d1 
								
							 
						 
						
							
							
								
								Privatize the first of the value maps.  
							
							... 
							
							
							
							llvm-svn: 76634 
							
						 
						
							2009-07-21 20:13:12 +00:00  
				
					
						
							
							
								 
						
							
								4118ddeeed 
								
							 
						 
						
							
							
								
								Privatize the MDNode uniquing table.  
							
							... 
							
							
							
							llvm-svn: 76126 
							
						 
						
							2009-07-16 23:44:30 +00:00  
				
					
						
							
							
								 
						
							
								69ab416d66 
								
							 
						 
						
							
							
								
								Privatize the MDString uniquing table.  
							
							... 
							
							
							
							llvm-svn: 76113 
							
						 
						
							2009-07-16 22:11:26 +00:00  
				
					
						
							
							
								 
						
							
								c277dc408b 
								
							 
						 
						
							
							
								
								Privatize the ConstantFP table.  I'm on a roll!  
							
							... 
							
							
							
							llvm-svn: 76097 
							
						 
						
							2009-07-16 19:05:41 +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