Skip to main content

All Questions

Tagged with
0 votes
1 answer
43 views

Why use WASI if WASM supported languages have their own standard libraries?

I might have a fundamental misunderstanding about WASM, tried to google it and read some of the docs, but it is not clear to me yet. As far as I understand, WASI is an language agnostic API for many ...
Matheus de Moraes Peixoto's user avatar
1 vote
1 answer
18 views

WebAssembly wait & notify not working across wasi threads

I'm trying to make a thread_join function in WebAssembly by setting a mutex to 1 in the main thread, and then launching a thread. the thread unlocks its mutex before exiting. the main thread can get ...
Ali Qanbari's user avatar
  • 3,081
0 votes
1 answer
51 views

wasmtime example doesn't run

I am currently exploring the add example for wasm component which is wasi-0.2, from wasmtime component doc diligently following their example, unfortunately it doesn't run #[allow(warnings)] mod ...
Joshua Aruokhai's user avatar
0 votes
0 answers
65 views

What is the best way to compile Python code to WASI?

I have a Python script that reads a file from a path. For what I know, compiling the script to WebAssembly will require to make use of WASI, as the script needs to access system calls to read the file....
Nuno Lima's user avatar
0 votes
0 answers
46 views

Read/write stdin/stdout of a WASI module in Node

Node's experimental WASI interface seems to support stdin & stdout, however instead of returning some kind of streams (WritableStream / ReadableStream seem like the obvious choice), you have to ...
Timmmm's user avatar
  • 93.6k
1 vote
0 answers
104 views

Error loading WASM module: [TypeError: WebAssembly.instantiate(): Import #0 module="go" error: module is not an object or function]

Hey guys i stuck on try to pass connection from nodejs to wasm. i successfully deploy it using "node server.js" it open on localhost port 8080. but when i want to test the result this is the ...
Novel Nouvel's user avatar
0 votes
0 answers
138 views

Compile clang into WASM using WASI-SDK

I'm trying to compile "clang" and "lld" into web assembly with the WASI-SDK 21.0 as my system root directory. I got build errors while compiling but I cannot resolve them properly. ...
Michael's user avatar
  • 327
0 votes
0 answers
22 views

WAMR: relocation truncated to fit' when build with pthread library

I am trying to compile WAMR with pthread library on zephyr os. I used the command in the root of my project: west build . -b qemu_cortex_a53 -p always -- -DWAMR_BUILD_LIB_PTHREAD=1 -DWAMR_BUILD_TARGET=...
Loki00's user avatar
  • 271
1 vote
0 answers
135 views

golang wasm:Remove the content of golang compilation wasm import wasi_snapshot_preview1

When I use Golang to compile into wasm, (import "wasi_snapshot_preview1" "fd_write" (func $runtime.fd_write (type 2))) will be introduced, but the environment running wasm does not ...
Abel's user avatar
  • 51
2 votes
0 answers
76 views

Would it be possible to run a Blazor server app with WASI?

I know that WASI is still experimental in Dotnet, but would it be possible to run a Blazor server app with WASI ? I tried to add the wasi-wasm tag in the project file and adding the wasi-experimental ...
Michel Adey's user avatar
0 votes
0 answers
132 views

WASI interface in wasmtime-dotnet print to stdout

I'm trying to use the WASI interface in wasmtime-dotnet . I am trying to print to stdout. - I also want to read input and so on. Here's the WebAssembly Text (wat) code that I'm using for testing: (...
Troels Lund's user avatar
2 votes
1 answer
360 views

Accessing file system with Go WASI throws "Bad file number" error

I'm trying out Go's newly added support for the WebAssembly System Interface (WASI). I'm attempting to access OS resources, such as the file system. package main import "os" func main() { ...
OptimusePrime's user avatar
3 votes
3 answers
1k views

Will Go 1.21 include ability to host http via WebAssembly? How?

I'd like to try an http server via WebAssembly on Go. I think that compiling go for webassembly outside the browser is not supported in go 1.20, and that the net/http libraries aren't included in ...
Tyler's user avatar
  • 55
2 votes
0 answers
84 views

Golang cannot compile wasmer

Am trying to build a simple go file, with the following contents: package main import ( _ "embed" "fmt" "log" "github.com/mattn/gowasmer" ) //...
nigel239's user avatar
  • 1,727
1 vote
0 answers
207 views

How to compile a Rust project that includes libc dependencies to wasm?

For some reason I need to translate a piece of C code to Rust with c2rust and then compile it to wasm. The Rust code is as follows: extern "C" { fn printf(_: *const libc::c_char, _: ...) ...
Effy's user avatar
  • 11

15 30 50 per page