-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Design a command language for interactive commandline / TUI rakudo-moarvm debugger #456
Labels
moarvm
Big changes to MoarVM
Comments
lizmat
added
moarvm
Big changes to MoarVM
and removed
fallback
If no other label fits
labels
Dec 7, 2024
The following is an unfinished brain-dump. It's missing aspects and commands and it does not tick all the boxes (e.g. allow more than one command per line) and it's biased (obviously). But I wanted to put it out now so we have something to shot down and to find out if the direction I'm thinking is right. Some major topics of debugging: Control execution
Repeating previous debugging runs
Inspect the current state of execution
Commands
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The command language for App::MoarVM::Debug is currently ad-hoc, counter-intuitive, requires lots of typing to do relatively simple tasks, doesn't handle errors like typos sensibly, doesn't allow more than one command per line, and many more issues.
Here is the "help" output from the current iteration of the language, if you can call it that:
https://github.com/raku-community-modules/App-MoarVM-Debug/blob/9b0bea317fd992bc82d8a484df829032c6f0756c/lib/App/MoarVM/Debug.rakumod#L77-L181
This Problem Solving issue has the goal of writing a kind of command language that makes debugging more pleasant.
Here are properties for a command language to be used in a CLI debugger (but also available in TUI and GUI debuggers for power users?):
There are some things that make stealing liberally from, for example GDB, difficult:
You can not attach the moar remote to a process that hasn't been started with the debug port activated. We also now have an nqp::syscall(...) that can tell you if the debugger is on, so in theory, built-in classes can do some extra work when we have the debugger attached.
It already has a performance impact anyway, so if we do something like "for every Promise created, also store a traceback" it may be an acceptable price if we can benefit from the information in the debugger.
The text was updated successfully, but these errors were encountered: