diff --git a/InstructionSets/x86/Instruction.cpp b/InstructionSets/x86/Instruction.cpp index 57b76c04a..0f1bc62db 100644 --- a/InstructionSets/x86/Instruction.cpp +++ b/InstructionSets/x86/Instruction.cpp @@ -141,6 +141,7 @@ std::string InstructionSet::x86::to_string(Operation operation, DataSize size) { default: assert(false); + return ""; } } diff --git a/InstructionSets/x86/Instruction.hpp b/InstructionSets/x86/Instruction.hpp index a50abc24d..1467defcf 100644 --- a/InstructionSets/x86/Instruction.hpp +++ b/InstructionSets/x86/Instruction.hpp @@ -83,7 +83,7 @@ enum class Operation: uint8_t { /// Reads from the port specified by source to the destination. IN, - /// Writes from the port specified by destination from the source. + /// Writes to the port specified by destination from the source. OUT, // Various jumps; see the displacement to calculate targets. diff --git a/OSBindings/Mac/Clock Signal.xcodeproj/project.pbxproj b/OSBindings/Mac/Clock Signal.xcodeproj/project.pbxproj index 352f0ad27..81c6ba4b8 100644 --- a/OSBindings/Mac/Clock Signal.xcodeproj/project.pbxproj +++ b/OSBindings/Mac/Clock Signal.xcodeproj/project.pbxproj @@ -8,6 +8,7 @@ /* Begin PBXBuildFile section */ 423BDC4A2AB24699008E37B6 /* 8088Tests.mm in Sources */ = {isa = PBXBuildFile; fileRef = 423BDC492AB24699008E37B6 /* 8088Tests.mm */; }; + 42437B332AC70833006DFED1 /* HDV.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B6FD0342923061300EC4760 /* HDV.cpp */; }; 4281683A2A37AFB4008ECD27 /* DispatcherTests.mm in Sources */ = {isa = PBXBuildFile; fileRef = 428168392A37AFB4008ECD27 /* DispatcherTests.mm */; }; 42A5E80C2ABBE04600A0DD5D /* NeskellTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 42A5E80B2ABBE04600A0DD5D /* NeskellTests.swift */; }; 42A5E8442ABBE16F00A0DD5D /* illegal_rmw_test.bin in Resources */ = {isa = PBXBuildFile; fileRef = 42A5E8332ABBE16F00A0DD5D /* illegal_rmw_test.bin */; }; @@ -6329,6 +6330,7 @@ 4B778F4323A5F1B00000D260 /* ImplicitSectors.cpp in Sources */, 4B7752B128217EA30073E2C5 /* StaticAnalyser.cpp in Sources */, 4B778F5123A5F2290000D260 /* StaticAnalyser.cpp in Sources */, + 42437B332AC70833006DFED1 /* HDV.cpp in Sources */, 4B7752C028217F3D0073E2C5 /* Line.cpp in Sources */, 4B7C7A00282C3BCA002D6C0B /* 68000flamewingTests.mm in Sources */, 4B778F0223A5EBA40000D260 /* MFMSectorDump.cpp in Sources */, diff --git a/OSBindings/Mac/Clock SignalTests/8088Tests.mm b/OSBindings/Mac/Clock SignalTests/8088Tests.mm index 7ff618037..1efe32904 100644 --- a/OSBindings/Mac/Clock SignalTests/8088Tests.mm +++ b/OSBindings/Mac/Clock SignalTests/8088Tests.mm @@ -146,7 +146,9 @@ std::string to_string( - (NSArray *)testFiles { NSString *path = [NSString stringWithUTF8String:TestSuiteHome]; NSSet *allowList = [NSSet setWithArray:@[ -// @"F6.7.json.gz", + // Failing CALL and JMP. +// @"FF.3.json.gz", +// @"FF.5.json.gz", ]]; // Unofficial opcodes; ignored for now. @@ -250,6 +252,34 @@ std::string to_string( operation += to_string(instruction.source(), instruction, offsetLength, immediateLength, InstructionSet::x86::DataSize::DWord); break; + case Operation::IN: + operation += " "; + operation += to_string(instruction.destination(), instruction, offsetLength, immediateLength); + operation += ", "; + switch(instruction.source().source()) { + case Source::DirectAddress: + operation += to_hex(instruction.offset(), 2, true); + break; + default: + operation += to_string(instruction.source(), instruction, offsetLength, immediateLength, InstructionSet::x86::DataSize::Word); + break; + } + break; + + case Operation::OUT: + operation += " "; + switch(instruction.destination().source()) { + case Source::DirectAddress: + operation += to_hex(instruction.offset(), 2, true); + break; + default: + operation += to_string(instruction.destination(), instruction, offsetLength, immediateLength, InstructionSet::x86::DataSize::Word); + break; + } + operation += ", "; + operation += to_string(instruction.source(), instruction, offsetLength, immediateLength); + break; + // Rolls and shifts list eCX as a source on the understanding that everyone knows that rolls and shifts // use CL even when they're shifting or rolling a word-sized quantity. case Operation::RCL: case Operation::RCR: