Start implementing profiling

This commit is contained in:
2025-08-27 22:49:44 -04:00
parent 6272f6cc21
commit 11c17cb246
5 changed files with 246 additions and 16 deletions
+9
View File
@@ -31,6 +31,9 @@ struct Args {
/// Start a GDB/LLDB debug server on this port.
#[arg(short, long)]
debug_port: Option<u16>,
/// Enable profiling a game
#[arg(short, long)]
profile: bool,
}
fn init_logger() {
@@ -106,6 +109,12 @@ fn main() -> Result<()> {
}
builder = builder.start_paused(true);
}
if args.profile {
if args.rom.is_none() {
bail!("to start profiling, please select a game.");
}
builder = builder.monitor_events(true)
}
ThreadBuilder::default()
.name("Emulator".to_owned())