Bug 1956103 - Verilator package nonfunctional with F34's GCC 11.
Summary: Verilator package nonfunctional with F34's GCC 11.
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: verilator
Version: 34
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Scott Tsai
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2021-05-02 18:49 UTC by Jake Merdich
Modified: 2021-05-02 18:50 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: ---
Doc Text:
Clone Of:
Last Closed:
Type: Bug

Attachments (Terms of Use)
Output on a fresh F34 machine (2.36 KB, text/plain)
2021-05-02 18:50 UTC, Jake Merdich
no flags Details

System ID Private Priority Status Summary Last Updated
Github verilator verilator pull 2747 0 None closed Include limits header for std::numeric_limits 2021-05-02 18:49:49 UTC

Description Jake Merdich 2021-05-02 18:49:49 UTC
Description of problem:
'Verilated' code does not compile with GCC 11 (default compiler on F34+). 'Verilator' generates c++ code from Verilog code, which is subsequently compiled with GCC/G++. This generated code is missing an `#include <limits>` which means that verilator is mostly nonfunctional on F34 and Rawhide. 

**This was fixed upstream with https://github.com/verilator/verilator/pull/2747, which is probably trivial enough to cherry pick.**

Version-Release number of selected component (if applicable):
verilator-4.108-2.fc34.x86_64 (any 4.108.x works)
gcc-c++-11.1.1-1.fc34.x86_64 (any 11.x works)

How reproducible: 100%

Steps to Reproduce:
1. Install g++ and verilator
2. Create a trivial verilog file 'out.v' (content doesn't really matter, taken from example on verilator docs):

  module our;
     initial begin $display("Hello World"); $finish; end

3. 'Verilate' and compile the file with 'verilator --cc --exe --build our.v'

Actual results:
  Build fails with missing 'std::numeric_limits' (see attached log)

Expected results:
  Build passes and an exe is generated

Additional info:

Comment 1 Jake Merdich 2021-05-02 18:50:53 UTC
Created attachment 1778665 [details]
Output on a fresh F34 machine

Note You need to log in before you can comment on or make changes to this bug.