php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #77427 Garbage collector segmentation fault with many circular references
Submitted: 2019-01-08 01:38 UTC Modified: 2019-01-08 10:56 UTC
From: drealecs at gmail dot com Assigned:
Status: Duplicate Package: *General Issues
PHP Version: All versions OS:
Private report: No CVE-ID: None
 [2019-01-08 01:38 UTC] drealecs at gmail dot com
Description:
------------
It seems that when there are many objects in memory with circular references and garbage collector cycle is triggered, it will segfault.

Test script:
---------------
https://3v4l.org/3PniX


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-01-08 09:25 UTC] nikic@php.net
-Status: Open +Status: Duplicate
 [2019-01-08 09:25 UTC] nikic@php.net
Duplicate of bug #77345, GC recursion causes stackoverflow. Only happens since 7.3 as GC can now run on much more objects.
 [2019-01-08 10:56 UTC] drealecs at gmail dot com
-PHP Version: 7.3.0 +PHP Version: All versions
 [2019-01-08 10:56 UTC] drealecs at gmail dot com
I didn't mentioned correctly, the error is present since long time ago if you set the right number of objects:
Doubling it fails for all version: https://3v4l.org/EJCaI

I'm not sure that it is the same problem...
The script I provided fails very fast, even if it is more complex.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Oct 09 06:01:26 2024 UTC