Skip to content

Exception support: Compatibility with LLVM 17 #3087

Open
@fredldotme

Description

@fredldotme

The problem:

WAMR with its current exception-handling branch has some support for it but various things happened in the meantime: new proposals getting made, and probably implemented.

So much so that the current LLVM 17 upstream stable is unable to function properly as a compilation toolchain for exception-handling support, not even with this fork of it: https://github.com/fredldotme/llvm-project

How to test:

Invoking bash bootstrap.sh on macOS/bash boostrap.sh --linux on GNU/Linux should then lead you to getting a full Clang environment set up that is able to build WASI using CMake (without Emscripten).

The status quo:

Right now running two binaries creates two different results, both failing in proper exception handling:

  • { printf("Hello\n"); throw; } results in an exception from the WAMR environment rather than the WASM binary
  • More sophisticated C++ linking against libcxx{,abi} might cause it to get code emitted which has unknown label errors thrown at WAMR runtime.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions