diff options
author | Andreas Hansson <andreas.hansson@arm.com> | 2013-05-30 12:53:54 -0400 |
---|---|---|
committer | Andreas Hansson <andreas.hansson@arm.com> | 2013-05-30 12:53:54 -0400 |
commit | 88aa7755f4f4ebd39a26fbece9c0d09cd195a010 (patch) | |
tree | ff24a9bb88a3cf810f3ffd40927290833879bdaa /src/mem/abstract_mem.hh | |
parent | cc8911261e11d67f2b8745289ed5ecbb89c9d917 (diff) | |
download | gem5-88aa7755f4f4ebd39a26fbece9c0d09cd195a010.tar.xz |
mem: Avoid explicitly zeroing the memory backing store
This patch removes the explicit memset as it is redundant and causes
the simulator to touch the entire space, forcing the host system to
allocate the pages.
Anonymous pages are mapped on the first access, and the page-fault
handler is responsible for zeroing them. Thus, the pages are still
zeroed, but we avoid touching the entire allocated space which enables
us to use much larger memory sizes as long as not all the memory is
actually used.
Diffstat (limited to 'src/mem/abstract_mem.hh')
-rw-r--r-- | src/mem/abstract_mem.hh | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/src/mem/abstract_mem.hh b/src/mem/abstract_mem.hh index c1ecbdba4..57a47e390 100644 --- a/src/mem/abstract_mem.hh +++ b/src/mem/abstract_mem.hh @@ -203,13 +203,6 @@ class AbstractMemory : public MemObject bool isNull() const { return params()->null; } /** - * See if this memory should be initialized to zero or not. - * - * @return true if zero - */ - bool initToZero() const { return params()->zero; } - - /** * Set the host memory backing store to be used by this memory * controller. * |