Skip to content

WASM build #1502

@oscargus

Description

@oscargus

@Immortalin a webassembly port is definitely an interesting project, but requires a lot more work than just getting it to build with emcc. For example we use dlopen to load the shared library generated by LLVM from the filesystem. That doesn't really make sense in the browser, where I guess we'd need a separate backend that generates WASM/JS directly. The fixes for Windows were just replacing the unix calls with Windows equivalents - e.g. dlopen -> LoadLibrary.

Originally posted by @nickg in #306

I thought I'd open an issue about this for possible discussion and steps towards it.

So far, I have not been able to build NVC using emscripten/emcc, so not much to report there (and I didn't even get to the issues mentioned above).

For reference, it is now possible to run clang/LLVM in WASM: https://codeberg.org/YoWASP/clang

A possible use case (the one I am primarily driven by) is a VHDL version of VGA Playground (which currently runs a pre-compiled version of Verilator if I understand it correctly): https://vga-playground.com/ https://github.com/TinyTapeout/vga-playground/

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions