stacks-network / stacks-core

The Stacks blockchain implementation
https://docs.stacks.co
GNU General Public License v3.0
3.01k stars 672 forks source link

Split `get-(burn)-block-info` linker function #5481

Open BowTiedWoo opened 2 days ago

BowTiedWoo commented 2 days ago

This PR splits get-block-info and get-burn-block-info so every property has its own linked function in order to avoid pushing every property of the get-block-info and get-burn-block-info functions to the stack once they are called.

e.g. when the function get-block-info is compiled, the compiler generates the code for all the available properties. With this change, when get-block-info is compiled it will generate only the property that is called.

Related issue: https://github.com/stacks-network/clarity-wasm/issues/430