-
Notifications
You must be signed in to change notification settings - Fork 155
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
Expose memory.grow, memory.size, memory.dataLength #79
Comments
Just FYI WebAssembly/spec#649 |
Thanks, hopefully, it only affects text encoding. Might need to adjust some docs etc., |
this would be nice :) |
Implemented by #148 |
Not sure if this is the best place to ask, if I have a function that has to allocate a lot of memory for one operation (say I pass an unusually long array to it), but no more after that, will it keep using up all that memory? |
yea, afaik you can't shrink memory.. if that's what you're asking.. |
Thanks, good to know (that kind of sucks for the things that I was thinking of doing though, because it involves operations on arrays that can get quite big but only incidentally) |
you can always reuse the memory for other stuff.. |
Goal
Unblock work for a full-blown allocator.
Overview
memory_grow
are not available through walt, but can be implemented as members of theMemory
andTable
types.Acceptance Criteria
This should work
Memory.grow()
Memory.size()
current size of memoryMemory.dataSize
length of the data section, always zero until data senction encoding is implemented.The text was updated successfully, but these errors were encountered: