diff options
author | Siddarth Suresh <155843085+SiddarthSuresh98@users.noreply.github.com> | 2025-03-10 10:28:28 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-10 10:28:28 -0400 |
commit | 66edce63597093cf5f3afa5b577fd9e3ecae0ef6 (patch) | |
tree | a0b0df4fff6f7d680901cd6007df67b15b3df3b6 /inc/storage.h | |
parent | 92b41d1a8b970c46b0c6d2d8d538c68855a4de25 (diff) | |
parent | 1f8b8babcfb383f1fb0281663561161061684206 (diff) |
Merge pull request #19 from bdunahu/bdunahu
cache store, handle load requests to memory, write allocate policy
-- changes look good
Diffstat (limited to 'inc/storage.h')
-rw-r--r-- | inc/storage.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/inc/storage.h b/inc/storage.h index 1fb41b0..793b982 100644 --- a/inc/storage.h +++ b/inc/storage.h @@ -32,7 +32,10 @@ class Storage * @return a status code reflecting the state of the request, and the * data being returned. */ - virtual Response read(Accessor accessor, int address, std::array<signed int, LINE_SIZE>& data) = 0; + virtual Response read( + Accessor accessor, + int address, + std::array<signed int, LINE_SIZE> &data) = 0; /** * Sidedoor view of `lines` of memory starting at `base`. * @param The base line to start getting memory from. @@ -48,10 +51,6 @@ class Storage protected: /** - * Helper for `write`. - */ - void do_write(signed int, int); - /** * The data currently stored in this level of storage. */ std::vector<std::array<signed int, LINE_SIZE>> *data; @@ -73,6 +72,11 @@ class Storage * The number of cycles until the current request is completed. */ int wait_time; + /** + * A flag indicating whether this level of storage is currently waiting for + * a lower level. + */ + int is_waiting; }; #endif /* STORAGE_H_INCLUDED */ |