> Hi all!
> 
> A concern was raised off list that due to the complexity of the way this 
> feature interacts with the engine, it may be best to mark the feature as 
> experimental. This would allow some changes to be made to certain edge-case 
> behaviors and, while I don't think it would be necessary, the public API.
> 
> We (Niklas and I) agree with this and propose that if this feature is 
> accepted, it is marked as experimental through the 8.x release cycle or until 
> we're comfortable removing that label, whichever comes first.
> 
> Experimental in this context would mean fibers would be compiled and 
> available in all releases, but the documentation would denote that behavioral 
> and API changes may be made in future minor releases – use at your own risk.
> 
> As this feature is targeted at library authors and not average PHP users, we 
> believe there would be little effect to the community to take this step.
> 
> Cheers,
> Aaron Piotrowski
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: https://www.php.net/unsub.php
> 

Hi everyone!

I’m concerned my email above may have had the opposite effect from which I had 
hoped.

I think the Fiber implementation is sound and the API, mirroring that of Ruby, 
is proven and unlikely to require change.

There are certain edge case behaviors that I’m concerned may need to changed, 
such as the error reporting level that is active when a fiber is switched. If 
the @ operator is active, should it remain active after a fiber switch? Right 
now, it does not, the @ operator is on a per-fiber basis, restoring error 
reporting when switching fibers. Perhaps though this was the wrong decision. 
What I was hoping to accomplish with marking the feature as experimental was to 
get feedback on such behaviors and make sure we make the right choices.

Recent changes to the JIT also make fibers as an extension incompatible due to 
defining a user opcode handler. This is unfortunate, as cli apps including 
amphp and ReactPHP greatly benefited from the JIT: 
https://www.php.net/releases/8.0/en.php (see Relative JIT contribution to PHP 8 
performance). Integrating fibers in core will allow the opcode handler to be 
predefined.

Hopefully that provides some clarity to our intensions. Cheers!

Aaron Piotrowski

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: https://www.php.net/unsub.php

Reply via email to