Skip to content

Commit e7a4853

Browse files
committed
Remove createDyncallWrapper and its usage
This change effectively reverts emscripten-core#17328. IIUC the `dynCall_xxx` helpers for a given side module should always be exported by that side module. i.e. for all possible indirect calls a `dynCall_xxx` wrapper should already exist either in the main module or the side module.
1 parent 5a4df0f commit e7a4853

File tree

5 files changed

+0
-205
lines changed

5 files changed

+0
-205
lines changed

src/library.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1855,9 +1855,6 @@ addToLibrary({
18551855
$dynCalls: '{}',
18561856
#endif
18571857
$dynCallLegacy__deps: [
1858-
#if MAIN_MODULE == 1
1859-
'$createDyncallWrapper'
1860-
#endif
18611858
#if MINIMAL_RUNTIME
18621859
'$dynCalls',
18631860
#endif
@@ -1887,11 +1884,6 @@ addToLibrary({
18871884
#if MINIMAL_RUNTIME
18881885
var f = dynCalls[sig];
18891886
#else
1890-
#if MAIN_MODULE == 1
1891-
if (!('dynCall_' + sig in Module)) {
1892-
Module['dynCall_' + sig] = createDyncallWrapper(sig);
1893-
}
1894-
#endif
18951887
var f = Module['dynCall_' + sig];
18961888
#endif
18971889
return f(ptr, ...args);

src/library_makeDynCall.js

Lines changed: 0 additions & 154 deletions
This file was deleted.

src/modules.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ export const LibraryManager = {
5757
'library_html5.js',
5858
'library_stack_trace.js',
5959
'library_wasi.js',
60-
'library_makeDynCall.js',
6160
'library_eventloop.js',
6261
'library_promise.js',
6362
];

test/test_other.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14246,15 +14246,6 @@ def test_warn_once(self):
1424614246
''')
1424714247
self.do_runf('main.c', 'warning: foo\ndone\n')
1424814248

14249-
def test_dyncallwrapper(self):
14250-
self.set_setting("MAIN_MODULE", 1)
14251-
expected = """\
14252-
2 7
14253-
i: 2 j: 8589934599 f: 3.120000 d: 77.120000
14254-
j1: 8589934599, j2: 30064771074, j3: 12884901891
14255-
"""
14256-
self.do_runf("test_runtime_dyncall_wrapper.c", expected)
14257-
1425814249
def test_compile_with_cache_lock(self):
1425914250
# Verify that, after warming the cache, running emcc does not require the cache lock.
1426014251
# Previously we would acquire the lock during sanity checking (even when the check

test/test_runtime_dyncall_wrapper.c

Lines changed: 0 additions & 33 deletions
This file was deleted.

0 commit comments

Comments
 (0)