openlane2 icon indicating copy to clipboard operation
openlane2 copied to clipboard

Verilator doesn't recognize macros

Open smunaut opened this issue 1 year ago • 1 comments

Description

If you include a macro that has liberty file, yosys will parse the liberty file and know about the macro and its ports just fine. But Verilator won't because it doesn't parse liberty files ...

Expected Behavior

No errors.

Environment report

kernel: Linux
kernel_version: 5.10.0-19-cloud-amd64
supported: True
distro: debian
distro_version: 11
python_version: 3.9.2
python_path:
  - /mnt/pdk/tt-local-harden/venv/bin
  - /usr/lib/python39.zip
  - /usr/lib/python3.9
  - /usr/lib/python3.9/lib-dynload
  - /mnt/pdk/tt-local-harden/venv/lib/python3.9/site-packages
tkinter: True
container_info:
  engine: docker
  version: 27.3.1
  conmon: False
  rootless: False
nix_info:
  version_string: nix (Nix) 2.15.1
  channels:
    nixpkgs: https://nixos.org/channels/nixpkgs-unstable
  nix_command: False
  flakes: False

Reproduction material

n/a

Relevant log output

%Error: /home/runner/work/tt09-atari-2600/tt09-atari-2600/src/tt_um_rejunity_atari2600.v:425:3: Cannot find file containing module: 'rom_2600'
      425 |   rom_2600 rom_I (
          |   ^~~~~~~~
    %Error: /home/runner/work/tt09-atari-2600/tt09-atari-2600/src/tt_um_rejunity_atari2600.v:425:3: This may be because there's no search path specified with -I.
      425 |   rom_2600 rom_I (
          |   ^~~~~~~~
            ... Looked in:
                 rom_2600
                 rom_2600.v
                 rom_2600.sv
                 obj_dir/rom_2600
                 obj_dir/rom_2600.v
                 obj_dir/rom_2600.sv
    %Error: Exiting due to 2 error(s)

smunaut avatar Oct 12 '24 09:10 smunaut

Sorry for the extremely late reply. There's not much we can do about this… except for maybe a lib to verilog converter of some kind.

donn avatar Nov 26 '24 15:11 donn