log psw as value
This commit is contained in:
parent
00ec6af6cd
commit
f75293a9b0
2 changed files with 3 additions and 2 deletions
1
cpu.cpp
1
cpu.cpp
|
@ -2212,6 +2212,7 @@ std::map<std::string, std::vector<std::string> > cpu::disassemble(const uint16_t
|
|||
std::string psw_str = format("%d%d|%d|%d|%c%c%c%c%c", psw >> 14, (psw >> 12) & 3, (psw >> 11) & 1, (psw >> 5) & 7,
|
||||
psw & 16?'t':'-', psw & 8?'n':'-', psw & 4?'z':'-', psw & 2 ? 'v':'-', psw & 1 ? 'c':'-');
|
||||
out.insert({ "psw", { psw_str } });
|
||||
out.insert({ "psw-value", { format("%06o", psw) } });
|
||||
|
||||
// values worked with
|
||||
std::vector<std::string> work_values_str;
|
||||
|
|
|
@ -65,10 +65,10 @@ int disassemble(cpu *const c, console *const cnsl, const uint16_t pc, const bool
|
|||
work_values.c_str()
|
||||
);
|
||||
else
|
||||
result = format("R0: %s, R1: %s, R2: %s, R3: %s, R4: %s, R5: %s, SP: %s, PC: %06o, PSW: %s, instr: %s: %s - MMR0/1/2/3: %s/%s/%s/%s",
|
||||
result = format("R0: %s, R1: %s, R2: %s, R3: %s, R4: %s, R5: %s, SP: %s, PC: %06o, PSW: %s (%s), instr: %s: %s - MMR0/1/2/3: %s/%s/%s/%s",
|
||||
registers[0].c_str(), registers[1].c_str(), registers[2].c_str(), registers[3].c_str(), registers[4].c_str(), registers[5].c_str(),
|
||||
registers[6].c_str(), pc,
|
||||
psw.c_str(),
|
||||
psw.c_str(), data["psw-value"][0].c_str(),
|
||||
instruction_values.c_str(),
|
||||
instruction.c_str(),
|
||||
MMR0.c_str(), MMR1.c_str(), MMR2.c_str(), MMR3.c_str()
|
||||
|
|
Loading…
Add table
Reference in a new issue