Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #3197 #3221

Merged
merged 17 commits into from
Oct 18, 2022
Merged

Fix #3197 #3221

merged 17 commits into from
Oct 18, 2022

Conversation

fschutt
Copy link
Contributor

@fschutt fschutt commented Oct 10, 2022

Fixes #3197

@fschutt fschutt requested a review from syrusakbary as a code owner October 10, 2022 09:07
@fschutt fschutt marked this pull request as draft October 10, 2022 09:07
@fschutt fschutt marked this pull request as ready for review October 10, 2022 09:27
@fschutt
Copy link
Contributor Author

fschutt commented Oct 11, 2022

@syrusakbary wasmtime has a different architecture in this section, which is why they can just return self.vec.len() for the minimum, while we use a "descriptor", so we have to update it every time the table is grown or shrunk.

@syrusakbary
Copy link
Member

We need to address this based on today's latest review (check the length, not just the descriptor minimum, on link time)

Copy link
Member

@syrusakbary syrusakbary left a comment

Choose a reason for hiding this comment

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

It looks great, although we forgot to update the is_memory_compatible with the same fix as we did in the table

@fschutt
Copy link
Contributor Author

fschutt commented Oct 14, 2022

@syrusakbary yeah I wasn't sure if I should do that

@syrusakbary
Copy link
Member

As long as that's done we should be good to merge

Copy link
Contributor

@Michael-F-Bryan Michael-F-Bryan left a comment

Choose a reason for hiding this comment

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

LGTM 👍

I've got a couple queries, but they're more so I can understand the decision (e.g. u32 vs usize) or to make troubleshooting test_table_grow_3197() easier if it ever fails down the track.

lib/vm/src/table.rs Show resolved Hide resolved
lib/api/src/sys/externals/table.rs Outdated Show resolved Hide resolved
lib/api/src/sys/externals/table.rs Show resolved Hide resolved
@fschutt
Copy link
Contributor Author

fschutt commented Oct 14, 2022

@syrusakbary I have no idea why the Linux CI doesn't run, otherwise tests should pass now.

@syrusakbary syrusakbary merged commit 2fa4b90 into master Oct 18, 2022
@bors bors bot deleted the fix-3197 branch October 18, 2022 08:29
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.

Incompatible import type for resized table
3 participants