Per discussion on the list, remove BitcodeVerify pass to reimplement as a free function.
authorChad Rosier <mcrosier@apple.com>
Wed, 14 Dec 2011 00:29:31 +0000 (00:29 +0000)
committerChad Rosier <mcrosier@apple.com>
Wed, 14 Dec 2011 00:29:31 +0000 (00:29 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146531 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Bitcode/ReaderWriter.h
lib/Bitcode/Writer/BitcodeVerifier.cpp [deleted file]
lib/Bitcode/Writer/CMakeLists.txt

index 4f8630309c69a75e5a3fa4085b07801754402bd5..fa754c014621f52af5698561d1718ae014f24bca 100644 (file)
@@ -60,12 +60,8 @@ namespace llvm {
   /// createBitcodeWriterPass - Create and return a pass that writes the module
   /// to the specified ostream.
   ModulePass *createBitcodeWriterPass(raw_ostream &Str);
-
-  /// createBitcodeVerifierPass - Create a pass that writes a module to disk and
-  /// then reads the module back in to verify bitcode serialization and
-  /// deserialization.
-  ModulePass *createBitcodeVerifierPass(raw_ostream &Str);
-
+  
+  
   /// isBitcodeWrapper - Return true if the given bytes are the magic bytes
   /// for an LLVM IR bitcode wrapper.
   ///
diff --git a/lib/Bitcode/Writer/BitcodeVerifier.cpp b/lib/Bitcode/Writer/BitcodeVerifier.cpp
deleted file mode 100644 (file)
index 9296e29..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-//===--- Bitcode/Writer/BitcodeVerifier.cpp - Bitcode Writer ----------===//
-//
-//                     The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-//
-// BitcodeVerifier implementation.
-//
-//===----------------------------------------------------------------------===//
-
-#include "llvm/Pass.h"
-#include "llvm/Bitcode/ReaderWriter.h"
-#include "llvm/Support/Debug.h"
-#include "llvm/Support/raw_ostream.h"
-
-using namespace llvm;
-
-namespace {
-  struct VerifyBitcode : public ModulePass {
-    raw_ostream &OS; // raw_ostream to read from
-  public:
-    static char ID; // Pass identification, replacement for typeid
-    explicit VerifyBitcode(raw_ostream &o)
-      : ModulePass(ID), OS(o) {}
-    
-    virtual void getAnalysisUsage(AnalysisUsage &AU) const {
-    }
-
-    const char *getPassName() const { return "Bitcode Verifier"; }
-    
-    bool runOnModule(Module &M) {
-      Verify(M);
-      return false;
-    }
-
-    void Verify(Module &M);
-  };
-}
-
-char VerifyBitcode::ID = 0;
-
-/// createBitcodeVerifierPass - Create a pass that writes a module to disk and
-/// then reads the module back in to verify bitcode serialization and
-/// deserialization.
-ModulePass *llvm::createBitcodeVerifierPass(raw_ostream &Str) {
-  return new VerifyBitcode(Str);
-}
-
-void VerifyBitcode::Verify(Module &M) {
-  dbgs() << "BitcodeVerifier!\n";
-}
index 6d5144ed182d4065123da738533d627acb3356fc..f097b097c3371d5e8124293c3892ec5f5aac8e0e 100644 (file)
@@ -2,6 +2,5 @@ add_llvm_library(LLVMBitWriter
   BitWriter.cpp
   BitcodeWriter.cpp
   BitcodeWriterPass.cpp
-  BitcodeVerifier.cpp
   ValueEnumerator.cpp
   )