Repository navigation
merge queue: merged #2133: fix(sv): compare the bounds, not the spelling, of non-ANSI port ranges - #2729
Closed
mergify[bot] wants to merge 5 commits into
Closed
merge queue: merged #2133: fix(sv): compare the bounds, not the spelling, of non-ANSI port ranges#2729mergify[bot] wants to merge 5 commits into
mergify[bot] wants to merge 5 commits into
Conversation
A non-ANSI port can be declared again in a net or variable declaration, and if that declaration is a vector, the two ranges "shall be identical" (IEEE 1800-2023 23.2.2.1). The parser compared the token text of the two ranges, so equal ranges written differently were rejected. rtlmeter's XuanTie E902 and E906 declare `output [79:0] busif_kid_clicintattr_sel;` and `wire [CLICINTNUM-1:0] busif_kid_clicintattr_sel;` with `CLICINTNUM` = 64+16, and the compile failed. The parser cannot evaluate parameters, so the check moves to elaboration: - When the spellings differ, the parser keeps the net or variable declaration's type for the port and records the port declaration's type in the new `Port::declared_type`. - `ports_from_scope` evaluates both ranges with the module's parameter values and rejects the port when the bounds differ: "the ranges of a non-ANSI port declaration and its net or variable declaration of `x` differ". - A port declaration without a range completed by a vector declaration is still rejected by the parser. Closes #2126. - Shared case `hierarchy::non_ansi_port_ranges_compare_bounds`: the E902 shape (a macro-built parameter in the net's range), matching Icarus and Verilator. - `rejects_malformed_non_ansi_port_declarations` also rejects ranges that differ through a parameter (`input [3:0] a; wire [N-1:0] a;` with N = 8). Change-Id: I0fc04b280c929c9f50d191276e5cc31fb4949ad5
Change-Id: I1b666c99bf3bec2c6ea31960c88f76d9c5286bc0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note
This is a merge queue draft opened by Mergify. Its pull request has merged, and nobody needs to act on it.
Mergify opened it for batch singular-potaufeu-2n03sk of the
changesqueue, to test #2133 before it merged intomaster.🎉 What landed
Mergify merged its pull request into
master, then closed this draft:0cb1011This draft's code was built in this order:
masteratd7abfa7ad815f0Queued ahead of this batch
This pull request entered the queue before this batch and is not part of it.
Metadata for CI tooling, read by
mergify ci1 scope
coreRequired conditions of queue rule
changesfor mergecheck-success = Conventional Commit titlecheck-success = Queue validationcheck-success = Verify workflow lockfilemaster]:check-success = @github-actions/Lint & Formatcheck-neutral = @github-actions/Lint & Formatcheck-skipped = @github-actions/Lint & Formatmaster]:check-success = @github-actions/Rust Test & NAPI Buildcheck-neutral = @github-actions/Rust Test & NAPI Buildcheck-skipped = @github-actions/Rust Test & NAPI Buildmaster]:check-success = @github-actions/JS Test (Ubuntu)check-neutral = @github-actions/JS Test (Ubuntu)check-skipped = @github-actions/JS Test (Ubuntu)master]:check-success = @github-actions/Conventional Commit titlecheck-neutral = @github-actions/Conventional Commit titlecheck-skipped = @github-actions/Conventional Commit titlemaster]:check-success = @github-actions/Queue validationcheck-neutral = @github-actions/Queue validationcheck-skipped = @github-actions/Queue validationmaster]:check-success = @github-actions/Verify workflow lockfilecheck-neutral = @github-actions/Verify workflow lockfilecheck-skipped = @github-actions/Verify workflow lockfileRequired conditions to stay in the queue
-conflict-draft-head ~= ^(integration/|renovate/veryl-crates$|upgrade/veryl-|release-please--branches--master--components--celox$|master$)-head ~= ^renovate/-label = release:holdbase ~= ^(master|develop)$base ~= ^stack/body ~= (?m)^Depends-On:head != release-please--branches--master--components--celoxlabel = merge-readymaster]:check-success = @github-actions/Lint & Formatcheck-neutral = @github-actions/Lint & Formatcheck-skipped = @github-actions/Lint & Formatmaster]:check-success = @github-actions/Rust Test & NAPI Buildcheck-neutral = @github-actions/Rust Test & NAPI Buildcheck-skipped = @github-actions/Rust Test & NAPI Buildmaster]:check-success = @github-actions/JS Test (Ubuntu)check-neutral = @github-actions/JS Test (Ubuntu)check-skipped = @github-actions/JS Test (Ubuntu)master]:check-success = @github-actions/Conventional Commit titlecheck-neutral = @github-actions/Conventional Commit titlecheck-skipped = @github-actions/Conventional Commit titlemaster]:check-skipped = @github-actions/Queue validationcheck-neutral = @github-actions/Queue validationcheck-success = @github-actions/Queue validationmaster]:check-success = @github-actions/Verify workflow lockfilecheck-neutral = @github-actions/Verify workflow lockfilecheck-skipped = @github-actions/Verify workflow lockfile