Remove createDyncallWrapper and its usage#22825
Conversation
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.
|
@hoodmane, can you explain your use case a little more and why #17328 was needed in the first place? How were you able to create a side module without the corresponding |
|
Its also possible that you were using RTLD_LOCAL, in which case you use case should have been fixed by #22625. |
|
@hoodmane, could you take a look? I don't want to remove this feature you added if its going to break your use case. |
|
I'll try to look into it later this week, but if it causes a problem we can always just revert it downstream. Emscripten is quite easy to patch thankfully. As far as I understand my original messages, the problem only comes up from Rust shared libraries when |
Right, if that is the case I would hope we wouldn't have to support that use case upstream. i.e. linking side modules built with |
To be clear, I was never attempting to use .so files with a different setting than the main module. Using |
Ah, I think that should no longer be an issue after #22625. The side module should always export any dynCall helpers that it could need (same with the main module). |
To confirm do you use RTDL_LOCAL when loading these side module (#22625 was specifically for that mode). |
kripken
left a comment
There was a problem hiding this comment.
lgtm if the current discussion does not find a remaining use for this.
|
I'll wait to hear back from @hoodmane if |
|
Yeah we're using RTLD_LOCAL. So I think there are several reasons we don't need this. |
|
Thanks for checking @sbc100! |
Awesome. In that case I feel pretty confident landing this change since I believe #22625 handled that case. |
This change effectively reverts #17328.
IIUC the
dynCall_xxxhelpers for a given side module should always be exported by that side module. i.e. for all possible indirect calls adynCall_xxxwrapper should already exist either in the main module or the side module.