Remove unused method. NFC.
authorRafael Espindola <rafael.espindola@gmail.com>
Wed, 12 Nov 2014 02:27:40 +0000 (02:27 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Wed, 12 Nov 2014 02:27:40 +0000 (02:27 +0000)
llvm-svn: 221757

llvm/include/llvm/Support/MemoryObject.h
llvm/include/llvm/Support/StreamableMemoryObject.h
llvm/lib/Support/MemoryObject.cpp
llvm/lib/Support/StreamableMemoryObject.cpp

index 17aa9d2..fcc6bf7 100644 (file)
@@ -24,11 +24,6 @@ public:
   /// Destructor      - Override as necessary.
   virtual ~MemoryObject();
 
-  /// getBase         - Returns the lowest valid address in the region.
-  ///
-  /// @result         - The lowest valid address.
-  virtual uint64_t getBase() const = 0;
-
   /// getExtent       - Returns the size of the region in bytes.  (The region is
   ///                   contiguous, so the highest valid address of the region
   ///                   is getBase() + getExtent() - 1).
index a56f954..8094b53 100644 (file)
@@ -68,7 +68,6 @@ class StreamableMemoryObject : public MemoryObject {
 class StreamingMemoryObject : public StreamableMemoryObject {
 public:
   StreamingMemoryObject(DataStreamer *streamer);
-  uint64_t getBase() const override { return 0; }
   uint64_t getExtent() const override;
   int readByte(uint64_t address, uint8_t *ptr) const override;
   int readBytes(uint64_t address, uint64_t size,
index 02b5b50..fe5fa87 100644 (file)
@@ -17,7 +17,7 @@ int MemoryObject::readBytes(uint64_t address,
                             uint64_t size,
                             uint8_t* buf) const {
   uint64_t current = address;
-  uint64_t limit = getBase() + getExtent();
+  uint64_t limit = getExtent();
 
   if (current + size > limit)
     return -1;
index 5cb0680..7909c8e 100644 (file)
@@ -25,7 +25,6 @@ public:
     assert(LastChar >= FirstChar && "Invalid start/end range");
   }
 
-  uint64_t getBase() const override { return 0; }
   uint64_t getExtent() const override {
     return LastChar - FirstChar;
   }