lowRISC / lowRISC/opentitan

[SYNTHESIS] May remove xilinx primitive from general filelist?

Open
#29,241 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
SystemVerilog
Stars
3.6k
Forks
1.1k
Avg merge
2d 22h
Merged PRs (30d)
141

Description

Description

When I used syn step, I got this error

Error:  ../src/lowrisc_prim_xilinx_ram_1p_0/rtl/prim_xilinx_ram_1p.sv:48: The construct 'string' is not supported in synthesis. (VER-700)
Compiling source file ../src/lowrisc_prim_abstract_flop_en_0/prim_flop_en.sv
Error:  Cannot recover from previous errors. (VER-518)
*** Presto compilation terminated with 2 errors. ***

The solution is straightforward: remove all Xilinx prims from the filelist and use generic prims for synthesis. However, I have two questions out of curiosity:

  1. How can I manually eliminate the dependency on Xilinx prims in the filelist generation step during synthesis?
  2. Why are Xilinx prims added to the general dependencies when they are only used in implementations targeting Xilinx FPGAs? I don’t think they should be included even for simulation, and in fact, they are never actually used at all—the code never takes this branch.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the synthesis filelist generation that includes src/lowrisc_prim_xilinx_ram_1p_0/rtl/prim_xilinx_ram_1p.sv, then compare it with the generic primitives used by synthesis. Done means the synthesis filelist excludes Xilinx primitives, uses the generic alternatives, and no longer reports the unsupported string construct or compilation failure.

Written by the indexing model from the issue text.

Assessment

Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.