Add a method to the BitcodeReader to parse only the identification block
[oota-llvm.git] / include / llvm / LTO / LTOModule.h
index eda5a3a09ce0ca4466faf493713cfc2626390fa9..c3e86afe1d82b3ea8a42038fe8e119054f525126 100644 (file)
@@ -74,6 +74,11 @@ public:
   static bool isBitcodeForTarget(MemoryBuffer *memBuffer,
                                  StringRef triplePrefix);
 
+  /// Returns a string representing the producer identification stored in the
+  /// bitcode, or "" if the bitcode does not contains any.
+  ///
+  static std::string getProducerString(MemoryBuffer *Buffer);
+
   /// Create a MemoryBuffer from a memory range with an optional name.
   static std::unique_ptr<MemoryBuffer>
   makeBuffer(const void *mem, size_t length, StringRef name = "");