Skip to content

Remove C++ dependency from wasmtime - #1365

Merged
alexcrichton merged 2 commits into
bytecodealliance:masterfrom
alexcrichton:no-cpp
Mar 20, 2020
Merged

Remove C++ dependency from wasmtime#1365
alexcrichton merged 2 commits into
bytecodealliance:masterfrom
alexcrichton:no-cpp

Conversation

@alexcrichton

Copy link
Copy Markdown
Member

This commit removes the last wads of C++ that we have in wasmtime,
meaning that building wasmtime no longer requires a C++ compiler. It
still does require a C toolchain for some minor purposes, but hopefully
we can remove that over time too!

The motivation for doing this is to consolidate all our signal-handling
code into one location in one language so you don't have to keep
crossing back and forth when understanding what's going on. This also
allows us to remove some extra cruft that wasn't necessary from the C++
original implementation. Additionally this should also make building
wasmtime a bit more portable since it's often easier to acquire a C
toolchain than it is to acquire a C++ toolchain. (e.g. if you're
cross-compiling to a musl target)

This commit removes the last wads of C++ that we have in wasmtime,
meaning that building wasmtime no longer requires a C++ compiler. It
still does require a C toolchain for some minor purposes, but hopefully
we can remove that over time too!

The motivation for doing this is to consolidate all our signal-handling
code into one location in one language so you don't have to keep
crossing back and forth when understanding what's going on. This also
allows us to remove some extra cruft that wasn't necessary from the C++
original implementation. Additionally this should also make building
wasmtime a bit more portable since it's often easier to acquire a C
toolchain than it is to acquire a C++ toolchain. (e.g. if you're
cross-compiling to a musl target)
Comment thread crates/runtime/src/traphandlers.rs Outdated
Comment thread crates/runtime/src/traphandlers.rs Outdated

@sunfishcode sunfishcode left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great simplification that makes some of the scariest code in Wasmtime less scary :-).

@alexcrichton
alexcrichton merged commit f700efe into bytecodealliance:master Mar 20, 2020
@alexcrichton
alexcrichton deleted the no-cpp branch March 20, 2020 20:21
@sunfishcode sunfishcode mentioned this pull request Mar 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants