Skip to content

SIMD-406: Restrict to 255 the number of accounts in instructions for transactions v0 and legacy#520

Closed
LucasSte wants to merge 1 commit into
anza-xyz:masterfrom
LucasSte:simd-406-1
Closed

SIMD-406: Restrict to 255 the number of accounts in instructions for transactions v0 and legacy#520
LucasSte wants to merge 1 commit into
anza-xyz:masterfrom
LucasSte:simd-406-1

Conversation

@LucasSte
Copy link
Copy Markdown
Contributor

@LucasSte LucasSte commented Jan 8, 2026

In SIMD-406, we proposed that v0 and legacy transaction sanitization must now have an extra check to limit the number of accounts per instruction to 255.

This PR implements this check behind a boolean flag that will be coupled with a feature gate in Agave.

@LucasSte LucasSte requested review from Lichtso and jstarry January 8, 2026 21:20
@LucasSte LucasSte marked this pull request as ready for review January 8, 2026 21:20
@LucasSte LucasSte requested a review from a team as a code owner January 8, 2026 21:20
Comment thread sanitize/src/lib.rs
/// - All values are within their static max/min bounds.
pub trait Sanitize {
fn sanitize(&self) -> Result<(), SanitizeError> {
fn sanitize(&self, _limit_ix_accounts_simd_406: bool) -> Result<(), SanitizeError> {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are a lot of things in the agave repo that implement this trait so I don't think it's a good idea to change this trait method. Check out anza-xyz/agave#8182 for another approach that doesn't involve changing the Sanitize trait. After these features are activated we can update the Sanitize implementation in the SDK without a boolean for the feature.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the hint. I'll follow an approach similar to the PR you pointed.

@LucasSte
Copy link
Copy Markdown
Contributor Author

LucasSte commented Feb 2, 2026

Superseded by anza-xyz/agave#10223.

@LucasSte LucasSte closed this Feb 2, 2026
@LucasSte LucasSte deleted the simd-406-1 branch February 2, 2026 15:21
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