Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrapper lazy instantiation #157

Open
pmdartus opened this issue Jan 18, 2020 · 1 comment · May be fixed by #158
Open

Wrapper lazy instantiation #157

pmdartus opened this issue Jan 18, 2020 · 1 comment · May be fixed by #158

Comments

@pmdartus
Copy link
Member

When playing around with #155 I came to the realization that for each created impl, webidl2js eagerly creates the associated wrapper. However, 99% of the jsdom code operates on the impls not the wrappers, window.js is the only exception. Those wrappers are only needed when userland code manipulates the DOM APIs.

I am wondering if it could be possible to make all the wrapper instantiation lazy to reduce the overall jsdom memory footprint.

@ExE-Boss
Copy link
Contributor

ExE-Boss commented Jan 18, 2020

That would probably also make #155 not cause a 3× slowdown on V8.

@pmdartus pmdartus linked a pull request Jan 20, 2020 that will close this issue
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 a pull request may close this issue.

2 participants