Stream: git-wasmtime

Topic: wasmtime / PR #2065 Refactor Cache logic to include debug...


view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2020 at 21:18):

yurydelendik opened PR #2065 from refactor-cache to main:

Currently, it is a responsibility of the compiler to do caching. Moving this logic to the CompiledModule level. This allows early access to all compilation artifacts without analyzing the wasm file (only bytes hash).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2020 at 22:21):

yurydelendik updated PR #2065 from refactor-cache to main:

Currently, it is a responsibility of the compiler to do caching. Moving this logic to the CompiledModule level. This allows early access to all compilation artifacts without analyzing the wasm file (only bytes hash).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 01:15):

yurydelendik updated PR #2065 from refactor-cache to main:

Currently, it is a responsibility of the compiler to do caching. Moving this logic to the CompiledModule level. This allows early access to all compilation artifacts without analyzing the wasm file (only bytes hash).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 14:31):

yurydelendik has marked PR #2065 as ready for review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 15:25):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 15:25):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 15:25):

alexcrichton created PR Review Comment:

Could Compiler perhaps directly implement Hash?

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 15:25):

alexcrichton created PR Review Comment:

It makes me happy to see this go :fire:

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 15:25):

alexcrichton created PR Review Comment:

Would it be possible to do this in the wasmtime crate itself? The caching architecture is a pretty high-level concern so I think it'd be best if we could migrate it out of the wasmtime-environ crate (or maybe even migrate it to its own crate). It'd be pretty neat if this could be:

let result = cache_entry.get_data((compiler, wasm), CompilationArtifacts::build);

(in wasmtime)

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:03):

yurydelendik updated PR #2065 from refactor-cache to main:

Currently, it is a responsibility of the compiler to do caching. Moving this logic to the CompiledModule level. This allows early access to all compilation artifacts without analyzing the wasm file (only bytes hash).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:03):

yurydelendik submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:03):

yurydelendik created PR Review Comment:

done

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:06):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:06):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:06):

alexcrichton created PR Review Comment:

Is the Env wrapper here needed? I think a tuple of hashtable types shoudl be hashable here

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:06):

alexcrichton created PR Review Comment:

Can this pass CompilationArtifacts::build as a bare function instead of making a closure?

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:06):

alexcrichton created PR Review Comment:

Could this use destructuring like:

let Compiler { field1, field2, } = self;

and then hash each individual field? That way we can be sure we're not forgetting anything if the contents change over time.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:13):

yurydelendik updated PR #2065 from refactor-cache to main:

Currently, it is a responsibility of the compiler to do caching. Moving this logic to the CompiledModule level. This allows early access to all compilation artifacts without analyzing the wasm file (only bytes hash).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:15):

yurydelendik submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:15):

yurydelendik created PR Review Comment:

remove Env, but I do not see how to unwrap tuple to pass to CompilationArtifacts::build as params

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:15):

yurydelendik edited PR Review Comment.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 16:19):

yurydelendik updated PR #2065 from refactor-cache to main:

Currently, it is a responsibility of the compiler to do caching. Moving this logic to the CompiledModule level. This allows early access to all compilation artifacts without analyzing the wasm file (only bytes hash).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 17:10):

alexcrichton created PR Review Comment:

Oops, indeed!

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 17:10):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2020 at 17:10):

alexcrichton merged PR #2065.


Last updated: Dec 23 2024 at 12:05 UTC