1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-06-30 22:29:56 +00:00

Eliminate INT3 special case.

This commit is contained in:
Thomas Harte 2022-03-11 14:03:46 -05:00
parent 4b4f92780e
commit 44252984c2
2 changed files with 6 additions and 3 deletions

View File

@ -370,7 +370,12 @@ std::pair<int, typename Decoder<model>::InstructionT> Decoder<model>::decode(con
case 0xca: RegData(RETfar, None, data_size_); break;
case 0xcb: Complete(RETfar, None, None, DataSize::DWord); break;
case 0xcc: Complete(INT3, None, None, DataSize::None); break;
case 0xcc:
// Encode INT3 as though it were INT with an
// immediate operand of 3.
Complete(INT, Immediate, None, DataSize::Byte);
operand_ = 3;
break;
case 0xcd: RegData(INT, None, DataSize::Byte); break;
case 0xce: Complete(INTO, None, None, DataSize::None); break;
case 0xcf: Complete(IRET, None, None, DataSize::None); break;

View File

@ -108,8 +108,6 @@ enum class Operation: uint8_t {
JPCX,
/// Generates a software interrupt of the level stated in the operand.
INT,
/// Generates a software interrupt of level 3.
INT3,
/// Generates a software interrupt of level 4 if overflow is set.
INTO,