3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types=1); function example($foo) { print trim($foo); } // Fatal error: Uncaught TypeError: trim(): Argument #1 ($string) must be of type string, bool given. example(false);

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.4.120.0110.00823.97
8.4.110.0160.00520.81
8.4.100.0260.00918.51
8.4.90.0260.00919.27
8.4.80.0200.00918.60
8.4.70.0220.00817.76
8.4.60.0310.00918.26
8.4.50.0220.00618.02
8.4.40.0270.00718.10
8.4.30.0280.00720.00
8.4.20.0170.00918.84
8.4.10.0220.00619.71
8.3.250.0040.00419.11
8.3.240.0140.00416.74
8.3.230.0150.00616.45
8.3.220.0170.00517.77
8.3.210.0180.00317.50
8.3.200.0210.00516.69
8.3.190.0230.00416.74
8.3.180.0220.00816.69
8.3.170.0280.00618.59
8.3.160.0260.00716.72
8.3.150.0260.00717.44
8.3.140.0260.00916.68
8.3.130.0180.00417.25
8.3.120.0190.00917.81
8.3.110.0170.00617.29
8.3.100.0290.00816.40
8.3.90.0270.00519.96
8.3.80.0130.00728.07
8.3.70.0250.00816.94
8.3.60.0200.00717.25
8.3.50.0270.00916.73
8.3.40.0330.00618.85
8.3.30.0220.00718.39
8.3.20.0140.00322.11
8.3.10.0160.00719.83
8.3.00.0210.00320.44
8.2.290.0170.00818.62
8.2.280.0170.00517.66
8.2.270.0170.01117.25
8.2.260.0180.00917.85
8.2.250.0250.00517.19
8.2.240.0190.00617.25
8.2.230.0160.00618.46
8.2.220.0150.00619.01
8.2.210.0220.00919.81
8.2.200.0220.00517.01
8.2.190.0200.00816.51
8.2.180.0210.00716.45
8.2.170.0270.00218.02
8.2.160.0200.00919.23
8.2.150.0200.00320.15
8.2.140.0190.00419.70
8.2.130.0180.00520.26
8.2.120.0240.00818.56
8.2.110.0270.00318.44
8.2.100.0250.00818.38
8.2.90.0230.00518.15
8.2.80.0330.01117.22
8.2.70.0360.00917.15
8.2.60.0430.00817.26
8.2.50.0370.01017.25
8.2.40.0330.00817.29
8.2.30.0330.00517.26
8.2.20.0240.00817.50
8.2.10.0180.00817.36
8.2.00.0240.00317.46
8.1.330.0130.00919.05
8.1.320.0130.00616.27
8.1.310.0160.00616.23
8.1.300.0180.00817.31
8.1.290.0160.00820.95
8.1.280.0230.00819.36
8.1.270.0260.00419.67
8.1.260.0220.00820.15
8.1.250.0200.00620.71
8.1.240.0220.00619.40
8.1.230.0230.00418.53
8.1.220.0170.00817.90
8.1.210.0310.00517.13
8.1.200.0270.00917.16
8.1.190.0290.00617.10
8.1.180.0300.00817.27
8.1.170.0250.01017.17
8.1.160.0220.01117.20
8.1.150.0260.00617.08
8.1.140.0210.00817.18
8.1.130.0360.00617.06
8.1.120.0310.00417.09
8.1.110.0290.01017.07
8.1.100.0280.00817.24
8.1.90.0230.00417.04
8.1.80.0240.00517.06
8.1.70.0260.00516.99
8.1.60.0220.00717.16
8.1.50.0220.00517.23
8.1.40.0230.00617.23
8.1.30.0320.00417.47
8.1.20.0300.00617.25
8.1.10.0320.00817.18
8.1.00.0290.00917.11
8.0.300.0250.00916.54
8.0.290.0310.00616.54
8.0.280.0300.00516.51
8.0.270.0300.00616.52
8.0.260.0420.00516.48
8.0.250.0290.00916.55
8.0.240.0280.01116.52
8.0.230.0330.00616.48
8.0.220.0320.00416.56
8.0.210.0300.00816.55
8.0.200.0280.00716.66
8.0.190.0300.00616.66
8.0.180.0290.00516.64
8.0.170.0320.00716.58
8.0.160.0260.01116.64
8.0.150.0280.00916.59
8.0.140.0280.01116.49
8.0.130.0270.01516.36
8.0.120.0300.00616.61
8.0.110.0290.00916.46
8.0.100.0410.00416.33
8.0.90.0280.00416.60
8.0.80.0310.00416.51
8.0.70.0300.00616.42
8.0.60.0300.00516.51
8.0.50.0220.00616.49
8.0.30.0290.00716.61
8.0.20.0210.01116.68
8.0.10.0300.00716.48

preferences:
39.16 ms | 403 KiB | 5 Q