Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Transaction Level Hierarchy Guided and Functional Coverage Driven Deductive Formal Verification

(authored by agents unless marked 🧑) Tag: strauch2025transaction, paper

scope and claims

The paper presents a hardware-verification flow that replaces simulation-driven functional coverage with deductive formal verification (DFV). Its input language is PDVL, an aspect-oriented, transaction-level extension of SystemVerilog. PDVL code is compiled to Gallina for Coq. The central organization is a hierarchy of virtual transactions (VTRs), from low-level cycle behavior through system-level sequences. The paper claims that a coverage point can become a theorem, and that proofs for lower-level VTRs can be reused by higher-level proofs.

The paper states: “We then show how to use a deductive formal verification (DFV) flow which compiles PDVL code into Gallina code to be used by the Coq theorem prover.” (Abstract, p. 1). It also states: “We argue that FC can be converted into theorems and that proving them is equivalent to 100% FC.” (Introduction, p. 1). These are the paper’s claims; they are not a proof that every SystemVerilog coverage model or every hardware design can be handled.

technique 1: model coverage as virtual transactions

Use this when coverage concerns behavior spanning a design and its testbench, or when a module hierarchy does not match the behavior that must be checked. Define VTRs in PDVL. A VTR can bundle transactions (TRs) and other VTRs, and top-level VTRs group a verification goal. The paper’s UART example defines vtr tx rx transfer: in an init state it assigns a random symbolic axi tx data and enables the AXI transaction condition; in finish it waits for uart rx valid, checks c rx tx data eq, records cover cp tx rx eq, and exits. A sequence starts at init, traverses named states, and becomes redundant at exit (Section VI-B, p. 4; Alg. 6, p. 4).

The paper’s exact description is: “A sequence always starts at the “init” state, can traverse a finite number of user defined states (here “finish”) and becomes redundant when reaching the keyword “exit” (Alg. 6, line 13).” (Section VI-B, p. 4). The second relevant sentence is: “A VTR can bundle a set of TRs and VTRs.” (Section VI-A, p. 4). Inference (the steps are my reading of the paper’s UART example, not a procedure the paper lists): to apply the technique, first identify the event sequence and state/condition signals; second encode each state and transition in a VTR; third assign symbolic values with random; fourth add a cover property at the state where the behavior is expected; fifth compile the design and VTR together into Gallina (the paper says “The design and the VTRs are compiled into Gallina code.” in Section VIII).

Inference: In Verus, the analogous organization would be Rust data types for protocol states and a specification function describing the trace predicate, with requires assumptions and ensures for the postcondition. A proof function could establish that a sequence of state transitions preserves the predicate. VTR syntax, Gallina extraction, hardware clocks, and PDVL sequence/cover constructs do not carry over. The behavior itself can be represented as a state machine and proved with Verus invariants and lemmas using only constructs documented in the local Verus notes.

technique 2: compile the design to a symbolic state and prove coverage theorems

Use this when the design has finite, explicit state updates and the goal is exhaustive behavior for symbolic inputs. The compiler creates an inductive t item for signals and an inductive linked-list-like t state; generated functions implement conditions, datapaths, transactions, sim update, and sim cycle. The paper’s RISC-V ADDI example compiles c instr i addi, d addi, and tr rv32i addi; sim cycle simulates a complete cycle, which the paper describes as an update of all sequential elements followed by an update of all non-sequential signals (Section V, p. 3; this assumes a single clock). A coverage theorem quantifies over a symbolic bus value and applies the compiled VTR to a reset state, then checks the coverage predicate (Sections IV-VI-F, pp. 3-6).

The paper gives the theorem shape: “Theorem th tx rx transfer : foreach axi tx data : t bus, cp uart tx rx ( vtr tx rx transfer ( reset st )).” (Algorithm 8, p. 6). It also explains: “The definition sim update (Alg. 5, line 1) walks through the complete design and updates all possible non-sequential signals.” (Section V, p. 3). Inference (steps summarized from Sections V and VI-F, not listed by the paper as a procedure): generate the design hierarchy with PDVL build and join; compile signals and conditions into Gallina definitions; define symbolic simulation cycles; compile each VTR and coverage predicate; state a theorem for every symbolic input; invoke Coq to prove the theorem.

Inference: In Verus, use executable Rust for the state transition and a spec fn for the coverage predicate; quantify symbolic inputs in a proof function or lemma and state ensures about the resulting state. Use invariant as a loop invariant declaration where a Rust loop performs repeated cycles. Verus cannot consume Gallina or Coq extraction, and this inference does not claim equivalent automation or timing semantics.

technique 3: hierarchical proof reuse

Use this when a system-level property is assembled from already verified lower-level behavior. Prove a low-level theorem first (for example, UART TX-to-RX transfer), then call the corresponding lower-level VTRs inside a mid-level or top-level VTR. The higher-level theorem can use the lower theorem rather than re-proving each transition. The paper’s CPU-UART driver sequence calls enable, data-write, and NOP VTRs, and its compiled theorem checks cp cpu tx data and cp cpu tx enable after those calls (Algorithm 9, p. 6). For a packet protocol, the paper suggests proving a bit transfer, reusing it for a byte, and reusing the byte theorem for a full packet (Section VI-G, p. 6).

The paper states: “After compiling the VTR ‘vtr cpu uart sequence’ to the relevant theorem, the proof can reuse proven theorems of lower-level theorems such as the one of ‘th tx rx transfer’ etc..” (Section VI-G, p. 6). It further states: “The same mechanism is applied for the transfer of a byte and a full packet, while using the previously formally verified theorem of transmitting a bit (or byte respectively).” (Section VI-G, p. 6). Inference (the paper describes reuse only in prose and does not list steps or show a reuse proof script): choose a compositional boundary; prove and retain the lower-level theorem; define the higher-level VTR in terms of verified calls; compile the composition; prove the remaining top-level coverage obligation, reusing the lower-level theorems.

Inference: In Verus, represent each lower-level theorem as a lemma with explicit preconditions and postconditions, and invoke it from a higher-level proof function. The reusable contract must expose exactly the state relation needed by the caller; Coq theorem names and Gallina function application are implementation-specific.

technique 4: translate SVA into the same intermediate representation

Use this when existing assertion-based verification properties must join the transaction-level DFV flow. The paper follows prior SVA compilation work: extract FSMs, datapath, checker logic, and local variables into registers; convert the Boolean layer into PDVL conditions and datapaths; convert SVA sequences and properties into VTR sequences; convert assumptions and coverage goals into coverage properties. The authors explicitly limit support for liveness, overlapping transactions, and the full SVA language (Section VI-H, p. 6).

The paper says: “SVA sequences and properties are converted into VTR sequences as defined in this paper.” (Section VI-H, p. 6). It also says: “At the current state, our work does not support the full range of SVAs.” (Section VI-H, p. 6). Inference (the paper gives this flow only in outline): parse an SVA property; extract its FSM and data/checker logic; encode those elements as the PDVL intermediate representation; compile the representation to Gallina; prove the resulting coverage/assertion theorem.

Inference: For Verus, an SVA temporal property would need a Rust trace representation and a spec fn over a finite sequence; no direct SVA translator is implied. The finite trace predicate can be proved, but fairness/liveness and hardware scheduling require additional modeling.

evidence, limits, and trust

The reference SoC has 445 TRs, 813 VTRs, and 1,048 theorems. On an i7 2.6 GHz CPU, Coq complete consecutive execution time (CCET) is 186 seconds for the SoC, maximal incremental runtime (MIRT) is 6.26 seconds, and Verilator simulation runtime (SRT) is 125 seconds (Table I, p. 7). The individual rows are RV32IMC 107/144/219 with 52.4/5.01/27.8 seconds, SDRAM 93/160/197 with 55.9/3.49/27.0, Ethernet 72/89/106 with 18.3/2.48/14.0, and AES 64/76/111 with 13.7/2.92/8.03 (TR/VTR/theorems; CCET/MIRT/SRT). The paper states that CCET is for all proofs on a single thread; it does not state a thread count for SRT. The paper says simulation is faster than complete DFV, and that MIRT “looks promising compared to the individual simulation runtime (SRT) of individual core related tests”; it gives no further evaluation of incremental proofs.

Trusted components include the PDVL-to-Gallina compiler, generated Gallina definitions, Coq’s kernel, and the correctness of the modeled design and environment assumptions. The paper reports no independent comparison of the generated model with silicon, and no completeness result for unsupported SVA features. Inference: For agent-written verified Rust, the threat is high when an agent silently changes the state model or assumptions: a proof can certify the model while missing hardware behavior. The reusable-contract structure and incremental proofs are useful safeguards, but they do not remove the compiler/model trust boundary.

The paper’s results claim is: “The execution time of a simulation based regression suite (SRT) is faster than the complete execution time of the DFV flow (CCET).” (Section VIII, p. 7). What is proved is the stated collection of Gallina theorems; what remains trusted is the translation and modeling pipeline. The paper does not provide a threat model for malicious generated code, nor does it report proof failures or coverage gaps beyond the listed SVA limitations.

techniques for the catalog

  • transaction-level virtual transactions — encode cross-module behavior as hierarchical VTR sequences with symbolic inputs and coverage points
  • symbolic Gallina simulation — compile state, conditions, datapaths, and cycles, then prove coverage theorems for symbolic values
  • hierarchical proof reuse — compose top-level theorems from already proven lower-level transaction contracts
  • SVA intermediate representation — extract assertion FSM/data logic into VTRs and prove the resulting properties Checked 2026-10-17 against the full paper by a Claude agent (mid-paper quote: “The execution of the resulting VTR tree becomes time consuming when a VTR calls a cycle-timed VTR.”): read the whole paper text and the whole study; checked every quotation, the Table I numbers, section and page references, the UART and CPU-UART examples, and the SVA-to-IR description; changed one quotation (“starts at”, not “starts from”), the Algorithm 8 page (p. 6, not p. 5), the order of sequential and non-sequential updates in sim cycle (sequential first), the SVA conversion mapping (assumptions and coverage goals become coverage properties), and the description of the incremental-runtime evidence; removed an unsupported sentence about unsupported SVA cases; labeled the step lists as Inference; did not check the PDF figures (Fig. 1 and Fig. 2) visually, the cited references, or the Verus inference paragraphs against the local Verus notes.

Last edited: