BugHunter Pro and the VeriLogger Simulators

10.3 Building and Running SystemC simulations

10.3 Building and Running SystemC simulations

Previous topic Next topic  

10.3 Building and Running SystemC simulations

Previous topic Next topic  

To compile and run SystemC simulations with BugHunter, you must first compile the systemc.lib library file using your selected C++ compiler (currently we support gcc on Linux and Visual C++ on Windows). Section 10.1: Setting up Visual Studio C++ has the steps for performing this operation on Windows.

First run a SynaptiCAD SystemC Example Project

If you're creating your first SystemC simulation with BugHunter, we recommend you start by opening the SystemC example projects (located in c:\SynaptiCAD\Examples\SystemC directory) and compile and run these examples first. These examples also demonstrate how to properly set the paths to the SystemC include files and library files as needed to compile SystemC simulations. For example:

Choose the Project > Open Project menu and open the andm.hpj file located in the directory:

  C:\SynaptiCAD\Examples\SystemC\andm 

Press the Project Simulations Properties button to open the dialog of the same name.

Pick either the debug or the release configuration appropriate for your OS (either Windows or Unix).

Press the Build button to compile the simulation.

Press the Run button to run the simulation.

After the simulation is complete, choose the File > Open Timing Diagram and open the andm.vcd. You may need to do a full zoom to see the waveforms in the timing diagram window.

Creating your own SystemC Projects

After you've looked at the examples shipped with BugHunter, you're probably ready to create your own SystemC project.

Create a new project by selecting the menu option Project>New Project to open the New Project Wizard.  Leave the language type set to Verilog in the New Project Wizard (this setting only matters when creating test benches).

After the project window appears, add your SystemC source code files to the User Source Files folder.

Then select the menu option Project > Project Simulation Properties and click the C++ tab in the dialog to set your compilation options. As a starting point, copy the Include Directories, Library Directories, Compile, and Linker settings from one of the SystemC examples into your project.

Important Note: If you plan on creating several SystemC simulation, you'll probably want to copy these compilation settings to your Settings Template (radio button at the top of the Project Simulation Properties dialog) so that future C++ projects will automatically get the appropriate settings.