Skip to content

Fix/comp terminal predicate rtl#305

Open
guosran wants to merge 1 commit into
tancheng:masterfrom
guosran:fix/comp-terminal-predicate-rtl
Open

Fix/comp terminal predicate rtl#305
guosran wants to merge 1 commit into
tancheng:masterfrom
guosran:fix/comp-terminal-predicate-rtl

Conversation

@guosran

@guosran guosran commented Jun 23, 2026

Copy link
Copy Markdown
Collaborator

Summary

Addresses #292 with a minimized terminal compare predicate fix. This PR only updates CompRTL.py and its focused test.

Changes

  • Let terminal EQ_CONST/NE_CONST comparisons produce the loop-control predicate when the vector factor is reached.
  • Add a concrete example as an inline test comment.

No new ports or interfaces are introduced.

@guosran guosran changed the base branch from master to kernel-submit June 23, 2026 21:07
@guosran

guosran commented Jun 24, 2026

Copy link
Copy Markdown
Collaborator Author

This PR is intentionally separated from #297 because the predicate semantics may need discussion. The intended case is terminal loop comparison: when the vector factor is reached, EQ_CONST/NE_CONST produces the loop-control predicate even if the incoming data token predicate is false.

@guosran guosran force-pushed the fix/comp-terminal-predicate-rtl branch from 354fcb1 to abcbc50 Compare June 25, 2026 14:43
@guosran guosran changed the base branch from kernel-submit to master June 25, 2026 14:50
@guosran guosran marked this pull request as draft June 25, 2026 14:51
@guosran guosran force-pushed the fix/comp-terminal-predicate-rtl branch from abcbc50 to 794c491 Compare June 25, 2026 19:46
@guosran guosran marked this pull request as ready for review June 26, 2026 00:35
@guosran

guosran commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator Author

Concrete example:
A terminal comparison should preserve predicate behavior when using const comparisons.

input payload = 7, predicate = 1
operation = >= const 7

Expected:
output indicates true and remains predicated.

If predicate is 0:
comparison result should not become an active terminal result.

Comment thread fu/single/CompRTL.py
Comment thread fu/single/CompRTL.py
Comment thread fu/single/CompRTL.py
@tancheng tancheng requested review from BenkangPeng and yyan7223 June 26, 2026 20:23
@guosran guosran force-pushed the fix/comp-terminal-predicate-rtl branch from 794c491 to 924a63c Compare June 26, 2026 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants