Sign in

    minivcd_mbt

    A lightweight VCD waveform parser and CLI written in MoonBit.

    vcd
    verilog
    waveform
    parser
    cli
    Download zip
    Version
    0.1.6
    License
    MIT
    Last updated
    last month
    Downloads
    30

    Dependencies

    #MiniVCD-MBT

    A lightweight VCD waveform parser and CLI written in MoonBit.

    MiniVCD-MBT reads a Value Change Dump file, extracts digital signal declarations and value changes, and provides small command-line queries and CSV export. It is intentionally a focused parser/viewer rather than a full EDA application.

    #Features

    • VCD header parsing ($date, $version, $timescale)
    • Hierarchical signals from $scope and $upscope
    • Four-state scalar values (0, 1, x, z)
    • Binary vectors
    • Signal lookup, change history, and point-in-time value queries
    • Change count and basic rising/falling edge statistics
    • File summary and identifier-based query helpers
    • Signal descriptors, scope/type filtering, snapshots, timestamp buckets, and coverage summaries
    • Parsed-data validation diagnostics
    • Markdown and plain-text reports
    • VCD-to-VCD regression comparison for signal sets, timestamps, and values
    • CSV export
    • Single-signal CSV export
    • Six-command CLI

    #Installation

    Install a current MoonBit toolchain, then build the project:

    moon update moon build --target native

    During development, run the CLI directly with moon run cmd/minivcd -- .... After the package is published, library users can install it with:

    moon add alicedhaha/minivcd_mbt

    #Usage

    Show file metadata:

    moon run cmd/minivcd -- info examples/demo.vcd

    List signals:

    moon run cmd/minivcd -- signals examples/demo.vcd

    Show one signal's changes:

    moon run cmd/minivcd -- changes examples/demo.vcd top.clk

    Show one signal's statistics:

    moon run cmd/minivcd -- stats examples/demo.vcd top.clk

    Query the most recent value at or before a timestamp:

    moon run cmd/minivcd -- value examples/demo.vcd top.counter 20

    Export all changes:

    moon run cmd/minivcd -- export examples/demo.vcd output.csv

    The standalone executable uses the same commands with the shorter form minivcd <command> ....

    #Library Example

    Add alicedhaha/minivcd_mbt to the consuming package's moon.pkg, then call the parser and query API:

    let text =
    #|$timescale 1ns $end
    #|$scope module top $end
    #|$var wire 1 ! clk $end
    #|$upscope $end
    #|$enddefinitions $end
    #|#0 0!
    #|#5 1!

    let vcd = @minivcd_mbt.parse_vcd(text) catch { _ => panic() }
    let value = @minivcd_mbt.value_at(vcd, "top.clk", 5L) catch { _ => panic() }
    assert_eq(value, Some("1"))

    The main public functions are parse_vcd/parse, list_signals, find_signal, find_signal_by_identifier, signal_changes, signal_changes_by_identifier, value_at, summary, signal_stats, export_csv, and export_signal_csv.

    #Supported Features

    • Basic VCD headers and unknown skippable header commands
    • Simple module hierarchy
    • wire, reg, and other declared signal type names as metadata
    • Scalar digital changes
    • Binary vector changes
    • Non-negative timestamps
    • $dumpvars, $dumpall, $dumpon, and $dumpoff blocks
    • Point-in-time snapshots and timestamp buckets
    • Parsed-data validation, signal coverage summaries, Markdown reports, and VCD regression comparison helpers

    Malformed input raises a readable VcdError; normal input errors do not panic.

    #Limitations

    MiniVCD-MBT does not support:

    • FSDB or FST files
    • Verilog/SystemVerilog compilation or simulation
    • A waveform GUI or waveform drawing
    • Real/string signal advanced processing
    • Streaming very large files
    • Clock frequency, duty-cycle, jitter, glitch, or activity analysis

    #Testing

    Run all tests with:

    moon test

    The repository currently includes 240 tests covering parser behavior, malformed inputs, scalar/vector values, query APIs, statistics, CSV export, diagnostics, snapshots, coverage summaries, Markdown reports, and VCD comparison helpers.

    For stricter local validation:

    moon check --deny-warn moon test --deny-warn

    #Contest Notes

    This repository is an original MoonBit implementation. The GitHub account alicedhaha and the GitLink account alicedhh both belong to the same contestant, Huang Donghong; the different names are only platform nicknames.

    #License

    MIT

    VcdError

    pub(all) suberror VcdError {
    VcdError(String)
    } derive(
    Debug
    )

    A readable parse or query error. The library raises this instead of panicking on malformed VCD input or an invalid query.

    LogicCounts

    pub(all) struct LogicCounts {
    zeros : Int
    ones : Int
    unknowns : Int
    high_impedances : Int
    width : Int
    } derive(Eq,
    Debug
    )

    Per-character counts for a scalar or vector logic value.

    RenderOptions

    pub(all) struct RenderOptions {
    include_header : Bool
    include_empty_values : Bool
    separator : String
    } derive(Eq,
    Debug
    )

    A text rendering option bundle for CLI-style library reports.

    Signal

    pub(all) struct Signal {
    identifier : String
    name : String
    full_name : String
    width : Int
    signal_type : String
    } derive(Eq,
    Debug
    )

    A signal declared in the VCD header.

    SignalChange

    pub(all) struct SignalChange {
    timestamp : Int64
    identifier : String
    value : String
    } derive(Eq,
    Debug
    )

    One value change associated with a VCD identifier.

    SignalCoverage

    pub(all) struct SignalCoverage {
    full_name : String
    has_value : Bool
    first_change_time : Int64?
    last_change_time : Int64?
    change_count : Int
    transition_count : Int
    unknown_change_count : Int
    high_impedance_change_count : Int
    } derive(Eq,
    Debug
    )

    A per-signal coverage summary for review and diagnostics.

    SignalDescriptor

    pub(all) struct SignalDescriptor {
    identifier : String
    name : String
    full_name : String
    width : Int
    signal_type : String
    scope : String
    is_scalar : Bool
    is_vector : Bool
    } derive(Eq,
    Debug
    )

    A normalized signal declaration summary suitable for reports.

    SignalMatch

    pub(all) struct SignalMatch {
    signal : Signal
    reason : String
    } derive(Eq,
    Debug
    )

    A search result produced by name, scope, type, or identifier queries.

    SignalSetDiff

    pub(all) struct SignalSetDiff {
    common : Array[String]
    left_only : Array[String]
    right_only : Array[String]
    width_mismatches : Array[String]
    type_mismatches : Array[String]
    } derive(Eq,
    Debug
    )

    Difference between the signal declarations of two parsed VCD files.

    SignalStats

    pub(all) struct SignalStats {
    change_count : Int
    first_change_time : Int64?
    last_change_time : Int64?
    rising_edges : Int
    falling_edges : Int
    } derive(Eq,
    Debug
    )

    Basic activity statistics for one signal.

    SignalTransition

    pub(all) struct SignalTransition {
    timestamp : Int64
    previous : String
    current : String
    } derive(Eq,
    Debug
    )

    A transition between two consecutive known values of one signal.

    SignalValue

    pub(all) struct SignalValue {
    signal : Signal
    value : String?
    } derive(Eq,
    Debug
    )

    One signal value observed at a selected timestamp.

    TimeWindow

    pub(all) struct TimeWindow {
    start_time : Int64
    end_time : Int64
    } derive(Eq,
    Debug
    )

    A query window over VCD timestamps.

    TimestampBucket

    pub(all) struct TimestampBucket {
    timestamp : Int64
    changes : Array[SignalChange]
    } derive(Eq,
    Debug
    )

    A compact report of one timestamp and the changes that happened there.

    TimestampDiff

    pub(all) struct TimestampDiff {
    common : Array[Int64]
    left_only : Array[Int64]
    right_only : Array[Int64]
    } derive(Eq,
    Debug
    )

    Timestamp presence difference between two parsed VCD files.

    ValueCount

    pub(all) struct ValueCount {
    value : String
    count : Int
    } derive(Eq,
    Debug
    )

    Count of a concrete value in a signal change history.

    ValueDiff

    pub(all) struct ValueDiff {
    timestamp : Int64
    full_name : String
    left : String?
    right : String?
    } derive(Eq,
    Debug
    )

    Value difference for one signal at one timestamp.

    ValueSpan

    pub(all) struct ValueSpan {
    start_time : Int64
    end_time : Int64?
    value : String
    } derive(Eq,
    Debug
    )

    A half-open time interval over which a signal keeps the same value.

    VcdDiff

    pub(all) struct VcdDiff {
    signal_diff : SignalSetDiff
    timestamp_diff : TimestampDiff
    value_diffs : Array[ValueDiff]
    } derive(Eq,
    Debug
    )

    Compact comparison between two parsed VCD files.

    VcdFile

    pub(all) struct VcdFile {
    date : String
    version : String
    timescale : String
    signals : Array[Signal]
    changes : Array[SignalChange]
    } derive(Eq,
    Debug
    )

    Parsed VCD metadata, declarations, and value changes.

    VcdHealth

    pub(all) struct VcdHealth {
    signal_count : Int
    scalar_signal_count : Int
    vector_signal_count : Int
    change_count : Int
    unknown_value_change_count : Int
    high_impedance_change_count : Int
    issue_count : Int
    } derive(Eq,
    Debug
    )

    Counts of scalar/vector/unknown-state signals and changes.

    VcdIssue

    pub(all) struct VcdIssue {
    code : String
    message : String
    timestamp : Int64?
    signal : String?
    } derive(Eq,
    Debug
    )

    A validation issue discovered after parsing a VCD file.

    VcdSnapshot

    pub(all) struct VcdSnapshot {
    timestamp : Int64
    values : Array[SignalValue]
    } derive(Eq,
    Debug
    )

    A point-in-time view of every declared signal.

    VcdSummary

    pub(all) struct VcdSummary {
    signal_count : Int
    change_count : Int
    start_time : Int64?
    end_time : Int64?
    } derive(Eq,
    Debug
    )

    File-level counts and time bounds.

    all_signal_coverage

    fn all_signal_coverage(vcd : VcdFile) -> Array[SignalCoverage] raise VcdError

    Return coverage summaries for all declared signals.

    binary_value_to_int64

    fn binary_value_to_int64(value : String) -> Int64?

    Convert a known binary value to Int64 when it fits.

    change_count_at_timestamp

    fn change_count_at_timestamp(vcd : VcdFile, timestamp : Int64) -> Int

    Count changes that happened at one timestamp.

    change_count_in_window

    fn change_count_in_window(vcd : VcdFile, window : TimeWindow) -> Int raise VcdError

    Count all changes inside an inclusive time window.

    changes_at_timestamp

    fn changes_at_timestamp(vcd : VcdFile, timestamp : Int64) -> Array[SignalChange]

    Return changes that occurred at one timestamp.

    changes_in_window

    fn changes_in_window(vcd : VcdFile, window : TimeWindow) -> Array[SignalChange] raise VcdError

    Return all changes in an inclusive time window.

    classify_value

    fn classify_value(value : String) -> String

    Return a compact textual classification of a parsed value.

    compare_and_render

    fn compare_and_render(left : VcdFile, right : VcdFile) -> String raise VcdError

    compare_and_render_markdown

    fn compare_and_render_markdown(left : VcdFile, right : VcdFile) -> String raise VcdError

    compare_signal_sets

    fn compare_signal_sets(left : VcdFile, right : VcdFile) -> SignalSetDiff

    compare_timestamps

    fn compare_timestamps(left : VcdFile, right : VcdFile) -> TimestampDiff

    compare_values_at

    fn compare_values_at(left : VcdFile, right : VcdFile, timestamp : Int64) -> Array[ValueDiff] raise VcdError

    compare_values_on_union_timeline

    fn compare_values_on_union_timeline(left : VcdFile, right : VcdFile) -> Array[ValueDiff] raise VcdError

    compare_vcd

    fn compare_vcd(left : VcdFile, right : VcdFile) -> VcdDiff raise VcdError

    comparison_manifest

    fn comparison_manifest(diff : VcdDiff) -> String

    count_signals_by_type

    fn count_signals_by_type(vcd : VcdFile, signal_type : String) -> Int

    Count declarations of a given VCD signal type such as wire or reg.

    count_value

    fn count_value(vcd : VcdFile, full_name : String, value : String) -> Int raise VcdError

    Count writes of a concrete value for a signal.

    count_value_diffs_at

    fn count_value_diffs_at(left : VcdFile, right : VcdFile, timestamp : Int64) -> Int raise VcdError

    covered_signal_count

    fn covered_signal_count(vcd : VcdFile) -> Int raise VcdError

    Count signals with at least one value.

    default_render_options

    fn default_render_options() -> RenderOptions

    Return the default text-rendering options used by the report helpers.

    describe_signal

    fn describe_signal(signal : Signal) -> SignalDescriptor

    Build a normalized descriptor for one signal declaration.

    describe_signals

    fn describe_signals(vcd : VcdFile) -> Array[SignalDescriptor]

    Build descriptors for every declared signal in source order.

    distinct_values

    fn distinct_values(vcd : VcdFile, full_name : String) -> Array[String] raise VcdError

    Return all distinct values written to a signal.

    end_time

    fn end_time(vcd : VcdFile) -> Int64?

    Latest timestamp in the file, if any changes exist.

    export_csv

    fn export_csv(vcd : VcdFile) -> String raise VcdError

    Export all parsed changes in timestamp,signal,value form.

    export_signal_csv

    fn export_signal_csv(vcd : VcdFile, full_name : String) -> String raise VcdError

    Export one signal in timestamp,signal,value form.

    file_high_impedance_change_count

    fn file_high_impedance_change_count(vcd : VcdFile) -> Int

    Count all changes whose value contains z.

    file_unknown_change_count

    fn file_unknown_change_count(vcd : VcdFile) -> Int

    Count all changes whose value contains x.

    find_signal

    fn find_signal(vcd : VcdFile, full_name : String) -> Signal?

    Find a signal by hierarchical full name.

    find_signal_by_identifier

    fn find_signal_by_identifier(vcd : VcdFile, identifier : String) -> Signal?

    Find a signal by raw VCD identifier.

    first_change_at_or_after

    fn first_change_at_or_after(vcd : VcdFile, full_name : String, timestamp : Int64) -> SignalChange? raise VcdError

    Return the first change at or after a timestamp.

    first_time_in_window

    fn first_time_in_window(vcd : VcdFile, window : TimeWindow) -> Int64? raise VcdError

    Return the first timestamp in a window, if the file has any matching change.

    first_value

    fn first_value(vcd : VcdFile, full_name : String) -> String? raise VcdError

    Return the first parsed value of a signal.

    first_value_diff

    fn first_value_diff(left : VcdFile, right : VcdFile) -> ValueDiff? raise VcdError

    hamming_distance

    fn hamming_distance(left : String, right : String) -> Int?

    Count bit positions that differ between two equal-width known or four-state values.

    has_high_impedance_bit

    fn has_high_impedance_bit(value : String) -> Bool

    Return true when a value has any high-impedance bit.

    has_unknown_bit

    fn has_unknown_bit(value : String) -> Bool

    Return true when a value has any unknown bit.

    health

    fn health(vcd : VcdFile) -> VcdHealth

    Build a compact health summary from declarations, changes, and validation.

    high_impedance_bit_count

    fn high_impedance_bit_count(value : String) -> Int

    Count high-impedance bits in a scalar or vector value.

    high_impedance_change_count

    fn high_impedance_change_count(vcd : VcdFile, full_name : String) -> Int raise VcdError

    Count changes for a signal whose value contains z.

    is_known_binary

    fn is_known_binary(value : String) -> Bool

    Return true when a value contains only known binary bits.

    is_scalar_logic_value

    fn is_scalar_logic_value(value : String) -> Bool

    Return true when the value is exactly one scalar logic character.

    is_valid_vcd

    fn is_valid_vcd(vcd : VcdFile) -> Bool

    Return true when validate_vcd finds no issues.

    is_vector_logic_value

    fn is_vector_logic_value(value : String) -> Bool

    Return true when the value has more than one valid logic character.

    last_change_at_or_before

    fn last_change_at_or_before(vcd : VcdFile, full_name : String, timestamp : Int64) -> SignalChange? raise VcdError

    Return the last change at or before a timestamp.

    last_time_in_window

    fn last_time_in_window(vcd : VcdFile, window : TimeWindow) -> Int64? raise VcdError

    Return the last timestamp in a window, if the file has any matching change.

    last_value

    fn last_value(vcd : VcdFile, full_name : String) -> String? raise VcdError

    Return the last parsed value of a signal.

    list_signals

    fn list_signals(vcd : VcdFile) -> Array[Signal]

    Return the declared signals in source order.

    logic_counts

    fn logic_counts(value : String) -> LogicCounts

    Return per-character counts for one value.

    manifest_line

    fn manifest_line(vcd : VcdFile) -> String

    Render a plain one-line manifest useful for logs.

    markdown_buckets

    fn markdown_buckets(vcd : VcdFile) -> String

    Render a timestamp-bucket overview as Markdown.

    markdown_changes

    fn markdown_changes(vcd : VcdFile) -> String

    Render all parsed changes as a Markdown table.

    markdown_coverage

    fn markdown_coverage(vcd : VcdFile) -> String raise VcdError

    Render coverage summaries for all signals as Markdown.

    markdown_issues

    fn markdown_issues(vcd : VcdFile) -> String

    Render validation issues as Markdown.

    markdown_report

    fn markdown_report(vcd : VcdFile) -> String raise VcdError

    Render a compact Markdown report covering the most useful library outputs.

    markdown_signal_changes

    fn markdown_signal_changes(vcd : VcdFile, full_name : String) -> String raise VcdError

    Render one signal's changes as a Markdown table.

    markdown_signal_set_diff

    fn markdown_signal_set_diff(diff : SignalSetDiff) -> String

    markdown_signal_stats

    fn markdown_signal_stats(vcd : VcdFile, full_name : String) -> String raise VcdError

    Render basic statistics for one signal as Markdown.

    markdown_signals

    fn markdown_signals(vcd : VcdFile) -> String

    Render all signal declarations as a Markdown table.

    markdown_snapshot

    fn markdown_snapshot(snapshot : VcdSnapshot) -> String

    Render a snapshot as a Markdown table.

    markdown_summary

    fn markdown_summary(vcd : VcdFile) -> String

    Render a Markdown summary section for the parsed file.

    markdown_timestamp_diff

    fn markdown_timestamp_diff(diff : TimestampDiff) -> String

    markdown_value_counts

    fn markdown_value_counts(vcd : VcdFile, full_name : String) -> String raise VcdError

    Render one signal's value-count table as Markdown.

    markdown_value_diffs

    fn markdown_value_diffs(diffs : Array[ValueDiff]) -> String

    markdown_vcd_diff

    fn markdown_vcd_diff(diff : VcdDiff) -> String

    one_bit_count

    fn one_bit_count(value : String) -> Int

    Count ones in a scalar or vector value.

    parse

    fn parse(text : String) -> VcdFile raise VcdError

    Short alias for parse_vcd.

    parse_vcd

    fn parse_vcd(text : String) -> VcdFile raise VcdError

    Parse a complete VCD document held in memory.

    render_buckets

    fn render_buckets(vcd : VcdFile) -> String

    Render timestamp buckets.

    render_change

    fn render_change(vcd : VcdFile, change : SignalChange) -> String

    Render one value change using the signal full name when possible.

    render_coverage

    fn render_coverage(vcd : VcdFile) -> String raise VcdError

    Render signal coverage summaries.

    render_health

    fn render_health(vcd : VcdFile) -> String

    Render a health summary intended for human-readable diagnostics.

    render_info

    fn render_info(vcd : VcdFile) -> String

    Render file summary in the same style as the CLI info command.

    render_issues

    fn render_issues(issues : Array[VcdIssue]) -> String

    Render validation issues, one per line.

    render_signal

    fn render_signal(signal : Signal) -> String

    Render one signal declaration as a compact text line.

    render_signal_changes

    fn render_signal_changes(vcd : VcdFile, full_name : String) -> String raise VcdError

    Render one signal's change history.

    render_signal_set_diff

    fn render_signal_set_diff(diff : SignalSetDiff) -> String

    render_signals

    fn render_signals(vcd : VcdFile) -> String

    Render the declared signal table.

    render_snapshot

    fn render_snapshot(snapshot : VcdSnapshot, options : RenderOptions) -> String

    Render one snapshot as text.

    render_timeline

    fn render_timeline(vcd : VcdFile, options : RenderOptions) -> String raise VcdError

    Render all snapshots at recorded timestamps.

    render_timestamp_diff

    fn render_timestamp_diff(diff : TimestampDiff) -> String

    render_value_counts

    fn render_value_counts(vcd : VcdFile, full_name : String) -> String raise VcdError

    Render value counts for one signal.

    render_value_diff

    fn render_value_diff(diff : ValueDiff) -> String

    render_value_diffs

    fn render_value_diffs(diffs : Array[ValueDiff]) -> String

    render_vcd_diff

    fn render_vcd_diff(diff : VcdDiff) -> String

    scalar_signals

    fn scalar_signals(vcd : VcdFile) -> Array[Signal]

    Return one-bit signals.

    search_signals

    fn search_signals(vcd : VcdFile, text : String) -> Array[SignalMatch]

    Search signals by a text fragment in full name, short name, identifier, or type.

    signal_changes

    fn signal_changes(vcd : VcdFile, full_name : String) -> Array[SignalChange] raise VcdError

    Get every change for a signal selected by full name.

    signal_changes_by_identifier

    fn signal_changes_by_identifier(vcd : VcdFile, identifier : String) -> Array[SignalChange] raise VcdError

    Get every change for a signal selected by VCD identifier.

    signal_changes_in_window

    fn signal_changes_in_window(vcd : VcdFile, full_name : String, window : TimeWindow) -> Array[SignalChange] raise VcdError

    Return changes inside an inclusive time window.

    signal_changes_inside_window

    fn signal_changes_inside_window(vcd : VcdFile, full_name : String, window : TimeWindow) -> Bool raise VcdError

    Return true if a signal changes inside an inclusive time window.

    signal_coverage

    fn signal_coverage(vcd : VcdFile, full_name : String) -> SignalCoverage raise VcdError

    Summarize how completely one signal is covered by changes.

    signal_full_names

    fn signal_full_names(vcd : VcdFile) -> Array[String]

    Return full hierarchical names in declaration order.

    signal_has_changes

    fn signal_has_changes(vcd : VcdFile, full_name : String) -> Bool raise VcdError

    Return true when a signal has at least one value change.

    signal_has_high_impedance

    fn signal_has_high_impedance(vcd : VcdFile, full_name : String) -> Bool raise VcdError

    Return true when the signal ever contains a z value.

    signal_has_unknown

    fn signal_has_unknown(vcd : VcdFile, full_name : String) -> Bool raise VcdError

    Return true when the signal ever contains an x value.

    signal_identifiers

    fn signal_identifiers(vcd : VcdFile) -> Array[String]

    Return raw VCD identifiers in declaration order.

    signal_manifest

    fn signal_manifest(vcd : VcdFile) -> String

    Render signal names as a newline-delimited manifest.

    signal_stats

    fn signal_stats(vcd : VcdFile, full_name : String) -> SignalStats raise VcdError

    Compute change count, time bounds, and 1-bit rising/falling edges.

    signal_transitions

    fn signal_transitions(vcd : VcdFile, full_name : String) -> Array[SignalTransition] raise VcdError

    Return transitions between consecutive known parsed values of one signal.

    signal_types

    fn signal_types(vcd : VcdFile) -> Array[String]

    Return every unique signal type seen in declarations.

    signal_value_diff_count

    fn signal_value_diff_count(left : VcdFile, right : VcdFile, full_name : String) -> Int raise VcdError

    signals_by_type

    fn signals_by_type(vcd : VcdFile, signal_type : String) -> Array[Signal]

    Return declarations whose VCD type matches signal_type.

    signals_under_scope

    fn signals_under_scope(vcd : VcdFile, scope_prefix : String) -> Array[Signal]

    Return signals whose full hierarchical name starts with scope_prefix.

    single_signal_report

    fn single_signal_report(vcd : VcdFile, full_name : String) -> String raise VcdError

    Render a lightweight report for one signal.

    snapshot_at

    fn snapshot_at(vcd : VcdFile, timestamp : Int64) -> VcdSnapshot raise VcdError

    Build a point-in-time snapshot for every declared signal.

    snapshot_is_complete

    fn snapshot_is_complete(vcd : VcdFile, timestamp : Int64) -> Bool raise VcdError

    Return true when every declared signal has a value at timestamp.

    snapshot_value

    fn snapshot_value(snapshot : VcdSnapshot, full_name : String) -> String?

    Return the value for a signal inside a snapshot.

    snapshots

    fn snapshots(vcd : VcdFile) -> Array[VcdSnapshot] raise VcdError

    Build snapshots for every timestamp present in the VCD.

    start_time

    fn start_time(vcd : VcdFile) -> Int64?

    Earliest timestamp in the file, if any changes exist.

    summary

    fn summary(vcd : VcdFile) -> VcdSummary

    Summarize file-wide counts and time bounds.

    timestamp_buckets

    fn timestamp_buckets(vcd : VcdFile) -> Array[TimestampBucket]

    Group all changes into timestamp buckets.

    timestamp_count

    fn timestamp_count(vcd : VcdFile) -> Int

    Count unique timestamps.

    timestamps

    fn timestamps(vcd : VcdFile) -> Array[Int64]

    Return all unique timestamps seen in change order.

    transition_count

    fn transition_count(vcd : VcdFile, full_name : String) -> Int raise VcdError

    Count value transitions, ignoring repeated writes of the same value.

    unchanged_signals

    fn unchanged_signals(vcd : VcdFile) -> Array[Signal]

    Return signals that never receive a value change.

    uncovered_signal_count

    fn uncovered_signal_count(vcd : VcdFile) -> Int

    Count signals that never receive a value.

    undefined_signals_at

    fn undefined_signals_at(vcd : VcdFile, timestamp : Int64) -> Array[Signal] raise VcdError

    Return signals that have no value at timestamp.

    unknown_bit_count

    fn unknown_bit_count(value : String) -> Int

    Count unknown bits in a scalar or vector value.

    unknown_change_count

    fn unknown_change_count(vcd : VcdFile, full_name : String) -> Int raise VcdError

    Count changes for a signal whose value contains x.

    validate_vcd

    fn validate_vcd(vcd : VcdFile) -> Array[VcdIssue]

    Validate parsed invariants that should hold after parse_vcd.

    value_at

    fn value_at(vcd : VcdFile, full_name : String, timestamp : Int64) -> String? raise VcdError

    Return the most recent value at or before timestamp.

    value_counts

    fn value_counts(vcd : VcdFile, full_name : String) -> Array[ValueCount] raise VcdError

    Count occurrences of each value in a signal change history.

    value_diff_count

    fn value_diff_count(left : VcdFile, right : VcdFile) -> Int raise VcdError

    value_spans

    fn value_spans(vcd : VcdFile, full_name : String) -> Array[ValueSpan] raise VcdError

    Return value spans from each change until the next change.

    vcds_are_equivalent

    fn vcds_are_equivalent(left : VcdFile, right : VcdFile) -> Bool raise VcdError

    vcds_have_same_signal_set

    fn vcds_have_same_signal_set(left : VcdFile, right : VcdFile) -> Bool

    vcds_have_same_timestamps

    fn vcds_have_same_timestamps(left : VcdFile, right : VcdFile) -> Bool

    vcds_have_same_values

    fn vcds_have_same_values(left : VcdFile, right : VcdFile) -> Bool raise VcdError

    vector_signals

    fn vector_signals(vcd : VcdFile) -> Array[Signal]

    Return multi-bit signals.

    zero_bit_count

    fn zero_bit_count(value : String) -> Int

    Count zeros in a scalar or vector value.