public:
MallocSlabAllocator() : Allocator() { }
virtual ~MallocSlabAllocator();
- virtual MemSlab *Allocate(size_t Size) override;
- virtual void Deallocate(MemSlab *Slab) override;
+ MemSlab *Allocate(size_t Size) override;
+ void Deallocate(MemSlab *Slab) override;
};
/// BumpPtrAllocator - This allocator is useful for containers that need
///
const char *Scanned;
- virtual void write_impl(const char *Ptr, size_t Size) override;
+ void write_impl(const char *Ptr, size_t Size) override;
/// current_pos - Return the current position within the stream,
/// not counting the bytes currently in the buffer.
- virtual uint64_t current_pos() const override {
+ uint64_t current_pos() const override {
// Our current position in the stream is all the contents which have been
// written to the underlying stream (*not* the current position of the
// underlying stream).
const char *Str;
public:
PrettyStackTraceString(const char *str) : Str(str) {}
- virtual void print(raw_ostream &OS) const override;
+ void print(raw_ostream &OS) const override;
};
/// PrettyStackTraceProgram - This object prints a specified program arguments
: ArgC(argc), ArgV(argv) {
EnablePrettyStackTrace();
}
- virtual void print(raw_ostream &OS) const override;
+ void print(raw_ostream &OS) const override;
};
} // end namespace llvm
/// getBase - Returns the lowest valid address in the region.
///
/// @result - The lowest valid address.
- virtual uint64_t getBase() const override = 0;
+ uint64_t getBase() const override = 0;
/// getExtent - Returns the size of the region in bytes. (The region is
/// contiguous, so the highest valid address of the region
/// May block until all bytes in the stream have been read
///
/// @result - The size of the region.
- virtual uint64_t getExtent() const override = 0;
+ uint64_t getExtent() const override = 0;
/// readByte - Tries to read a single byte from the region.
/// May block until (address - base) bytes have been read
/// @param ptr - A pointer to a byte to be filled in. Must be non-NULL.
/// @result - 0 if successful; -1 if not. Failure may be due to a
/// bounds violation or an implementation-specific error.
- virtual int readByte(uint64_t address, uint8_t *ptr) const override = 0;
+ int readByte(uint64_t address, uint8_t *ptr) const override = 0;
/// readBytes - Tries to read a contiguous range of bytes from the
/// region, up to the end of the region.
/// and large enough to hold size bytes.
/// @result - 0 if successful; -1 if not. Failure may be due to a
/// bounds violation or an implementation-specific error.
- virtual int readBytes(uint64_t address,
- uint64_t size,
- uint8_t *buf) const override = 0;
+ int readBytes(uint64_t address, uint64_t size,
+ uint8_t *buf) const override = 0;
/// getPointer - Ensures that the requested data is in memory, and returns
/// A pointer to it. More efficient than using readBytes if the
class StreamingMemoryObject : public StreamableMemoryObject {
public:
StreamingMemoryObject(DataStreamer *streamer);
- virtual uint64_t getBase() const override { return 0; }
- virtual uint64_t getExtent() const override;
- virtual int readByte(uint64_t address, uint8_t *ptr) const override;
- virtual int readBytes(uint64_t address,
- uint64_t size,
- uint8_t *buf) const override;
- virtual const uint8_t *getPointer(uint64_t address,
- uint64_t size) const override {
+ 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,
+ uint8_t *buf) const override;
+ const uint8_t *getPointer(uint64_t address, uint64_t size) const override {
// This could be fixed by ensuring the bytes are fetched and making a copy,
// requiring that the bitcode size be known, or otherwise ensuring that
// the memory doesn't go away/get reallocated, but it's
assert(0 && "getPointer in streaming memory objects not allowed");
return NULL;
}
- virtual bool isValidAddress(uint64_t address) const override;
- virtual bool isObjectEnd(uint64_t address) const override;
+ bool isValidAddress(uint64_t address) const override;
+ bool isObjectEnd(uint64_t address) const override;
/// Drop s bytes from the front of the stream, pushing the positions of the
/// remaining bytes down by s. This is used to skip past the bitcode header,
/// @returns The value, or nullptr if failed() == true.
Node *getValue();
- virtual void skip() override {
+ void skip() override {
getKey()->skip();
getValue()->skip();
}
iterator end() { return iterator(); }
- virtual void skip() override {
+ void skip() override {
yaml::skip(*this);
}
iterator end() { return iterator(); }
- virtual void skip() override {
+ void skip() override {
yaml::skip(*this);
}
Filled = false;
}
- virtual void write_impl(const char *Ptr, size_t Size) override;
+ void write_impl(const char *Ptr, size_t Size) override;
/// current_pos - Return the current position within the stream,
/// not counting the bytes currently in the buffer.
///
- virtual uint64_t current_pos() const override {
+ uint64_t current_pos() const override {
// This has the same effect as calling TheStream.current_pos(),
// but that interface is private.
return TheStream->tell() - TheStream->GetNumBytesInBuffer();
std::ostream &OS;
/// write_impl - See raw_ostream::write_impl.
- virtual void write_impl(const char *Ptr, size_t Size) override;
+ void write_impl(const char *Ptr, size_t Size) override;
/// current_pos - Return the current position within the stream, not
/// counting the bytes currently in the buffer.
- virtual uint64_t current_pos() const override;
+ uint64_t current_pos() const override;
public:
raw_os_ostream(std::ostream &O) : OS(O) {}
uint64_t pos;
/// write_impl - See raw_ostream::write_impl.
- virtual void write_impl(const char *Ptr, size_t Size) override;
+ void write_impl(const char *Ptr, size_t Size) override;
/// current_pos - Return the current position within the stream, not
/// counting the bytes currently in the buffer.
- virtual uint64_t current_pos() const override { return pos; }
+ uint64_t current_pos() const override { return pos; }
/// preferred_buffer_size - Determine an efficient buffer size.
- virtual size_t preferred_buffer_size() const override;
+ size_t preferred_buffer_size() const override;
/// error_detected - Set the flag indicating that an output error has
/// been encountered.
UseAtomicWrites = Value;
}
- virtual raw_ostream &changeColor(enum Colors colors, bool bold=false,
- bool bg=false) override;
- virtual raw_ostream &resetColor() override;
+ raw_ostream &changeColor(enum Colors colors, bool bold=false,
+ bool bg=false) override;
+ raw_ostream &resetColor() override;
- virtual raw_ostream &reverseColor() override;
+ raw_ostream &reverseColor() override;
- virtual bool is_displayed() const override;
+ bool is_displayed() const override;
- virtual bool has_colors() const override;
+ bool has_colors() const override;
/// has_error - Return the value of the flag in this raw_fd_ostream indicating
/// whether an output error has been encountered.
std::string &OS;
/// write_impl - See raw_ostream::write_impl.
- virtual void write_impl(const char *Ptr, size_t Size) override;
+ void write_impl(const char *Ptr, size_t Size) override;
/// current_pos - Return the current position within the stream, not
/// counting the bytes currently in the buffer.
- virtual uint64_t current_pos() const override { return OS.size(); }
+ uint64_t current_pos() const override { return OS.size(); }
public:
explicit raw_string_ostream(std::string &O) : OS(O) {}
~raw_string_ostream();
SmallVectorImpl<char> &OS;
/// write_impl - See raw_ostream::write_impl.
- virtual void write_impl(const char *Ptr, size_t Size) override;
+ void write_impl(const char *Ptr, size_t Size) override;
/// current_pos - Return the current position within the stream, not
/// counting the bytes currently in the buffer.
- virtual uint64_t current_pos() const override;
+ uint64_t current_pos() const override;
public:
/// Construct a new raw_svector_ostream.
///
/// raw_null_ostream - A raw_ostream that discards all output.
class raw_null_ostream : public raw_ostream {
/// write_impl - See raw_ostream::write_impl.
- virtual void write_impl(const char *Ptr, size_t size) override;
+ void write_impl(const char *Ptr, size_t size) override;
/// current_pos - Return the current position within the stream, not
/// counting the bytes currently in the buffer.
- virtual uint64_t current_pos() const override;
+ uint64_t current_pos() const override;
public:
explicit raw_null_ostream() {}
class _do_message : public error_category
{
public:
- virtual std::string message(int ev) const override;
+ std::string message(int ev) const override;
};
const error_category& generic_category();
protected:
/// UpdatedSearchState - Callback used when the search state changes.
- virtual void UpdatedSearchState(const changeset_ty &Changes,
+ void UpdatedSearchState(const changeset_ty &Changes,
const changesetlist_ty &Sets) override {
DDAI.UpdatedSearchState(Changes, Sets, Required);
}
- virtual bool ExecuteOneTest(const changeset_ty &S) override {
+ bool ExecuteOneTest(const changeset_ty &S) override {
return DDAI.GetTestResult(S, Required);
}
virtual ~DataFileStreamer() {
close(Fd);
}
- virtual size_t GetBytes(unsigned char *buf, size_t len) override {
+ size_t GetBytes(unsigned char *buf, size_t len) override {
NumStreamFetches++;
return read(Fd, buf, len);
}
init(InputData.begin(), InputData.end(), RequiresNullTerminator);
}
- virtual const char *getBufferIdentifier() const override {
+ const char *getBufferIdentifier() const override {
// The name is stored after the class itself.
return reinterpret_cast<const char*>(this + 1);
}
- virtual BufferKind getBufferKind() const override {
+ BufferKind getBufferKind() const override {
return MemoryBuffer_Malloc;
}
};
}
}
- virtual const char *getBufferIdentifier() const override {
+ const char *getBufferIdentifier() const override {
// The name is stored after the class itself.
return reinterpret_cast<const char *>(this + 1);
}
- virtual BufferKind getBufferKind() const override {
+ BufferKind getBufferKind() const override {
return MemoryBuffer_MMap;
}
};
assert(LastChar >= FirstChar && "Invalid start/end range");
}
- virtual uint64_t getBase() const override { return 0; }
- virtual uint64_t getExtent() const override {
+ uint64_t getBase() const override { return 0; }
+ uint64_t getExtent() const override {
return LastChar - FirstChar;
}
- virtual int readByte(uint64_t address, uint8_t* ptr) const override;
- virtual int readBytes(uint64_t address,
- uint64_t size,
- uint8_t *buf) const override;
- virtual const uint8_t *getPointer(uint64_t address,
- uint64_t size) const override;
- virtual bool isValidAddress(uint64_t address) const override {
+ int readByte(uint64_t address, uint8_t* ptr) const override;
+ int readBytes(uint64_t address, uint64_t size,
+ uint8_t *buf) const override;
+ const uint8_t *getPointer(uint64_t address, uint64_t size) const override;
+ bool isValidAddress(uint64_t address) const override {
return validAddress(address);
}
- virtual bool isObjectEnd(uint64_t address) const override {
+ bool isObjectEnd(uint64_t address) const override {
return objectEnd(address);
}
class _generic_error_category : public _do_message {
public:
- virtual const char* name() const override;
- virtual std::string message(int ev) const override;
+ const char* name() const override;
+ std::string message(int ev) const override;
};
const char*
class _system_error_category : public _do_message {
public:
- virtual const char* name() const override;
- virtual std::string message(int ev) const override;
- virtual error_condition default_error_condition(int ev) const override;
+ const char* name() const override;
+ std::string message(int ev) const override;
+ error_condition default_error_condition(int ev) const override;
};
const char*