Transaction analysis on xbus design using Questa 10.0c

Hi,

I’m looking at the xbus example that ships with the standard OVM distribution. The simulator I’m using is Questa version 10.0c.

I’d like to trace the transactions going on between the sequencer and the driver in the master agent. Questa has a facility that allows the user to specify transaction streams and transactions that take place on these streams. In order to do this the code has to be instrumented with API calls. I’ve tried to instrument the xbus_master_driver.svh code with these calls, but Questa then denies any knowledge of the transaction stream I’ve defined.

Here’s how I instrumented the xbus_master_driver.svh code. I defined the following class properties :
int stream_h;
int transaction_h;

Then in the driver’s constructor I’m creating the stream :
function new (string name, ovm_component parent);

stream_h = $create_transaction_stream(“MasterDriver”);

In the task that does the actual driving work I’m attempting to add the salient request information (as represented here by the number 10 for simplicity) to the stream that I created :
virtual protected task get_and_drive();

transaction_h = $begin_transaction(stream_h, “Request”);
$add_attribute(transaction_h, 10, “address”);

I then start the simulation and run it to the end. As far as I understand it the command
add wave MasterDriver
should add my the MasterDriver transaction stream to the waveform window. Instead Questa tells me :

(vish-4014) No objects found matching ‘MasterDriver’.

Any ideas anyone?

Cheers,

Carsten

The quickest way to find the stream is to run your simulation in batch mode - you don’t need to do any add wave.

Then when your simulation finishes, do a ‘vsim -view vsim.wlf’ to open the WLF file in view mode. Do a ‘add wave -r /*’. You should see your streams.

Now, if you want to view your streams during simulation, you can add wave those names in live simulation. (Remember to do this ‘add wave’ after the streams have been created).

rich

Hi Rich,

thanks very much, that worked a treat!

I wasn’t able to record the data field of the transaction because it’s a dynamic array, which is a “non log-able item”. Are there any workarounds for that?

Cheers,

Carsten