Original Post
Pretend this is a stage in the pipeline of a processor.
Data from the 1st register works its way through the combinational logic, where a boolean value is ultimately produced (RESULT). If this signal is 1, then some data is written to the 2nd register. Otherwise the contents of the 2nd register must remain intact.
The problem is, at the beginning of the cycle, RESULT still has its old value from the previous cycle. If it is 1, then the write would occur, even if SIGNAL eventually changes to 0 later in the cycle.
My proposed solution is the "delay circuit". Assume RESULT_IS_VALID was 0 in the previous cycle. It is changed to 1 at the start of the current cycle, but because of the delay circuit, this 1 does not propogate to the AND gate until after the the new value for RESULT has propogated through the combinational logic.
Is this a reasonable, realistic solution? (It seems kludgy.) Also, I have no idea how the delay circuit should be implemented. Lastly, this processor''s clock can apparently be set to different rates, and I don''t know if a fixed delay would work for all clock rates.