-
Notifications
You must be signed in to change notification settings - Fork 8
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
Include space for small function parameters/local variables in scratch space. - [merged] #343
Comments
In GitLab by @isd on May 9, 2021, 05:10 added 6 commits
|
In GitLab by @isd on May 11, 2021, 04:49 added 2 commits
|
In GitLab by @isd on May 11, 2021, 04:54 Ok, I added some tests. Per discussion on discord, the assets2 branch just uses I think we can merge this as is, though there may be follow-on tasks. |
In GitLab by @isd on May 11, 2021, 10:16 The source of the failure appears to be that the new test needs a running test net, but we don't currently set one up for the unit tests. In principle, it seems like the new test shouldn't need one, since it's not actually deploying or running the contract, but without the So options:
My inclination is (1). Thoughts? |
In GitLab by @isd on May 12, 2021, 07:32 Ok, went ahead with (1) -- hopefully that will fix the CI issue. |
In GitLab by @isd on May 9, 2021, 05:04
Merges scratch-space -> master
This partially addresses #106, though this still doesn't reserve space for global variables. I'm not totally sure what that should look like, since we don't have any right now. I'm curious to hear from @AlexKnauth how storing the deposit amounts for different assets is going to work, since that's going to be our first usage of it.
For now, this is a fairly trivial change, as we were already computing this as params-end and just needed to actually stick it in the binary. It includes some normative comments -- I think the control flow here is not great.
I don't have automated tests currently, though I did some fiddling with various glow programs to make sure adding & removing variables has the right effect on the size of the scratch space, and it does. Automating this might take some non-trivial refactoring -- I'll look into it a bit more tomrrow or Monday.
The text was updated successfully, but these errors were encountered: