mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 02:05:57 +01:00
enable basic mozilla rr support
This commit is contained in:
27
README.adoc
27
README.adoc
@@ -9815,6 +9815,33 @@ In graphic mode, make sure that you never click inside the QEMU graphic while de
|
||||
|
||||
You can still send key presses to QEMU however even without the mouse capture, just either click on the title bar, or alt tab to give it focus.
|
||||
|
||||
==== Reverse debug the emulator
|
||||
|
||||
While step debugging any complext program, you always end up feeling the need to step in reverse to reach the last call to some function before the failure point.
|
||||
|
||||
While GDB "has" this feature, it is just too broken to be usable, and so we expose the amazing Mozilla RR tool conveniently in this repo: https://stackoverflow.com/questions/1470434/how-does-reverse-debugging-work/53063242#53063242
|
||||
|
||||
Before the first usage:
|
||||
|
||||
....
|
||||
echo 'kernel.perf_event_paranoid=1' | sudo tee -a /etc/sysctl.conf
|
||||
sudo sysctl -p
|
||||
....
|
||||
|
||||
Then use it as:
|
||||
|
||||
....
|
||||
./run --debug-vm-rr
|
||||
....
|
||||
|
||||
Once you are left in the RR GDB shell, just continue:
|
||||
|
||||
....
|
||||
continue
|
||||
....
|
||||
|
||||
you can now reiably use reverse debugging commands such as `reverse-continue` and `reverse-next`!
|
||||
|
||||
==== Debug gem5 Python scripts
|
||||
|
||||
Start pdb at the first instruction:
|
||||
|
||||
Reference in New Issue
Block a user