[llvm-commits] [llvm] r146531 - in /llvm/trunk: include/llvm/Bitcode/ReaderWriter.h lib/Bitcode/Writer/BitcodeVerifier.cpp lib/Bitcode/Writer/CMakeLists.txt
Chad Rosier
mcrosier at apple.com
Tue Dec 13 16:29:31 PST 2011
Author: mcrosier
Date: Tue Dec 13 18:29:31 2011
New Revision: 146531
URL: http://llvm.org/viewvc/llvm-project?rev=146531&view=rev
Log:
Per discussion on the list, remove BitcodeVerify pass to reimplement as a free function.
Removed:
llvm/trunk/lib/Bitcode/Writer/BitcodeVerifier.cpp
Modified:
llvm/trunk/include/llvm/Bitcode/ReaderWriter.h
llvm/trunk/lib/Bitcode/Writer/CMakeLists.txt
Modified: llvm/trunk/include/llvm/Bitcode/ReaderWriter.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Bitcode/ReaderWriter.h?rev=146531&r1=146530&r2=146531&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Bitcode/ReaderWriter.h (original)
+++ llvm/trunk/include/llvm/Bitcode/ReaderWriter.h Tue Dec 13 18:29:31 2011
@@ -60,12 +60,8 @@
/// 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.
///
Removed: llvm/trunk/lib/Bitcode/Writer/BitcodeVerifier.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Bitcode/Writer/BitcodeVerifier.cpp?rev=146530&view=auto
==============================================================================
--- llvm/trunk/lib/Bitcode/Writer/BitcodeVerifier.cpp (original)
+++ llvm/trunk/lib/Bitcode/Writer/BitcodeVerifier.cpp (removed)
@@ -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";
-}
Modified: llvm/trunk/lib/Bitcode/Writer/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Bitcode/Writer/CMakeLists.txt?rev=146531&r1=146530&r2=146531&view=diff
==============================================================================
--- llvm/trunk/lib/Bitcode/Writer/CMakeLists.txt (original)
+++ llvm/trunk/lib/Bitcode/Writer/CMakeLists.txt Tue Dec 13 18:29:31 2011
@@ -2,6 +2,5 @@
BitWriter.cpp
BitcodeWriter.cpp
BitcodeWriterPass.cpp
- BitcodeVerifier.cpp
ValueEnumerator.cpp
)
More information about the llvm-commits
mailing list