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

Set SA_ONSTACK in zend_sigaction #9597

Merged
merged 2 commits into from
Sep 26, 2022
Merged

Conversation

dunglas
Copy link
Contributor

@dunglas dunglas commented Sep 22, 2022

I'm currently working on a new SAPI for web servers written in Go.

Many virtual machines, including Go VM, depend on signals using SA_ONSTACK . This flag allows a thread to define a new alternate signal stack. Many argue that SA_ONSTACK should be a default, but it's not the case (yet).

This patch sets the SA_ONSTACK flag when PHP calls sigaction().

Python merged a similar patch (python/cpython#24730) in 2021 (Python 3.10+) for the same reasons, with no issues.

@Girgias
Copy link
Member

Girgias commented Sep 22, 2022

Shouldn't this target 8.2? master is currently 8.3-dev

@dunglas
Copy link
Contributor Author

dunglas commented Sep 22, 2022

@Girgias, @krakjoe said on internals

Master should be targeted, no RFC is required, and the patch looks fine to me.

Your call :)

@devnexen
Copy link
Member

I definitely would like to see it at least for 8.3, @dunglas is doing the right things IMHO nor I have any problem seeing also into the 8.2 branch but should not we ask one of the release managers opinion just to be safe or is it ok ?

Copy link
Member

@iluuu1994 iluuu1994 left a comment

Choose a reason for hiding this comment

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

LGTM. I think master should be fine, unless the RMs think this should target an earlier branch.

@Girgias
Copy link
Member

Girgias commented Sep 26, 2022

@saundefined @adoy opinions about landing this in 8.2 or should this be deferred to 8.3?

@adoy
Copy link
Member

adoy commented Sep 26, 2022

Unless there is a very strong need to have this change in 8.2 I would recommend to target 8.3 since we already are in an RC phase.

@iluuu1994 iluuu1994 merged commit cd572ae into php:master Sep 26, 2022
@dunglas dunglas deleted the feat/SA_ONSTACK branch October 13, 2022 13:57
lstrojny pushed a commit to php-amqp/php-amqp that referenced this pull request Jun 4, 2024
Sets SA_ONSTACK and switches from signal to sigaction (see php/php-src#9597)
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.

5 participants