FEX-Emu / FEX

A fast usermode x86 and x86-64 emulator for Arm64 Linux
https://fex-emu.com
MIT License
1.99k stars 103 forks source link

Offline Debugging & Performance Analysis tools #495

Open skmp opened 3 years ago

skmp commented 3 years ago

Following up some discussions with @Sonicadvance1

Exposed via FEXLoader

IR dumping to folder

Rationale: We need the data for offline analysis

Per-block support for multiblock in perf symbols

Rationale: Superblocks can have 10s of blocks, it is important to attribute runtime to the hot ones

GuestOp IR op

Rationale: We need to better track Guest - IR - Host relationships to spot optimization opportunities

Add Offline IR compiler

Rationale: Allow us to iterate over a specific block/superblock without having to relaunch the guest application

Tighter perf integration / Perf Explorer

Rationale: We tooling to help us find optimization opportunities and slowdowns, and to also test the "simulated" effects of WIP optimizations


I'd use these as command line utilities in an offline fashion myself.

@Sonicadvance1 @phire, thoughts?

skmp commented 3 years ago

First steps for IR drumping in #500

skmp commented 3 years ago

Note to self: Add a bisection class + script that automates the process via env vars