Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

One problem I have is that I primarily work on embedded distributed systems (multiple software components talking over a high speed messaging layer, using both sockets and shared memory).

As soon as you pause the code in a debugger you "disturb the equilibrium" in such a way that debugging the original problem becomes impossible because remote components start timing out or closing sockets, etc.

I still end up debugging via print statement a lot so I can run the code at full speed. Does anyone have a good tooling suggestion for a situation like this?

My dream is a tool that would allow me to set a breakpoint which would start capturing program state at each line while still running at full speed, but then allow me to step through the recording later. Does something like this exist?



Yes, it's called rr. https://rr-project.org/


This is very cool. Thanks for sharing it.


GDB can kind of do this, you can have commands fire when a breakpoint is hit and continue automatically, and if you want to take it further you can use Python and execute Python code to inspect the state of the CPU and memory in some programmatic way. Not sure if it applies to your target platform, but if it’s ARM it should work.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: