Rename the tool to lucisv (Language Utility for Coding In SystemVerilog)
This commit is contained in:
1 parent
a284e33110
commit
eeaffafd56
188 files changed
+2825
-2802
No files matched your search
@@ -45,14 +45,14 @@ calls (`q.push_back(x)`, `q.size()`) are ordinary member calls.
|
||||
|
||||
- **`$` is an ordinary primary expression, not a keyword.** In real code a
|
||||
bare `$` stands only where a queue bound belongs (`q[$]`, `[$:N]`,
|
||||
`q[$-1]`), but vfmt does not check legality anywhere else either, and one
|
||||
`q[$-1]`), but lucisv does not check legality anywhere else either, and one
|
||||
`ExprKind::Ident("$")` leaf makes every position — dims, indexes, ranges,
|
||||
arithmetic — work through the existing expression grammar. This follows the
|
||||
`new`/`this`/`super` precedent from the classes round. The lexer already
|
||||
emits a lone `$` as a one-char Symbol token; nothing lexes differently.
|
||||
- **`{}` is accepted as an empty concatenation** (`ExprKind::Concat(vec![])`)
|
||||
because SystemVerilog's empty queue literal is spelled that way
|
||||
(`mem_states[$] = {};`). Plain Verilog forbids `{}`; vfmt is a formatter,
|
||||
(`mem_states[$] = {};`). Plain Verilog forbids `{}`; lucisv is a formatter,
|
||||
not a compiler, and refusing it would keep a real corpus file blocked.
|
||||
- **A named call argument is recognized by `.` + identifier at an expression
|
||||
*element* start.** `parse_expr_item` is shared by call arguments, concats,
|
||||
@@ -63,7 +63,7 @@ calls (`q.push_back(x)`, `q.size()`) are ordinary member calls.
|
||||
labels need and no expression could previously start with.
|
||||
- **`case (x) inside` is the same statement with one extra token.** The
|
||||
`inside` flag is stored on `StmtKind::Case` and printed back; item labels
|
||||
are the ordinary label list plus `[lo:hi]` ranges. vfmt does not restrict
|
||||
are the ordinary label list plus `[lo:hi]` ranges. lucisv does not restrict
|
||||
range labels to inside-mode cases — a plain `case` with a `[1:2]:` label is
|
||||
not legal SV but parses; same tokens out, no corruption possible.
|
||||
- **A bare `@name;` (no parens) is printed back without parens.** Before this
|
||||
@@ -163,10 +163,10 @@ loop and label loop were already flat.
|
||||
`ValueRange`/`Bare` reuse existing walker arms; two dynamic-type sources were
|
||||
added to `SOURCES`.
|
||||
|
||||
**Not touched, by scope:** `crates/vfmt`, `crates/vfmt_core`,
|
||||
`crates/vfmt_server`, `crates/vlog_linter`, `verify.rs`, `fence.rs`,
|
||||
**Not touched, by scope:** `crates/lucisv`, `crates/lucisv_core`,
|
||||
`crates/lucisv_server`, `crates/vlog_linter`, `verify.rs`, `fence.rs`,
|
||||
`editors/`, `tools/`, `corpus/`. A concurrent agent owns `vlog_linter` /
|
||||
`vfmt` / `vfmt_server` this round; `cargo fmt` was run per-package
|
||||
`lucisv` / `lucisv_server` this round; `cargo fmt` was run per-package
|
||||
(`-p vlog_parser -p vlog_formatter -p vlog_semantic`), never `--all`.
|
||||
|
||||
## Status / TODO
|
||||
@@ -241,7 +241,7 @@ added to `SOURCES`.
|
||||
build, exit 0. Three runs (two mid-round, one after the final `cargo fmt`):
|
||||
byte-identical TSVs, md5 `e6f12eb7964e22e452655cf517cae766`. All four corpus
|
||||
repos verified unmodified afterwards (`git status --porcelain` clean apart
|
||||
from the pre-existing untracked `.vfmt-corpus-rev` stamps).
|
||||
from the pre-existing untracked `.lucisv-corpus-rev` stamps).
|
||||
|
||||
| metric | before | after |
|
||||
|---|---|---|
|
||||
@@ -371,12 +371,12 @@ assignment-operator fix exposed the named-arg-paren drop in the same file.
|
||||
corpus repos confirmed clean. The `` `else`` 13 and `with` 7 next-blockers
|
||||
were read at their sites and filed under Status/TODO with the evidence.
|
||||
- **Scope discipline:** did not touch `verify.rs`, `fence.rs`,
|
||||
`crates/vfmt*`, `crates/vlog_linter` (its `visit.rs` needed no arm — it
|
||||
`crates/lucisv*`, `crates/vlog_linter` (its `visit.rs` needed no arm — it
|
||||
has no expression walk and its `Case` matches use `..`), `tools/`,
|
||||
`corpus/`. The concurrent one-parse-two-tools agent's files churned in the
|
||||
same tree throughout; `cargo fmt` was run per-package
|
||||
(`-p vlog_parser -p vlog_formatter -p vlog_semantic`), never `--all`, and
|
||||
the one transient `vfmt_server` test failure observed mid-round was
|
||||
the one transient `lucisv_server` test failure observed mid-round was
|
||||
re-run and confirmed to be their in-flight edit, not this diff. Did not
|
||||
run `git commit` / `git push`.
|
||||
- **Session note:** the session was interrupted by a usage limit mid-way
|
||||
@@ -440,10 +440,10 @@ is uncommitted here too; its files were attributed, not flagged — see
|
||||
`scratchpad/head-wt`, provenance re-verified — `git rev-parse HEAD` =
|
||||
`e9008b680c2df86c7bea6d29095250958c132306`, `git status --porcelain` empty,
|
||||
`cargo build --release` a no-op (binary genuinely fresh at `e9008b6`, md5
|
||||
`feaa240d`). "New" binary: this tree's `target/release/vfmt` (md5 `957e2ad6`),
|
||||
`feaa240d`). "New" binary: this tree's `target/release/lucisv` (md5 `957e2ad6`),
|
||||
also confirmed up to date. `corpus/` never written to; all four corpus repos
|
||||
`git status --porcelain` clean afterwards apart from the pre-existing
|
||||
untracked `.vfmt-corpus-rev` stamps.
|
||||
untracked `.lucisv-corpus-rev` stamps.
|
||||
|
||||
**Claim-by-claim.**
|
||||
|
||||
@@ -474,7 +474,7 @@ untracked `.vfmt-corpus-rev` stamps.
|
||||
`` `uvm_field_int`` 11, `'` 7, `with` 7, `"DPI-C"` 7, `$error` 6,
|
||||
`virtual` 4, `export` 4.
|
||||
- **Round-trip of all 636**, not sampled: copied to a scratch directory,
|
||||
`vfmt format` in place (0 failures), then `vfmt --check` (0 failures) —
|
||||
`lucisv format` in place (0 failures), then `lucisv --check` (0 failures) —
|
||||
every one a verified fixed point.
|
||||
- **Stronger than asked: all 578 previously-formattable files were
|
||||
compared byte-for-byte old-vs-new**, not a 20-file sample.
|
||||
@@ -499,9 +499,9 @@ untracked `.vfmt-corpus-rev` stamps.
|
||||
correct, they hold no expressions), and
|
||||
`ExprKind::NamedArg { value, .. }`. Nothing else in the crate changed.
|
||||
**Attribution:** `crates/vlog_linter/{src/context.rs,src/lib.rs,tests/rules.rs}`,
|
||||
`crates/vfmt/src/lint.rs`, `crates/vfmt_server/{lint,state}.rs` are the
|
||||
`crates/lucisv/src/lint.rs`, `crates/lucisv_server/{lint,state}.rs` are the
|
||||
one-parse round's own file list (its README §Handshakes / §Work log), and
|
||||
`crates/vfmt_server/src/diagnostics.rs` is the lead's QA-1 fix recorded in
|
||||
`crates/lucisv_server/src/diagnostics.rs` is the lead's QA-1 fix recorded in
|
||||
that round's Review §4. `git diff crates/vlog_linter/` contains **no**
|
||||
dynamic-types symbol (`DimKind`/`NamedArg`/`SensList`/`inside`/
|
||||
`op_comments`) — this feature really did not touch it.
|
||||
@@ -524,7 +524,7 @@ succeeded, re-parsed by the net's own equivalence + convergence check).**
|
||||
are idempotent. **Illegal positions are accepted and round-trip losslessly**:
|
||||
`assign x = $;`, `x = $ + 1;`, `x = $$;`, `f($, $)`, `logic [$:0] w;` all
|
||||
emit the same tokens back. That is consistent with the documented
|
||||
Assumption ("vfmt does not check legality anywhere else either") and cannot
|
||||
Assumption ("lucisv does not check legality anywhere else either") and cannot
|
||||
corrupt. **No identifier collision:** `int $;` is a parse error
|
||||
(`expected identifier (found "$")`), so `$` cannot be declared.
|
||||
`$display`/`$bits(int)`/`$error`/`$time`/`$finish` are byte-unaffected.
|
||||
@@ -538,8 +538,8 @@ succeeded, re-parsed by the net's own equivalence + convergence check).**
|
||||
- *`NamedArg`.* `f(.a(x), .b())`, `.a()` empty, named-in-`$display`
|
||||
(`$display(.fmt("%d"), .v(x))`), scoped callees, and **mixed positional +
|
||||
named in both orders** (`g(x, .b(y))`, `h(.a(x), y)`) all parse — SV forbids
|
||||
the mix, vfmt accepts it and emits the same tokens, matching the documented
|
||||
"vfmt is not a legality checker" stance. A nested `k(.a(.b(x)))` is a parse
|
||||
the mix, lucisv accepts it and emits the same tokens, matching the documented
|
||||
"lucisv is not a legality checker" stance. A nested `k(.a(.b(x)))` is a parse
|
||||
error (refusal, safe). **Disambiguation holds:** `sub #(.W(8), .D()) u0
|
||||
(.clk(clk), .d(), .q(q));`, `sub u1 (.*);` and `sub u2 (.a(1), .b);` are
|
||||
byte-identical old-vs-new — instantiation connections still take the
|
||||
@@ -583,9 +583,9 @@ succeeded, re-parsed by the net's own equivalence + convergence check).**
|
||||
`case … inside`, both bare event controls, the macro-then-`cov.` shape, and
|
||||
an `` `ifndef``/`` `endif`` wrapper: **format(format(format(x))) == format(x)**,
|
||||
and all six embedded comments present in the output.
|
||||
- *Lint path over the new syntax.* `vfmt check` over the probe files runs
|
||||
- *Lint path over the new syntax.* `lucisv check` over the probe files runs
|
||||
clean and `case-missing-default` correctly fires on `case … inside`. See
|
||||
QA-7 for the corpus-wide `vfmt check` delta.
|
||||
QA-7 for the corpus-wide `lucisv check` delta.
|
||||
|
||||
**Sabotage (each applied, caught, reverted, and the revert proven by `cmp`
|
||||
against a pre-sabotage byte copy).**
|
||||
@@ -681,7 +681,7 @@ failed**.
|
||||
Handshakes promises — including its pre-existing limitation. The shapes that
|
||||
*do* work in a connection also work in a named argument (`.a(x /* post */)`,
|
||||
`.a(/* only */)`, `.a(x // line` ⏎ `)`).
|
||||
- **QA-7 (INFORMATIONAL — cross-round note for the lead).** `vfmt check
|
||||
- **QA-7 (INFORMATIONAL — cross-round note for the lead).** `lucisv check
|
||||
corpus` differs from the HEAD binary by **10 lines, net +6 findings** (7921
|
||||
→ 7927), entirely as a consequence of files that now parse: 7 new, correct
|
||||
`case-missing-default` findings on `case … inside` statements, and at
|
||||
@@ -692,7 +692,7 @@ failed**.
|
||||
Handshakes' "Required of `vlog_linter`: nothing" is correct *at the
|
||||
compilation level*. Flagged only because the concurrent one-parse round
|
||||
proved its lint output byte-identical against a tree that did not contain
|
||||
this round: in the merged tree `vfmt check` output is no longer identical to
|
||||
this round: in the merged tree `lucisv check` output is no longer identical to
|
||||
`e9008b6`'s, and those 10 lines are why.
|
||||
- **QA-8 (INFORMATIONAL).** A `[lo:hi]` value range is accepted at every
|
||||
expression-element position **except the first call argument**:
|
||||
|
||||
Reference in new issue
Block a user