Stream: cull-os

Topic: WASM + WASI for running Cab on the builder to do the buil...


view this post on Zulip RGBCube (Oct 26 2024 at 16:11):

This is just a very experimental idea, but I mentioned before that realizers will support WASM execution (for truly cross platform island->derivation conversion) and I thought: Why not do this for Cab itself?

view this post on Zulip RGBCube (Oct 26 2024 at 16:17):

\program = runtime ==> (
  execute "${lib.getExe packages.cargo}" [ "build" ];
  exit 0
);

derive {
  features = [ "wasm" ],

  command = ./cab-runtime.wasm,
  arguments = [ (lib.compile program).wasmExecutablePath ],
}

view this post on Zulip RGBCube (Oct 26 2024 at 16:18):

This is definitely worth exploring IMO

view this post on Zulip RGBCube (Oct 26 2024 at 16:24):

Here we have a minimal WASM runtime for Cab (via Rust WASM cross compilation) that runs Cab bytecode (made to be tiny)

view this post on Zulip RGBCube (Oct 26 2024 at 16:31):

@Tim DeHerrera @Andreas what do you guys think?

view this post on Zulip Tim DeHerrera (Oct 26 2024 at 16:34):

so the "builder" is a wasm binary, essentialy?

view this post on Zulip RGBCube (Oct 26 2024 at 19:46):

Yup

view this post on Zulip Tim DeHerrera (Oct 26 2024 at 21:29):

looks like someone just asked a similar question to the tvix guys, might be good to review their response:
https://matrix.to/#/!YUnRYAzgytLSZbBhbx:hackint.org/$Sbspe2NOL3nYD2MQnmARWrnQ0SI2tOfT0GuK3s6qQck?via=hackint.org&via=matrix.org&via=envs.net


Last updated: Nov 15 2024 at 11:45 UTC