Using ruby-debug with ruby-vpi

Suraj N. Kurapati

Here is one way to use ruby-debug to help debug your ruby-vpi test benches. See the ruby-debug development blog to learn more ways.

  1. Add the following code to the top of your bench.rb file.
require 'ruby-debug'
  1. Add the command debugger in your where you wish to start a debugging session.

Now you have a powerful and fast interactive Ruby debugger at your disposal. The best part is that ruby-debug can be used remotely.

As a result, we can start a ruby-debug server within a ruby-vpi bench and then use a graphical tool for debugging. RadRails is already working towards such a goal for Ruby on Rails.