[logo] 
 
Home
News
Activity
About/Contact
Major Tools
  Dinotrace
  Verilator
  Verilog-mode
  Verilog-Perl
Other Tools
  BugVise
  CovVise
  Force-Gate-Sim
  Gspice
  IPC::Locker
  Rsvn
  Schedule::Load
  SVN::S4
  Synopsys-modes
  SystemPerl
  Verilog-Pli
  Voneline
  Vregs
General Info
  Papers

Best way to debug a segmentation fault in Verilator?

Added by Dimitris Nalbantis about 3 years ago

I am building a model bottom up using Verilator. The main block is composed of 3 main subblocks connected together with some logic. I first Verilated the three subblocks and apart from a few warnings which I eliminated with -W options there does not seem to be any problem converting them to C++. Then I took the top level and verilated it including the three main subblocks (again some warnings had to be disabled) without any obvious problem. In the final step I put the main block in a wrapper block together with a stimulus block that reads the stimulus from a text file and passes it to the main block. At this point Verilator threw a segmentation fault. I used -debug but a lot of data is coming out and haven't got a clue where to start looking. Any ideas/suggestions?


Replies (1)

RE: Best way to debug a segmentation fault in Verilator? - Added by Wilson Snyder about 3 years ago

First run "gdb verilator --debug ..." then at the gdb prompt type "run" then when it crashes "bt".

This'll point to the verilator source line in error. From there you might as well file a bug and we'll debug further. You can also try typing "p fl" or "p nodep->fl"; if the bug is in one of the visitor functions that'll print the verilog source position (if not you'll get a gdb error).

(1-1/1)