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

remove all refops if a basic block is a raising block #1045

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

dlee992
Copy link
Contributor

@dlee992 dlee992 commented Apr 29, 2024

A possible way to
fix #1044

Notes for reviewers:

  • remove all refops if a basic block is a raising block, since we allow memory leak in a raising block
  • put this pruning operation in the per_bb pattern
  • after per_bb pattern removes this case, fanout_raise pattern can do the rest as before

@dlee992 dlee992 changed the title skip hasDecrefInNode and hasAnyDecrefInNode if it's a raise block move isRaising check ahead before hasDecref check in refprune Apr 29, 2024
@dlee992 dlee992 changed the title move isRaising check ahead before hasDecref check in refprune remove all refops if a basic block is a raising block Apr 30, 2024
@dlee992
Copy link
Contributor Author

dlee992 commented May 3, 2024

Hi, @sklam. This is another small improvement for ref-pruning. It can enjoy your review! Thanks

@dlee992
Copy link
Contributor Author

dlee992 commented May 28, 2024

Hi, any comment for this PR and the related issue? cc @esc

@esc
Copy link
Member

esc commented May 28, 2024

@dlee992 I suppose this ought to make typed.List faster? If so, do you have any benchmarks to share?

@dlee992
Copy link
Contributor Author

dlee992 commented May 31, 2024

Yeah, I will make up one test case for it ASAP (probably tmr).
In theory, it will definitely help the performance since we prune more atomic refcounts.

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

Successfully merging this pull request may close these issues.

A concrete case for potential ref-pruning chances
2 participants