Skip to content
This repository was archived by the owner on Nov 3, 2021. It is now read-only.

[spec] Runtime format of element and data segments #91

Merged
merged 2 commits into from
May 31, 2019
Merged

[spec] Runtime format of element and data segments #91

merged 2 commits into from
May 31, 2019

Conversation

binji
Copy link
Member

@binji binji commented May 24, 2019

This is copied and modified from this closed PR:

#19

This is copied and modified from this closed PR:

#19
@binji binji requested a review from rossberg May 24, 2019 00:38
Copy link
Member

@rossberg rossberg left a comment

Choose a reason for hiding this comment

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

This looks correct. However, wouldn't it be more appropriate if an eleminst held a vector of references? The expressions from the segment should be evaluated only once, during instantiation of the module.

To model this, instead of a data segment, allocelem would take the vector of refs as parameter, and the evaluation would occur in the module instantiation rule, analogous to the init values for globals.

For symmetry, allocdata should take a plain byte vector as parameter as well.

@binji
Copy link
Member Author

binji commented May 28, 2019

Yes, that makes sense. I'll update the PR

@binji binji merged commit a976b82 into master May 31, 2019
@binji binji deleted the runtime branch May 31, 2019 00:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants