- optimised main emulator loop, allowing updates only once every roughly 32,000 instructions.

- optimised memory access patterns, removing unecessary mutability and accesses.
- replaced the standard HashMap with an implementation that uses a faster hashing algorithm.

results:

before:
    - our benchmark program with ~4m instructions would take around for their data to make it to the UI, and a bit over 200ms to actually run

after:
    - our benchmark program with ~4m instructions can run in around 75ms, and the UI receives the update almost instantly.

conclusion:
- emulator performance should be around 2-3x faster than before.
This commit is contained in:
2025-06-28 03:21:46 +01:00
parent eaaefd1b07
commit 56d2abe17f
8 changed files with 105 additions and 121 deletions
Generated
+3 -2
View File
@@ -783,9 +783,9 @@ dependencies = [
[[package]]
name = "discord-presence"
version = "1.6.0"
version = "2.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f91d7c2fc01ffdc327e2b66d65dd59b8bd3f31a17e88811ce0540412fa0b84c1"
checksum = "91948dab8ccaaefeb7be5f21714ed774411df66830def1f99dd74e7a85f5f111"
dependencies = [
"byteorder",
"bytes",
@@ -1027,6 +1027,7 @@ dependencies = [
"eframe",
"egui",
"egui_file",
"rustc-hash 2.1.1",
"serde",
"toml",
"winit",