From d1038c216f2488464a7feda2c5949e126e0c2f1a Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Tue, 25 Sep 2007 23:08:30 +0000 Subject: Use mmap to read from input files. --- gold/fileread.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'gold/fileread.h') diff --git a/gold/fileread.h b/gold/fileread.h index 0e5caa9..cda5d9c 100644 --- a/gold/fileread.h +++ b/gold/fileread.h @@ -114,13 +114,14 @@ class File_read File_read(const File_read&); File_read& operator=(const File_read&); - // A view into the file when not using mmap. + // A view into the file. class View { public: - View(off_t start, off_t size, const unsigned char* data, bool cache) + View(off_t start, off_t size, const unsigned char* data, bool cache, + bool mapped) : start_(start), size_(size), data_(data), lock_count_(0), - cache_(cache) + cache_(cache), mapped_(mapped) { } ~View(); @@ -163,6 +164,7 @@ class File_read const unsigned char* data_; int lock_count_; bool cache_; + bool mapped_; }; friend class File_view; -- cgit v1.1