Project

General

Profile

[logo] 
 
Home
News
Activity
About/Contact
Major Tools
  Dinotrace
  Verilator
  Verilog-mode
  Verilog-Perl
Other Tools
  BugVise
  CovVise
  Force-Gate-Sim
  Gspice
  IPC::Locker
  Rsvn
  SVN::S4
  Voneline
  WFH
General Info
  Papers

fst_time_unit.patch

Pieter Kapsenberg, 05/12/2019 04:58 AM

Download (1.43 KB)

View differences:

include/verilated_fst_c.h
77 77
        fstWriterClose(m_fst);
78 78
        m_fst = NULL;
79 79
    }
80
    // void set_time_unit(const char* unitp);  ///< Set time units (s/ms, defaults to ns)
80
    void set_time_unit(const char* unitp) { fstWriterSetTimescaleFromString(m_fst, unitp); }
81 81
    // void set_time_unit(const std::string& unit) { set_time_unit(unit.c_str()); }
82 82

  
83 83
    // void set_time_resolution(const char* unitp);  ///< Set time resolution (s/ms, defaults to ns)
......
216 216
    void dump(int timestamp) { dump(static_cast<vluint64_t>(timestamp)); }
217 217
    /// Set time units (s/ms, defaults to ns)
218 218
    /// See also VL_TIME_PRECISION, and VL_TIME_MULTIPLIER in verilated.h
219
    void set_time_unit(const char* unit) { /* TODO */ }
219
    void set_time_unit(const char* unit) { m_sptrace.set_time_unit(unit); }
220 220
    void set_time_unit(const std::string& unit) { set_time_unit(unit.c_str()); }
221 221
    /// Set time resolution (s/ms, defaults to ns)
222 222
    /// See also VL_TIME_PRECISION, and VL_TIME_MULTIPLIER in verilated.h
223
    void set_time_resolution(const char* unit) { /* TODO */ }
223
    void set_time_resolution(const char* unit) { /* TODO */ (void)unit; }
224 224
    void set_time_resolution(const std::string& unit) { set_time_resolution(unit.c_str()); }
225 225

  
226 226
    /// Internal class access