Provide the ACI along with the bytecode #771
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "optionally_generate_aci"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hyperchains will be governed by a Sophia smart contract which needs to be called pretty often. Calling the compiler to encode/decode the call data for this smart contract is infeasible because it would introduce a nasty bottleneck in block validation/sync time. Creating an hard coded encoder/decoder for a particular contract would be inelegant and inflexible. The solution we agreed on in the HC team is to create an erlang library which given a particular json ACI creates an encoder/decoder for you(or does the encoding/decoding for you).
In order to test the upcoming helper library we will:
As the core node test suite will start using the ACI helper library it would be inefficient and slow to call the compiler twice - one time for bytecode and the second time for the ACI. This PR allows the compiler to return the ACI without slowing the compilation down(I didn't measure a significant difference in compilation time)
Created by: UlfNorell
Review: Approved
Created by: hanssv
Review: Approved
Created by: erlmachinedev
Review: Approved
Merged by: gorbak25 at 2020-09-10 08:05:51 UTC