I'm currently writing a remote debugger, which i plan to share with you soon.
I have peculiar problem,
during debug if application unprepares a context but do not release it, there is no easy way for the debugger to know if context state is changed.
client say stop at line 10 at section x
debugger stops context on line 10.
steps out till function scope end.
application Unprepares function
debugger is not aware of the change it still thinks its in debugging state.
never inform application that debugging is finished, and ignore all other line callbacks because it is already debugging.
i currently actively check if debugged context is unprepared in one of the threads.
which is wasting cpu cycles. that thread would normally be waiting for debug commands to arrive and wake to process them.
i considered these but good not enough,
- depend on application to inform when context is unprepared. This error prone and much greater work needed for debugger integration.
- Check state change when debugger become wakes up again. This happens when client send debug information, or a new lineback. This would cause awkward pause when a function execution is complete.
did you face a similar problem?
what was your solution?
Edited by saejox, 23 October 2012 - 09:42 AM.