Conversation
There was a problem hiding this comment.
Pull request overview
Updates bank eviction/pruning to also cancel replay-related fork state (txncache/accdb/progcache) when dead banks are pruned, addressing replay eviction consistency.
Changes:
- Extends
fd_banks_prune_dead_banksto accept txncache/accdb_admin/progcache_admin handles and perform fork cancellation during pruning. - Updates replay tile to pass the required handles and removes the prior FIXME.
- Updates bank tests to match the new
fd_banks_prune_dead_bankssignature.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
src/flamenco/runtime/test_bank.c |
Updates unit tests to call the new prune API signature with NULL optional args. |
src/flamenco/runtime/fd_bank.h |
Changes prune API signature and adds forward declarations for new parameter types. |
src/flamenco/runtime/fd_bank.c |
Implements fork cancellation (txncache/accdb/progcache) when pruning dead replayable banks. |
src/discof/replay/fd_replay_tile.c |
Passes replay tile state (txncache/accdb/progcache) into bank pruning. |
|
|
||
| struct fd_txncache_private; | ||
| typedef struct fd_txncache_private fd_txncache_t; | ||
|
|
||
| struct fd_accdb_admin; | ||
| typedef struct fd_accdb_admin fd_accdb_admin_t; | ||
|
|
||
| struct fd_progcache_admin; | ||
| typedef struct fd_progcache_admin fd_progcache_admin_t; | ||
|
|
There was a problem hiding this comment.
The new forward typedefs for fd_txncache_t / fd_accdb_admin_t / fd_progcache_admin_t are likely to cause typedef redefinition errors in any TU that includes this header alongside the canonical headers that already typedef these names (e.g. fd_txncache.h, fd_accdb_base.h/fd_accdb_admin.h, fd_progcache_admin.h). For example, fd_bank.c now includes fd_txncache.h after fd_bank.h, which will redeclare fd_txncache_t. Prefer removing these typedefs from fd_bank.h and either (a) include the canonical header(s) that define the typedefs, or (b) use only struct ...; forward declarations and change the prune API to accept struct fd_* * parameters to avoid needing the typedefs here.
| struct fd_txncache_private; | |
| typedef struct fd_txncache_private fd_txncache_t; | |
| struct fd_accdb_admin; | |
| typedef struct fd_accdb_admin fd_accdb_admin_t; | |
| struct fd_progcache_admin; | |
| typedef struct fd_progcache_admin fd_progcache_admin_t; | |
| #include "fd_txncache.h" | |
| #include "fd_accdb_admin.h" | |
| #include "fd_progcache_admin.h" |
Performance Measurements ⏳
|
e7d29cc to
4770ae7
Compare
Performance Measurements ⏳
|
No description provided.