Graphical debugger for the rubyx register machine
Go to file
2015-10-27 18:09:50 +02:00
assets/css update salaam 2015-10-27 12:46:39 +02:00
codes change to same file ending 2015-10-27 18:09:24 +02:00
config yanked diy branch to master 2015-08-25 12:37:29 +02:00
lib showing integers correctly 2015-10-27 18:09:50 +02:00
spec/app/main/integration try to get object recursion going 2015-08-16 10:01:12 +03:00
static better documentation 2015-10-07 12:24:02 +03:00
.gitignore volt new overlay 2015-07-29 17:26:04 +03:00
config.ru change to same file ending 2015-10-27 18:09:24 +02:00
Gemfile update salaam 2015-10-22 14:44:00 +03:00
Gemfile.lock showing integers correctly 2015-10-27 18:09:50 +02:00
index.html.erb revived the styles 2015-08-20 02:14:33 +02:00
README.md virtual - register update 2015-10-27 12:44:02 +02:00

Debugger

After some tryouts it ended up being an Opal application. That is ruby as javascript in the browser.

Debugger

  • On the left are the classes of the system. Next idea is to have hover info about them.
  • Next a source code view (not implemented)
  • next a view of the Register Instructions
  • last section, current block with current Register Instruction highlighted
  • step (next) button for single stepping
  • state: starting , running , exited
  • bottom row are the registers. If the register holds an object the variables are shown.

Register View

The Register view is now greatly improved, especially in it's dynamic features:

  • when the contents update the register obviously updates
  • when the object that the register holds updates, the new value is shown immediately
  • hovering over a variable will expand that variable .
  • the hovering works recursively, so it is possible to drill pdown into objects for sevaral levels

Debugging the debugger

Opal is pre 1.0 and is a wip. While current source map support is quite good, one only gets real lines when switching debug on. Debug make it load every single file seperately, slooows it down in other words. Set DEBUG environement to swithc it on.

I set the sprockets cache to mem-cache and that increase load time from 12s to 1 , so it's quite usable and restarting a debug is fine.

Todos

Currently only one source is supported. I change the code.rb file to debug a new problem.

Parsing (parslet) does not work in opal. So s-expressions are used. I use the parser or interpreter to spew those out. Having a dropdown would be nice, and not even so difficult, but it happens rarely.

Breakpoints would be nice at some point. Both in step count and variable value.

Seeing the source code should be possible, just have to keep it around.