1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-07-02 20:30:00 +00:00

Corrected "should I adjust history?" tests.

This commit is contained in:
Thomas Harte 2017-06-11 16:41:34 -04:00
parent c2bc9a8c62
commit d12e50eb02

View File

@ -1753,7 +1753,7 @@ template <class T> class Processor {
// If this change happened at least one cycle ago then: (i) we're promised that this is a machine
// cycle per the contract on supplying an offset; and (ii) that means it happened before the lines
// were sampled. So adjust the most recent sample.
if(offset <= 0) {
if(offset < 0) {
last_request_status_ = (last_request_status_ & ~Interrupt::IRQ) | (request_status_ & Interrupt::IRQ);
}
}
@ -1767,7 +1767,7 @@ template <class T> class Processor {
// NMIs are edge triggered and cannot be masked.
if(value) {
request_status_ |= Interrupt::NMI;
if(offset <= 0) {
if(offset < 0) {
last_request_status_ |= Interrupt::NMI;
}
}