Skip to content

Use a JS Type Reflection based trampoline if possible#3955

Closed
hoodmane wants to merge 6 commits intopyodide:mainfrom
hoodmane:type-reflection-trampoline
Closed

Use a JS Type Reflection based trampoline if possible#3955
hoodmane wants to merge 6 commits intopyodide:mainfrom
hoodmane:type-reflection-trampoline

Conversation

@hoodmane
Copy link
Copy Markdown
Member

This is split off from #3210 and on top of #3954.

When type reflection is available, this uses an alternate trampoline that
inspects how many arguments the function actually needs and then chooses the
appropriate call with a switch block. This is necessary to use JSPI because
it does not interact well with trampolines.

This code will be used on Chrome and Safari but not Firefox. As far as I can tell it's
performance neutral.

hoodmane and others added 5 commits June 23, 2023 14:48
This is split off from pyodide#3210
…able

When type reflection is available, this uses an alternate trampoline that
inspects how many arguments the function actually needs and then chooses the
appropriate call with a switch block. This is necessary to use JSPI because
it does not interact well with trampolines
hoodmane added a commit to hoodmane/pyodide that referenced this pull request Jun 28, 2023
This is a replacement for pyodide#3954 and pyodide#3955 structured as an upstream
patch
@hoodmane
Copy link
Copy Markdown
Member Author

Closed in favor of #3964

@hoodmane hoodmane closed this Jun 29, 2023
hoodmane added a commit to hoodmane/pyodide that referenced this pull request Jul 7, 2023
This is a replacement for pyodide#3954 and pyodide#3955 structured as an upstream
patch
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.

1 participant