projects
/
gem5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
93c4527
)
base: add new ChunkGenerator method to identify last chunk
author
Brandon Potter
<brandon.potter@amd.com>
Wed, 22 Apr 2015 14:51:27 +0000
(07:51 -0700)
committer
Brandon Potter
<brandon.potter@amd.com>
Wed, 22 Apr 2015 14:51:27 +0000
(07:51 -0700)
src/base/chunk_generator.hh
patch
|
blob
|
history
diff --git
a/src/base/chunk_generator.hh
b/src/base/chunk_generator.hh
index cf303f693dc1c2b21b5e9dceeeb7e4f236734acb..a11bd73e6e54eb2ddc5203e50302f0e009598be5 100644
(file)
--- a/
src/base/chunk_generator.hh
+++ b/
src/base/chunk_generator.hh
@@
-122,6
+122,12
@@
class ChunkGenerator
*/
bool done() const { return (curSize == 0); }
+ /**
+ * Is this the last chunk?
+ * @return True if yes, false if more to go.
+ */
+ bool last() const { return (sizeLeft == 0); }
+
/**
* Advance generator to next chunk.
* @return True if successful, false if unsuccessful