Open partylikeits1983 opened 3 months ago
@developedby I'd like to work on this issue. Is there anything you think I should look into before implementing this?
It's not really possible to add this at this moment with good performance.
I think it makes more sense to implement these functions in Bend and then optimize HVM to run these functions efficiently.
Right now you could implement it as a dynamic IO library or as a fork of HVM that has the basic operations as primitives, but it's not really possible to run all of a hash in a single step. You'd need to either add operations that run on lists (tuple lists for the most dense possible HVM representation) or add native array types with their own set of interactions, which would be a bit more complicated.
@developedby Thanks for the heads up! I'll start with one hash function as a prototype and see what works best. If I have any questions, I'll reach out.
Is your feature request related to a problem? Please describe. Not a problem, but a feature request. It would be extremely useful to have various hash functions and other cryptographic primitives inside of bend.
Describe the solution you'd like Having standard hash functions such as SHA256 or keccak256, and then ZK oriented hash functions such as Poseidon2, Blake3, RPO, would make Bend a bombshell in the cryptography / blockchain engineering world.
Describe alternatives you've considered Implementing these hash functions natively in Bend would be time intensive, I was wondering if it is possible to import rust hash function implementations into bend.