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

WebIDL binder: Use WeakRefs in cache #9854

Open
kripken opened this issue Nov 18, 2019 · 2 comments
Open

WebIDL binder: Use WeakRefs in cache #9854

kripken opened this issue Nov 18, 2019 · 2 comments

Comments

@kripken
Copy link
Member

kripken commented Nov 18, 2019

The cache maps C pointers (integers) to JS object wrappers. It
currently keeps objects alive forever. This is normally ok as the
objects should be manually destroy()ed, however, we do allow
wrapping a class as a parent class, and then it ends up in
multiple caches, see kripken/ammo.js#284

Using WeakRefs where available could avoid this. However, until
they are present everywhere, perhaps we could analyze the
inheritance graph and clean up parent caches too, but that may
be tricky especially with multiple/virtual/etc. inheritance.

@stale
Copy link

stale bot commented Nov 19, 2020

This issue has been automatically marked as stale because there has been no activity in the past year. It will be closed automatically if no further activity occurs in the next 30 days. Feel free to re-open at any time if this issue is still relevant.

@stale stale bot added the wontfix label Nov 19, 2020
@kripken kripken removed the wontfix label Nov 19, 2020
@stale
Copy link

stale bot commented Apr 17, 2022

This issue has been automatically marked as stale because there has been no activity in the past year. It will be closed automatically if no further activity occurs in the next 30 days. Feel free to re-open at any time if this issue is still relevant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant