Commit Graph

4 Commits

Author SHA1 Message Date
Geza Lore d864057a60
Internals: Refactor AstNodeBlock representation (#6280) (#6588)
Internals: Refactor AstNodeBlock representation (#6280)

AstNodeBlock now has 2 child lists: 'declsp' to hold declarations within
the block, and 'stmtsp' to hold the procedural statements.

AstBegin is then just a simple subtype of AstNodeBlock.

AstFork is a proper superset of AstNodeBlock (and also AstBegin), and
adds 'forksp' which hold the parallel statements. Having the sequential
'stmtsp' in AstFork is required to properly implement variable
initializers in fork blocks (IEEE 1800-2023 9.3.2), this makes that
clear, while also separating the non AstNodeStmt declarations
(for #6280). The actual fork branches in 'AstFork::forkps()' are all
AstBegin nodes. This is required as lowering stages will introduce
additional statements in each parallel branch. (We used to wrap AstFork
statements into AstBegin in 3 different places, now they always are
AstBegin and this is enforced via the type checker/V3Broken).

Also fixes incorrect disabling of forked processes from within the `fork`.
2025-10-24 14:00:07 +01:00
Wilson Snyder 907047d823 Tests: Remove unneeded AUTOARGS. No test change. 2025-09-13 09:28:43 -04:00
Ryszard Rozak ac21d25d43
Support simple disable within task (#6334) 2025-08-26 10:39:24 -04:00
Ryszard Rozak 3d3462b209
Support disabling a fork from within that fork (#6314) 2025-08-20 12:21:07 -04:00