Stack overflow no location
Open
Nobody has claimed this yet.
Bug
Extension: standard
Status: Verified
- Dominant language
- C
- Stars
- 40.4k
- Forks
- 8.1k
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 96
Description
Description
The following code:
<?php
$a=[]; for($i=0;$i<1000000;$i++){ $a=['k'=>$a]; }
$b=array_merge_recursive($a,$a);
echo "ok\n";
Resulted in this output:
AddressSanitizer:DEADLYSIGNAL
=================================================================
==56==ERROR: AddressSanitizer: stack-overflow on address 0x7ffffca8dff8 (pc 0x7f0bfc038c33 bp 0x7ffffca8e000 sp 0x7ffffca8e000 T0)
<empty stack>
SUMMARY: AddressSanitizer: stack-overflow
==56==ABORTING
USE_ZEND_ALLOC=0 php -d "opcache.enable=1" -d "opcache.enable_cli=1" -d "opcache.jit=tracing" -d "opcache.jit_hot_loop=1" -d "opcache.jit_hot_func=1" poc.php
PHP Version
8.6.0
Operating System
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the provided poc.php reproducer with the listed PHP 8.6.0 and opcache JIT command. Trace the array_merge_recursive stack-overflow path and determine how the missing location should be reported. Done means the failure has a useful location or diagnostic and the reproducer is covered by an appropriate regression test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 45/100