I upgraded php from 5.4 (Centos) to 8.1 (Ubuntu22.04) and I noticed a big performance downgrade in php native calls such as php::date, php::sin etc.
for example, php::strtotime that before took 2msec for 260 calls, now takes 35msec.(measured with xdebug profiler)
The problem seems to be related to the web server. For a simple while that repeats strtotime 100000 times, the old server takes 2.7seconds behind apache and via command line, the new server takes 3.5 seconds behind apache but 0.9 seconds via command line,
what can I do to track down the problem?