Sam Clegg

Results 1242 comments of Sam Clegg

> yeah. GCC does, Clang does, and MSVC does. not only they provide the runtime, but because OpenMP is an extension to C, C++ and Fortran, compilers also perform code...

No, there is no mechanism for that I'm afraid. I'm not sure I'd want to add one either. What would your use case be fore exports so many functions? Normally...

The reason I think we don't have that mechism is that in general raw C/C++ are not very useful when exposed to JavaScript. Do you intend to try to call...

Maybe take a look at the test_fetch_sync_xhr test in the browser test suite? This test passed for me when I run `./test/runner browser.test_fetch_sync_xhr`

Is `req.attr` correctly initialized? e.g. with `emscripten_fetch_attr_init(...);`?

I ran the code in test.zip and it appeared to work just fine. Perhaps this issue has been fixed in the intervening year. Can you confirm?

While we could emulate these system calls, its probably best to recommend that folks compile their project assuming that these don't exist, since we don't actually have any memory mapping...

I did notice in #18062 that emscripten does support `fmemopen`.. but that returns a `FILE*` and no a `fd` (and `fileno()` doesn't work on that file handle). Would that be...

You can also use the JS `FS_createDataFile` API and pass a heap subarray along with `canOwn=true`. See https://github.com/emscripten-core/emscripten/blob/b3c25673f53974ff1f30df43701dc63af7cbbdc4/src/library.js#L2843-L2844 for an example of how to do that.

If you are looking for VFS solution in C code then you should probably look at WASMFS if you haven't already. Its the new emscripten VFS layer that is designed...