Skip to content

GC fiber unfinished executions #9810

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

Merged
merged 1 commit into from
Jan 13, 2023
Merged

GC fiber unfinished executions #9810

merged 1 commit into from
Jan 13, 2023

Conversation

arnaud-lb
Copy link
Member

@arnaud-lb arnaud-lb commented Oct 22, 2022

Fixes #9735

@arnaud-lb arnaud-lb marked this pull request as ready for review November 11, 2022 16:23
@arnaud-lb arnaud-lb requested review from trowski and dstogov November 19, 2022 12:12
Copy link
Member

@dstogov dstogov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't object.

Unfortunately, this GC part becomes too complex and actually makes the idea of backup cycle collection completely inefficient. Classic mark-and-sweep GC might win now.

Copy link
Member

@trowski trowski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Based on my limited knowledge of the GC this looks good. Thanks for tackling this issue!

@arnaud-lb
Copy link
Member Author

Unfortunately, this GC part becomes too complex and actually makes the idea of backup cycle collection completely inefficient.

Because it increases the size of the graph, right? or because of the get_gc handler overhead?

Classic mark-and-sweep GC might win now.

Classic mark-and-sweep would make destructor execution non deterministic though

@dstogov
Copy link
Member

dstogov commented Nov 28, 2022

Unfortunately, this GC part becomes too complex and actually makes the idea of backup cycle collection completely inefficient.

Because it increases the size of the graph, right? or because of the get_gc handler overhead?

Because get_gc handler starts to copy stack slots to GC buffer. That is very similar to "mark roots" phase of mark-and-sweep.

Classic mark-and-sweep GC might win now.

Classic mark-and-sweep would make destructor execution non deterministic though

I know. Destructors and GC are conceptually incompatible.

@arnaud-lb arnaud-lb merged commit 4fb1493 into php:PHP-8.1 Jan 13, 2023
arnaud-lb added a commit that referenced this pull request Jan 13, 2023
* PHP-8.1:
  Reduce HT_MAX_SIZE to account for the max load factor of 0.5 (#10242)
  GC fiber unfinished executions (#9810)
arnaud-lb added a commit that referenced this pull request Jan 13, 2023
* PHP-8.2:
  [ci skip] NEWS
  Reduce HT_MAX_SIZE to account for the max load factor of 0.5 (#10242)
  GC fiber unfinished executions (#9810)
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.

3 participants