AXI Data FIFO Testbench

You can choose to generate the testbench when generating the core in the IP Manager Configuration window. To generate testbench, the Testbench Deliverables Option signals must be enabled.

Note: You must include all .v files generated in the /Testbench directory in your simulation.
Important: tested the testbench generated with the default parameter options only.

provides a simulation script for you to run the testbench quickly using the Modelsim software. To run the Modelsim testbench script, run vsim -do modelsim.do in a terminal application. You must have Modelsim installed on your computer to use this script.

The testbench is set up like an example design, consisting of the following blocks:
  • Custom Master—Main driver and sequencer in the testbench
  • Custom Slave—Provides necessary feedback such as read data and handshake signals to the master through the DUT
  • Generator—Randomly generates the data used for all transactions made by both the custom master and slave
  • Checker—Probes all DUT inputs and outputs, internally performs similar logic to the DUT to predict the outputs, and asserts test_pass signal if the test is completed without any prediction mismatches with the DUT outputs
  • DUTAXI Data FIFO design under test
Figure 1. AXI Data FIFO Top-Level Block Diagram
Table 1. Testbench Files
File Description
tb.v Testbench to generate clock and pass down parameters to top.v.
top.v Top-level wrapper for the DUT environment.
efx_axi_data_fifo_checker.v Probe the DUT’s input and outputs signals to make sure that the data transferred through the data FIFO is consistent with the expected output.
generator.v Generates random data for the master and slave to be used as output for simulation.
efx_axi_master.v A state machine that drives the scenarios used for simulation.
efx_axi_slave.v A slave that acts like a memory and giving response based on the AXI protocol.
efx_crc32.v CRC32 module used by the traffic generator and checker.
efx_fifo_top.<simulator>.v Encrypted FIFO module.
<user_define_name>.v Generated encrypted AXI Data FIFO core file based on user configuration in Efinity IP Manager.