diff options
author | bd <bdunahu@operationnull.com> | 2025-03-29 17:11:17 -0400 |
---|---|---|
committer | bd <bdunahu@operationnull.com> | 2025-03-29 17:11:17 -0400 |
commit | d21a1a9caa1f1791343a5376121936e552b1124c (patch) | |
tree | df28c01f6d01603e5408bc1b1b111a66adafbff7 /inc/if.h | |
parent | ac0ae7206491a42cdba70560b0db41cfc8c7f642 (diff) |
Fetch stage properly holds objects until parent is ready
Diffstat (limited to 'inc/if.h')
-rw-r--r-- | inc/if.h | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -15,7 +15,17 @@ class IF : public Stage */ IF(Stage *next); - Response advance(InstrDTO &i, Response p) override; + Response advance(InstrDTO &next_instr, Response p) override; + + private: + /** + * Performs a fetch only if a current fetch is not pending. Pending means + * that a fetch has completed successfully, but the caller stage in the + * pipeline is not ready to receive it. In this case, `curr_instr` is not + * the nullptr. + * @return STALLED if we are waiting on the storage devices, OK otherwise. + */ + void fetch_with_buffer(); }; #endif /* IF_H_INCLUDED */ |