2 ms·
Debuggers don't have to halt execution on hitting a breakpoint. They can do other things, like print the contents of memory, letting the host system handle the
by SAI_Peregrinus 6y ago
Debuggers don't have to halt execution on hitting a breakpoint. They can do other things, like print the contents of memory, letting the host system handle the formatting. They're actually usually better for timing-sensitive prints than printf debugging.
That said, most people don't know this is possible (the learning curve issue you mentioned), even though it's an important part of how to use debuggers!
- ShroudedNight 6y agoIn my experience, GDB running commands on a breakpoint is generally much, much slower and more prone to materially changing the timing of things than printf.