Ticket #3602 (new defect)

Opened 4 months ago

A simple script with more than 29 functions crashes

Reported by: anonymous Assigned to: anonymous
Priority: high Milestone:
Component: Commandline Version: 2.9.6
Severity: crash Keywords:
Cc:

Description

A simple compiled script with more than 29 functions crashes during loading with error message:

Fatal error: vector too large in ft.php on line 0

Tested on Linux 2.6.18 & FreeBSD 6.2-RELEASE with BigLoo? versions 3.0c and 3.1a and with PCC compiler 2.9.6 & 2.9.7.

The script runs normally in interpreted mode (pcc -f ft.php).

Script to reproduce:

<?php

echo "Start\n";

function X1(){}

function X2(){}

function X3(){}

function X4(){}

function X5(){}

function X6(){}

function X7(){}

function X8(){}

function X9(){}

function X10(){}

function X11(){}

function X12(){}

function X13(){}

function X14(){}

function X15(){}

function X16(){}

function X17(){}

function X18(){}

function X19(){}

function X20(){}

function X21(){}

function X22(){}

function X23(){}

function X24(){}

function X25(){}

function X26(){}

function X27(){}

function X28(){}

function X29(){}

function X30(){}

echo "End\n";

?>

Compile command: pcc ft.php

Workaround: move some functions from the main namespace to a class.