Reuse MATLAB Functions in UVM Environments with Automatic SystemVerilog DPI Component Generation

Status
Not open for further replies.

FarhadR

Newbie
Joined
Aug 8, 2022
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
12
I have a problem simulating test benches containing DPI-C imports. Here is a method for reusing MATLAB functional model of the DUT in a SystemVerilog testbench. I downloaded all the code for this example from this address on Mathworks. Then I successfully ran 'build_dpi.m' in MATLAB 2022a with no warnings/errors. Finally, when I run sim.do in Questasim-64 2021.1, I get the following list of warnings:

Code:
# ** Warning: (vsim-3770) Failed to find user specified function 'DPI_fft_checker_initialize' in DPI precompiled library search list ".\codegen/dll/fft_checker/libfft_checker_dpi.dll .\codegen/dll/gen_wave/libgen_wave_dpi.dll C:/questasim64_2021.1/uvm-1.1d\win64\uvm_dpi.dll ".
# ** Warning: (vsim-3770) Failed to find user specified function 'DPI_fft_checker' in DPI precompiled library search list ".\codegen/dll/fft_checker/libfft_checker_dpi.dll .\codegen/dll/gen_wave/libgen_wave_dpi.dll C:/questasim64_2021.1/uvm-1.1d\win64\uvm_dpi.dll ".
# ** Warning: (vsim-3770) Failed to find user specified function 'DPI_gen_wave_initialize' in DPI precompiled library search list ".\codegen/dll/fft_checker/libfft_checker_dpi.dll .\codegen/dll/gen_wave/libgen_wave_dpi.dll C:/questasim64_2021.1/uvm-1.1d\win64\uvm_dpi.dll ".
# ** Warning: (vsim-3770) Failed to find user specified function 'DPI_gen_wave' in DPI precompiled library search list ".\codegen/dll/fft_checker/libfft_checker_dpi.dll .\codegen/dll/gen_wave/libgen_wave_dpi.dll C:/questasim64_2021.1/uvm-1.1d\win64\uvm_dpi.dll ".
Finally, the simulation is aborted with the following error:
Code:
** Fatal: (vsim-160) fft_pkg.sv(120): Null foreign function pointer encountered when calling 'DPI_fft_checker_initialize'
I would highly appreciate some guidance on how to solve this problem. I'm working on integration of my MATLAB models into my SV simulations and I'm stuck here with this problem. Thank you very much
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…