Repository navigation
feat(sv): support unpacked structures as dynamic container elements - #2422
Conversation
|
This pull request is part of a Mergify stack:
|
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: 79d36ee85f
ℹ️ 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 ↓. |
c3f54de to
c71b11a
Compare
79d36ee to
437b350
Compare
Revision history
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 437b350222
ℹ️ 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".
c71b11a to
ecce9b8
Compare
437b350 to
53dedc6
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 53dedc6898
ℹ️ 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".
ecce9b8 to
9c93687
Compare
53dedc6 to
15e6872
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 15e6872922
ℹ️ 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".
9c93687 to
98ce935
Compare
15e6872 to
8e65031
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8e65031d3b
ℹ️ 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".
8e65031 to
b431e1e
Compare
98ce935 to
88a469a
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b431e1ea9c
ℹ️ 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".
b431e1e to
5f7b93b
Compare
88a469a to
4f9dad1
Compare
Queues, dynamic arrays and associative arrays of an unpacked structure type were rejected. A structure of at most 64 bits whose members are all 2-state or all 4-state and hold no handle is kept as its flat value, so the container's default element is the structure's default. Any other structure is held as an immutable heap record: `ObjectOp::Box` builds a record from the flat value on `push`, `insert` or an assignment, and `ObjectOp::Unbox` reads it back. Each leaf is a record field, so the collector traces string and handle members through the record's handle list, and 4-state members keep their X/Z bits. Record fields are `nullable`: the new `OBJECT_LOAD_NULLABLE` heap operation reads a null record as zeros without a fault, which is the default structure for a missing associative entry or a new dynamic array element. Records are not seeded, so they do not draw from the process RNG. `e.m` reads a member of an element `q[i]`, `aa[k]` or a popped element directly from the record or the flat value, including a handle member's properties (`q[0].orig.m_type.n`). Patterns, typed patterns and values of the structure type initialize elements. Comparing containers of records and sorting structures without `with` are rejected, as is writing a member of an element. Assignment patterns passed to a method argument now receive the formal's shape, which method calls taking a structure need. Change-Id: Iac820f46cbee8d792f4b0fbde28baccdd54ecf31
5f7b93b to
a37c612
Compare
4f9dad1 to
23214db
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a37c612c38
ℹ️ 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".
✅ Merged into
|
| Condition | |
|---|---|
| ✅ | depends-on = celox-sim/celox#2419 |
The batch, tested on draft #2495
| Condition | Required by | |
|---|---|---|
| ✅ | check-success = Conventional Commit title |
— |
| ✅ | check-success = Queue validation |
— |
| ✅ | any of: check-success = @github-actions/Lint & Format, check-neutral = @github-actions/Lint & Format, check-skipped = @github-actions/Lint & Format |
GitHub repository ruleset rule master |
| ✅ | any of: check-success = @github-actions/Rust Test & NAPI Build, check-neutral = @github-actions/Rust Test & NAPI Build, check-skipped = @github-actions/Rust Test & NAPI Build |
GitHub repository ruleset rule master |
| ✅ | any of: check-success = @github-actions/JS Test (Ubuntu), check-neutral = @github-actions/JS Test (Ubuntu), check-skipped = @github-actions/JS Test (Ubuntu) |
GitHub repository ruleset rule master |
| ✅ | any of: check-success = @github-actions/Conventional Commit title, check-neutral = @github-actions/Conventional Commit title, check-skipped = @github-actions/Conventional Commit title |
GitHub repository ruleset rule master |
| ✅ | any of: check-success = @github-actions/Queue validation, check-neutral = @github-actions/Queue validation, check-skipped = @github-actions/Queue validation |
GitHub repository ruleset rule master |
Times in UTC · dashboard · how the merge queue works
… reads Review findings on the unpacked structure stack (#2415, #2422, #2424) that arrived after it merged: - A `default` pattern item descends into a structure member unless the value is a structure of that member's type (IEEE 1800-2023 10.9.2), so `c = '{default: a}` initializes the nested members of `a`'s type instead of rejecting it. - 4-state object fields store their complemented value and mask planes masked to the field width. Padding bits stay zero, so a default record of a field that is not byte-aligned (`logic flag`) is all zero bytes, and `finish_record` keeps it `null`: `d = new[1]; d[0] = d[0];` no longer wakes `@(d)`. - `q.pop_front` and `q.pop_back` without parentheses are whole elements of a queue of structures. - A `$` index of a queue read through a receiver with a side effect, such as `m[f()][$]`, is rejected: the size behind `$` reads the receiver again, which could name another queue. Change-Id: Ibd97e9c73adb7703a0734ca9fcdedeb66c0a2189
Queues, dynamic arrays and associative arrays of an unpacked structure
type were rejected. A structure of at most 64 bits whose members are all
2-state or all 4-state and hold no handle is kept as its flat value, so
the container's default element is the structure's default. Any other
structure is held as an immutable heap record:
ObjectOp::Boxbuilds arecord from the flat value on
push,insertor an assignment, andObjectOp::Unboxreads it back. Each leaf is a record field, so thecollector traces string and handle members through the record's handle
list, and 4-state members keep their X/Z bits. Record fields are
nullable: the newOBJECT_LOAD_NULLABLEheap operation reads a nullrecord as zeros without a fault, which is the default structure for a
missing associative entry or a new dynamic array element. Records are not
seeded, so they do not draw from the process RNG.
e.mreads a member of an elementq[i],aa[k]or a popped elementdirectly from the record or the flat value, including a handle member's
properties (
q[0].orig.m_type.n). Patterns, typed patterns and values ofthe structure type initialize elements. Comparing containers of records
and sorting structures without
withare rejected, as is writing amember of an element.
Assignment patterns passed to a method argument now receive the formal's
shape, which method calls taking a structure need.
Depends-On: #2419