mirror of
https://github.com/TomHarte/CLK.git
synced 2024-11-26 08:49:37 +00:00
Corrects PLB, PLD, PLP.
This commit is contained in:
parent
b510b9d337
commit
1ba0a117e7
@ -45,6 +45,7 @@ class KlausDormannTests: XCTestCase {
|
||||
case 0x3399: return nil // success!
|
||||
|
||||
case 0x052a: return "TAX, DEX or LDA did not correctly set flags, or BEQ did not branch correctly"
|
||||
case 0x05db: return "PLP did not affect N flag correctly"
|
||||
case 0x33a7: return "Decimal ADC result has wrong value"
|
||||
case 0x3502: return "Binary SBC result has wrong value"
|
||||
case 0x33b9: return "Decimal SBC result has wrong value"
|
||||
|
@ -329,17 +329,17 @@ template <typename BusHandler> void Processor<BusHandler>::run_for(const Cycles
|
||||
break;
|
||||
|
||||
case PLB:
|
||||
data_bank_ = (instruction_buffer_.value & 0xff) << 16;
|
||||
data_bank_ = (data_buffer_.value & 0xff) << 16;
|
||||
flags_.set_nz(instruction_buffer_.value);
|
||||
break;
|
||||
|
||||
case PLD:
|
||||
direct_ = instruction_buffer_.value;
|
||||
direct_ = data_buffer_.value;
|
||||
flags_.set_nz(instruction_buffer_.value);
|
||||
break;
|
||||
|
||||
case PLP:
|
||||
flags_.set(instruction_buffer_.value);
|
||||
flags_.set(data_buffer_.value);
|
||||
|
||||
if(!emulation_flag_) {
|
||||
assert(false); // TODO: M and X.
|
||||
|
Loading…
Reference in New Issue
Block a user