additional instructions are only ^0111 and not ^1111 (2)
This commit is contained in:
parent
e6d89c425e
commit
d81f7eec66
1 changed files with 39 additions and 31 deletions
12
cpu.cpp
12
cpu.cpp
|
@ -410,8 +410,12 @@ bool cpu::double_operand_instructions(const uint16_t instr)
|
|||
if (operation == 0b000)
|
||||
return single_operand_instructions(instr);
|
||||
|
||||
if (operation == 0b111 && word_mode == false)
|
||||
if (operation == 0b111) {
|
||||
if (word_mode)
|
||||
return false;
|
||||
|
||||
return additional_double_operand_instructions(instr);
|
||||
}
|
||||
|
||||
const uint8_t src = (instr >> 6) & 63;
|
||||
const uint8_t src_mode = (src >> 3) & 7;
|
||||
|
@ -1836,7 +1840,10 @@ std::map<std::string, std::vector<std::string> > cpu::disassemble(const uint16_t
|
|||
if (text.empty() == false && next_word != -1)
|
||||
instruction_words.push_back(next_word);
|
||||
}
|
||||
else if (do_opcode == 0b111 && word_mode == false) {
|
||||
else if (do_opcode == 0b111) {
|
||||
if (word_mode)
|
||||
name = "?";
|
||||
else {
|
||||
std::string src_text = format("R%d", (instruction >> 6) & 7);
|
||||
auto dst_text { addressing_to_string(dst_register, (addr + 2) & 65535, word_mode) };
|
||||
|
||||
|
@ -1876,6 +1883,7 @@ std::map<std::string, std::vector<std::string> > cpu::disassemble(const uint16_t
|
|||
if (text.empty() == false && next_word != -1)
|
||||
instruction_words.push_back(next_word);
|
||||
}
|
||||
}
|
||||
else {
|
||||
switch(do_opcode) {
|
||||
case 0b001:
|
||||
|
|
Loading…
Add table
Reference in a new issue