Forum Discussion

jmitrevs's avatar
jmitrevs
Icon for New Contributor rankNew Contributor
4 years ago

modelsim.ini used when running vlog in i++ compilation for cosimulation.

When compiling HLS with i++ -fpga-only testfile.o , is it possible to pass a modelsim.ini that’s used for the vlog compilations?

7 Replies

  • Hi,

    I did not get the question, can you briefly explain what that is you are trying to achieve?

  • jmitrevs's avatar
    jmitrevs
    Icon for New Contributor rankNew Contributor

    Hi,

    Actually I think the modelsim.ini file may be tangential to the problem. The issue that I have is that the vlog command used internally by i++ in the testbench creation phase sometimes cannot find included svh files. It seems like if I work in my home directory it can find includes but on the data drive it cannot, and I cannot explain it. Here is a simple example with a verilog file implementing an AND gate and an include file that defines FOO (which is unused). There are only two files in the directory to start, simple.sv and simple.svh.

    [jmitrevs@correlator4 ~]$ cp -r vlog_test /data/jmitrevs/
    [jmitrevs@correlator4 ~]$ cd vlog_test/
    [jmitrevs@correlator4 vlog_test]$ vlog +incdir+. simple.sv
    Model Technology ModelSim - Intel FPGA Edition vlog 2020.3 Compiler 2020.07 Jul 22 2020
    Start time: 16:42:39 on May 10,2021
    vlog "+incdir+." simple.sv
    -- Compiling module andgateTop level modules:
    andgate
    End time: 16:42:39 on May 10,2021, Elapsed time: 0:00:00
    Errors: 0, Warnings: 0
    [jmitrevs@correlator4 vlog_test]$ cd /data/jmitrevs/vlog_test/
    [jmitrevs@correlator4 vlog_test]$ vlog +incdir+. simple.sv
    Model Technology ModelSim - Intel FPGA Edition vlog 2020.3 Compiler 2020.07 Jul 22 2020
    Start time: 16:42:56 on May 10,2021
    vlog "+incdir+." simple.sv
    ** Error: simple.sv(1): Cannot open `include file "./simple.svh".
    -- Compiling module andgate
    End time: 16:42:56 on May 10,2021, Elapsed time: 0:00:00
    Errors: 1, Warnings: 0

    Jovan

      • jmitrevs's avatar
        jmitrevs
        Icon for New Contributor rankNew Contributor

        My current thinking is that Modelsim, being a 32-bit program, is having trouble being installed on a very large hard drive. When I reinstalled Modelsim to a smaller hard drive, this problem seems to go away.

        Next problem:

        # ** Error: (vsim-3) System call 'mmap()' failed.
        # Permission denied. (errno = EACCES)
        # End time: 13:57:31 on May 03,2021, Elapsed time: 0:02:19
        # Errors: 1, Warnings: 6475
        ** Fatal: vsimk is exiting with code 9.