I'm also interested in having a core of a system that pulls in "DLLs" later that can access the same HEAP8.
It seems that there is some support for DLLs/.so ... which means being able to share pointers with the code that loaded them (hence same heap):
This makes use of something called "SIDE_MODULE" which is a more basic form of compilation that doesn't include system libraries, and you attach it to some heap that's already around, or that you create. You can also use this to make more bare-bones WASM code that doesn't have all of emscripten's overhead, a (possibly outdated) demo is here:
The page points out a problem I'd wondered about trying to use a SIDE_MODULE:
"The one tricky aspect to this design is that a side module might need a system library that the main doesn't know about."
So it looks like you might wind up having to make a fairly "fat" main module if you want to cover the contingencies of arbitrary SIDE_MODULEs that came along later.