Repository navigation
feat(sv): run always @* calls of timed tasks as processes and accept package delays - #1816
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: bd85c2d892
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Queued — the merge queue status continues in this comment ↓. |
Merge Queue Status
This pull request spent 57 minutes 24 seconds in the queue, with no time running CI. ReasonThe pull request conflicts with the base branch The pull request was held in the queue, conflicting with at least one of 4 pull requests ahead of it. The conflict became a base branch one after #1773, #1814 merged. HintYou should update or rebase your pull request. If you want to requeue this pull request, you can post a Requeued — the merge queue status continues in this comment ↓. |
bd85c2d to
6b6ce69
Compare
6b6ce69 to
e0d3f3d
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e0d3f3d20f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
e0d3f3d to
911d5ce
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 911d5ce646
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…package delays A plain always @* that calls a task containing a timing control was rejected. It is an ordinary always procedure (IEEE 1800-2023 9.2.2.2.2), so it now runs as a process that waits on its implicit event list, the variables the statement reads with the task's arguments but not its body (9.4.2.2), before each run, like an always @* with a direct timing control. always_comb and always_latch may not suspend (9.2.2.2): a timed task call there is now the same language error as a direct timing control, instead of an unsupported construct. A package-scoped delay value such as #pkg::D is a ps_identifier delay_value (A.6.5); it is now bound like the parenthesized #(pkg::D). Verilator 5.052 schedules the always @* case differently and Icarus 13.0 cannot parse #pkg::D; both cases are excluded with retained evidence. The wait of an @* now keeps the statements it covers, folded branches included (Stmt::WaitImplicit), and the frontend reads them with the analysis that gives a combinational always @* its sensitivity: the defaults of omitted arguments, of nested calls too, and constant-false branches count (9.4.2.2), and timing-control expressions do not. Direct @* waits in processes use the same analysis. Icarus prunes folded branches and Verilator leaves defaults out; both are excluded. Fixes #1710 Change-Id: I187e0c26549e9aca2eda399699c24ddbc8de24bf
Change-Id: I63e21eb628046b097fc69220dc1a63f1e148b286
911d5ce to
88acb3b
Compare
Merge Queue Status
This pull request spent 1 hour 16 minutes 23 seconds in the queue, including 1 hour 14 minutes 45 seconds running CI. Required conditions to merge
|
Part of #1123. Fixes #1710.
always @* t(a);wheretcontains a timing controlalways_comb t();/always_latch ... t();with a timedt#pkg::Dpkg::D, like#(pkg::D)IEEE 1800-2023
always @*is an ordinaryalwaysprocedure, so it may call a task that suspends.always_combandalways_latchmay not suspend.delay_valueincludesps_identifier, so#pkg::Dis legal without parentheses.Change
procedural::timed_tasks::classify): analways @*comb process whose body suspends through a task call moves to the process list.forever { @(implicit event); statement }, the same form analways @*with a direct timing control already takes.CombProcessnow carries aProcessSite, so the new process has a location for diagnostics such as fix(sim)!: reject designs with processes in untimed Simulator builds #1720'sProcessRequiresSimulation.always_comboralways_latchraisesTimingControlOutsideProcess.pkg::Dgoes through the same value binding as the parenthesized form.Perf
Optimized SIR (
TraceOptions::post_optimized_sir, hashed Debug text) is byte-identical between base 27f96bc and this branch for 655 of the 657 SV suite cases, timed cases included. The two that differ are the new cases.Tests
timing.vtest):always_star_timed_task_calls_run_as_processespackage_scoped_delay_values_wait_their_valuealways @*case passes on Icarus. Verilator 5.052 schedules it differently:ychanges at 6 instead of 5. A standalone probe also shows Verilator rerunning the call for changes made while the task was suspended, and for variables only the task body reads. New entry:sv_verilator_always_star_timed_task.#pkg::D. New entry:sv_icarus_package_delay_value.timing.jsonreports gain only the new records.always_star_timed_task_calls_miss_changes_while_suspended(Icarus agrees).always_combcase and analways_latchcase were added totiming_controls_outside_suspendable_processes_are_rejected, and the SV: timed task call from always @*, and package-scoped delay values #1710 entry was removed fromunimplemented_timing_features_are_rejected.synthesizable::task_timing_control_is_rejectednow expects the language error.timed_task_calls_require_a_suspendable_contextnow checks thatalways @*becomes a process.expected.tsv;retained_reportspasses; docs updated (EN and JA).Noticed, not in this PR
%tin Celox defaults to the module's time unit, rounded:#1.5under`timescale 1ns/1psprints2. Icarus and Verilator print in the design's precision (1500), and IEEE 20.4.3 makes the smallest precision the$timeformatdefault.