Skip to content

Conversation

@hvitved
Copy link
Contributor

@hvitved hvitved commented Jan 24, 2022

This avoids potential combinatorial explosion in SummaryComponentStacks. Until now it has not been a problem, since array indices are limited to 0..5, but with this change we should be able to track arbitrary known indices.

One example is the dig method, where dig(x, y, z) (with unknowns x, y, and z) yields 6^3 SummaryComponentStacks. With this change it yields just a single SummaryComponentStack, regardless of whether we increase the precision of which indices to track.

@github-actions github-actions bot added the Ruby label Jan 24, 2022
@hvitved hvitved marked this pull request as ready for review January 25, 2022 08:14
@hvitved hvitved requested a review from a team as a code owner January 25, 2022 08:14
Copy link
Contributor

@hmac hmac left a comment

Choose a reason for hiding this comment

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

Am I right in thinking that we let array indices range from 0..10? Then it looks like the problem is even worse than you describe, as we'd get 12^3 SummaryComponentStacks for dig(x,y,z) (the 12th being TUnknownArrayElementContent)!

@hvitved
Copy link
Contributor Author

hvitved commented Jan 26, 2022

Am I right in thinking that we let array indices range from 0..10? Then it looks like the problem is even worse than you describe, as we'd get 12^3 SummaryComponentStacks for dig(x,y,z) (the 12th being TUnknownArrayElementContent)!

Correct!

@hvitved hvitved merged commit 2c27a07 into github:main Jan 26, 2022
@hvitved hvitved deleted the ruby/any-array-element-content branch January 26, 2022 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants