futhark
Safe HaskellNone
LanguageGHC2021

Futhark.CodeGen.Backends.GenericWASM

Description

Code generation shared by the WASM backends. The JavaScript API is in rtsjavascriptwrappers.js, driven by the manifest.

Synopsis

Documentation

emccExportNames :: Manifest -> [String] Source #

The names of the C functions that must be exported from the WebAssembly module. This is every function named in the manifest, as the server calls these directly, as well as the context management functions.

javascriptWrapper :: Manifest -> Text Source #

The JavaScript code passed to emcc with --extern-post-js.

runServer :: Text Source #

Javascript code that can be appended to the generated module to run a Futhark server instance when it is loaded.

libraryExports :: Text Source #

The names exported by the generated module.