Refactor: ModRM Handler replaced with compile-time lookup table.

Started refactoring to a library-based model to easily integrate
comprehensive unit testing. Added CPU exception handling system for
the GUI. Non-critical exceptions (though critical to execution of
emulated application) will not shutdown the application in the future
releases. Refactored Userspace::Run() logic so that the GUI-controls
reflect emulator behavior.
This commit is contained in:
0x221E
2026-02-10 14:57:55 +01:00
parent 3e1e19023d
commit 9b250a6270
22 changed files with 377 additions and 137 deletions

21
tests/test.cpp Normal file
View File

@@ -0,0 +1,21 @@
#include <gtest/gtest.h>
//#include "../src/Userspace.cpp"
// uint8_t test[] = {
// 0xB8, 0x10,
// 0xB9, 0x10,
// 0x01, 0xC0,
// };
// Userspace user;
TEST(ModRM_C0, ModRM) {
// auto a = user.GetCPUStatus();
// user.Upload2Memory(test, 6);
// user.Run();
//EXPECT_EQ(a.m_Registers[0], 0x20);
EXPECT_EQ(1, 1);
}