You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following crate can not get extract to F* with hax right now. It allocates a lot of memory and uses CPU cycles but does not seem to finish (I stopped it after 10 minutes).
use hmac::{Hmac,Mac};use sha2::Sha256;pubfnhmac(){letmut m = Hmac::<Sha256>::new_from_slice(&[13;16]).unwrap();
m.update(&[9;32]);let _mac = m.finalize().into_bytes().to_vec();}
Use cargo add hmac sha2 to add the required dependencies.
The text was updated successfully, but these errors were encountered:
I looked at this issue yesterday.
In import_thir, the slow part is not so much importing, but renaming local instance names.
The problem is not about this specific operation, but about visitors: types are repeated a lot, and visiting such an AST is slow.
This issue exists with every visitor and phase in the AST, and I'm not sure how to deal with that.
One thing I tried is getting rid of Sized constraints, but that was not enough. Also, I tried to memoize some nodes in the import phase, but that doesn't impact much the performances.
We may need to do some sort of automatic memoization in the visitors and/or the phases, but since OCaml is an effectful language, that might be hard to do.
The good news is since we generate ourselfs visitors, we can do whatever we want.
The following crate can not get extract to F* with hax right now. It allocates a lot of memory and uses CPU cycles but does not seem to finish (I stopped it after 10 minutes).
Use
cargo add hmac sha2
to add the required dependencies.The text was updated successfully, but these errors were encountered: