3 ms·
I've used it for years for vulnerability development (when you need to debug why a particular exploitation run went wrong etc.). It is indeed marvelous for man
by tdullien 2y ago
I've used it for years for vulnerability development (when you need to debug why a particular exploitation run went wrong etc.).
It is indeed marvelous for many situations; except for concurrency bugs ;)
- i_am_a_peasant 2y agoWhy isn't it good for concurrency bugs? rr doesn't record the entire state up to the race condition?
- adgjlsfhk1 2y agoit serializes your problem because you can't atomically snapshot memory when there are multiple threads writing to it
- pm215 2y agoThis is true, but for at least some race conditions the rr "chaos mode" can help in tracking them down. Chaos mode basically randomly adjusts its thread scheduling so that it sometimes doesn't run a thread at all for a few seconds, so you run it a bunch of times until it hits the timing window for the race condition; and then when it does you debug the recording. IME it works at least sometimes but it does require that the thing you're testing doesn't take too long to fall over, since you need to do multiple recordings of it. https://robert.ocallahan.org/2016/02/introducing-rr-chaos-mode.html https://robert.ocallahan.org/2016/02/introducing-rr-chaos-mo...
- nemetroid 2y agoRR supports recording multithreaded programs, but only runs one thread at a time, so it cannot trigger data race bugs. It can find higher level concurrency bugs though, and has a "chaos mode" that schedules threads in an unfair random manner.
- leni536 2y agoIt is sometimes useful with concurreny bugs, especially when used in "chaos" mode. Altough it probably masks some classes of concurrency bugs. I wonder if rr + TSAN works.