leonardt / fault

A Python package for testing hardware (part of the magma ecosystem)
BSD 3-Clause "New" or "Revised" License
41 stars 13 forks source link

Explicitly set integer literal size in SV backend #107

Closed leonardt closed 5 years ago

leonardt commented 5 years ago

Fixes issue introduced in https://github.com/StanfordAHA/lassen/pull/95 where a 66 bit constant value was generated in system verilog and ncsim complained with:

inst = 21040819108348690454;
--
  | \|
  | ncvlog: *W,INTOVF (WrappedPE_tb.sv,37\|34): bit overflow during conversion from text [2.5(IEEE)] (32 bits).

This changes the system verilog backend to always emit the size of the integer literal using the <size>'d<value> syntax.

coveralls commented 5 years ago

Pull Request Test Coverage Report for Build 950


Changes Missing Coverage Covered Lines Changed/Added Lines %
fault/system_verilog_target.py 0 4 0.0%
<!-- Total: 0 4 0.0% -->
Totals Coverage Status
Change from base Build 945: -0.1%
Covered Lines: 1368
Relevant Lines: 1794

💛 - Coveralls