Teach SCEV's icmp simplification logic that a-b == 0 is equivalent to a == b.
[oota-llvm.git] / include / llvm / Module.h
index 8c50098dcedeb372378f8e757ff7ad25ec27fe0d..cb7c1dc36a627e4d8ced3cc917a6aeb33e6c6b27 100644 (file)
@@ -303,15 +303,13 @@ public:
 
   /// findUsedStructTypes - Walk the entire module and find all of the
   /// struct types that are in use, returning them in a vector.
-  void findUsedStructTypes(std::vector<StructType*> &StructTypes) const;
+  void findUsedStructTypes(std::vector<StructType*> &StructTypes,
+                           bool OnlyNamed = false) const;
   
   /// getTypeByName - Return the type with the specified name, or null if there
   /// is none by that name.
   StructType *getTypeByName(StringRef Name) const;
 
-  /// getNumNamedStructTypes - Return the number of named struct types.
-  unsigned getNumNamedStructTypes() const;
-
 /// @}
 /// @name Function Accessors
 /// @{
@@ -500,6 +498,13 @@ public:
   static iplist<GlobalAlias> Module::*getSublistAccess(GlobalAlias*) {
     return &Module::AliasList;
   }
+  /// Get the Module's list of named metadata (constant).
+  const NamedMDListType  &getNamedMDList() const      { return NamedMDList; }
+  /// Get the Module's list of named metadata.
+  NamedMDListType        &getNamedMDList()            { return NamedMDList; }
+  static ilist<NamedMDNode> Module::*getSublistAccess(NamedMDNode*) {
+    return &Module::NamedMDList;
+  }
   /// Get the symbol table of global variable and function identifiers
   const ValueSymbolTable &getValueSymbolTable() const { return *ValSymTab; }
   /// Get the Module's symbol table of global variable and function identifiers.