Skip to content

Conversation

@febo
Copy link
Collaborator

@febo febo commented Jul 19, 2025

Problem

PR #176 refactored the entrypoint and inlined the processing of accounts, but the parsing of duplicated accounts is wrongly storing the address to an AccountInfo instead of an Account.

Solution

Dereference the AccountInfo to store the address of its Account. The PR also includes a test for duplicated account parsing.

As a side-effect of the fix, CU consumption improved:

Name CUs Delta from current
Account (0) 9 --
Account (1) 13 --
Account (2) 13 -8
Account (3) 33 -1
Account (4) 41 -1
Account (5) 48 -1
Account (6) 63 -1
Account (7) 67 -1
Account (8) 74 -1
Account (16) 139 -1
Account (32) 257 -1
Account (64) 500 -1

cc: @cavemanloverboy

Fixes #208

@febo febo requested review from ilya-bobyr and joncinque July 19, 2025 11:09
@febo febo marked this pull request as ready for review July 19, 2025 11:12
ilya-bobyr
ilya-bobyr previously approved these changes Jul 19, 2025
joncinque
joncinque previously approved these changes Jul 21, 2025
Copy link
Collaborator

@joncinque joncinque left a comment

Choose a reason for hiding this comment

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

Ah too bad this snuck in, but looks good to me! I feel silly because I almost asked for a test with duplicates in the previous PR.

@febo
Copy link
Collaborator Author

febo commented Jul 21, 2025

Ah too bad this snuck in, but looks good to me! I feel silly because I almost asked for a test with duplicates in the previous PR.

I feel the same. There was not a good reason not to include one.

Copy link
Collaborator

@joncinque joncinque left a comment

Choose a reason for hiding this comment

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

Looks great, thanks!

@febo febo merged commit ed37b7c into main Jul 22, 2025
10 checks passed
@febo febo deleted the febo/dup-accounts branch July 22, 2025 00:01
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.

Instruction invokes broken

4 participants