3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = 0; if (!$foo) { print 'foo'; } $foo = ''; if (!$foo) { print 'foo'; } $foo = []; if (!$foo) { print 'foo'; } $foo = '0'; if (!$foo) { print 'foo'; }

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.3.70.0170.00716.58
8.3.60.0140.00718.06
8.3.50.0100.01018.19
8.3.40.0110.00718.53
8.3.30.0070.01418.55
8.3.20.0040.00424.18
8.3.10.0070.00024.66
8.3.00.0060.00326.16
8.2.190.0100.01016.58
8.2.180.0120.00625.92
8.2.170.0130.00719.00
8.2.160.0070.00722.96
8.2.150.0030.00525.66
8.2.140.0050.00324.66
8.2.130.0000.00726.16
8.2.120.0070.00417.93
8.2.110.0070.00319.21
8.2.100.0070.00417.91
8.2.90.0050.00317.63
8.2.80.0090.00018.64
8.2.70.0030.00618.04
8.2.60.0050.00318.22
8.2.50.0080.00018.10
8.2.40.0040.00421.06
8.2.30.0000.00719.25
8.2.20.0030.00518.05
8.2.10.0040.00419.29
8.2.00.0040.00419.24
8.1.280.0110.00725.92
8.1.270.0000.00823.99
8.1.260.0030.00626.35
8.1.250.0080.00028.09
8.1.240.0040.00419.19
8.1.230.0070.00317.71
8.1.220.0000.00817.74
8.1.210.0030.00518.77
8.1.200.0060.00317.13
8.1.190.0000.00817.23
8.1.180.0060.00318.10
8.1.170.0000.00918.64
8.1.160.0040.00420.54
8.1.150.0000.00718.96
8.1.140.0000.00720.58
8.1.130.0030.00317.45
8.1.120.0000.00717.42
8.1.110.0050.00217.41
8.1.100.0050.00317.48
8.1.90.0030.00617.46
8.1.80.0080.00017.48
8.1.70.0030.00317.45
8.1.60.0040.00417.52
8.1.50.0040.00417.39
8.1.40.0000.00817.42
8.1.30.0040.00417.66
8.1.20.0080.00017.55
8.1.10.0090.00017.52
8.1.00.0060.00317.33
8.0.300.0030.00618.77
8.0.290.0000.00716.75
8.0.280.0080.00018.33
8.0.270.0000.00716.82
8.0.260.0000.00716.80
8.0.250.0100.00016.95
8.0.240.0060.00016.89
8.0.230.0000.00717.02
8.0.220.0000.00716.92
8.0.210.0040.00416.77
8.0.200.0000.00716.82
8.0.190.0040.00416.88
8.0.180.0070.00016.90
8.0.170.0030.00716.88
8.0.160.0040.00416.95
8.0.150.0040.00416.84
8.0.140.0000.00716.73
8.0.130.0000.00513.36
8.0.120.0000.00816.86
8.0.110.0030.00616.97
8.0.100.0050.00316.73
8.0.90.0000.00716.92
8.0.80.0070.01116.82
8.0.70.0030.00316.69
8.0.60.0000.00716.79
8.0.50.0040.00416.78
8.0.30.0180.01016.78
8.0.20.0240.01316.88
8.0.10.0220.01716.86
8.0.00.0150.01516.86
7.4.330.0000.00515.55
7.4.320.0000.00716.52
7.4.300.0000.00616.57
7.4.290.0000.00716.53
7.4.280.0040.00416.49
7.4.270.0070.00016.50
7.4.260.0000.00713.32
7.4.250.0030.00316.55
7.4.240.0050.00216.56
7.4.230.0000.00816.62
7.4.220.0030.00316.46
7.4.210.0100.00516.60
7.4.200.0000.00716.30
7.4.160.0360.00616.49
7.4.150.0230.00816.38
7.4.140.0210.00616.38
7.4.130.0200.00616.16
7.4.120.0250.00216.31
7.4.110.0250.00516.23
7.4.100.0230.00716.36
7.4.90.0240.00716.34
7.4.80.0220.01016.33
7.4.70.0210.01116.29
7.4.60.0210.00716.36
7.4.50.0250.00316.15
7.4.40.0190.01216.24
7.4.30.0210.00716.23
7.4.20.0270.00816.20
7.4.10.0220.00716.28
7.4.00.0250.00316.31
7.3.330.0000.00716.16
7.3.320.0050.00012.91
7.3.310.0050.00216.14
7.3.300.0000.00716.11
7.3.290.0030.01216.25
7.3.280.0250.00716.08
7.3.270.0210.00516.05
7.3.260.0230.00716.14
7.3.250.0180.00816.07
7.3.240.0220.00516.10
7.3.230.0210.00616.10
7.3.220.0110.01415.99
7.3.210.0190.00816.01
7.3.200.0210.00716.06
7.3.190.0220.00716.05
7.3.180.0150.01416.07
7.3.170.0170.00916.01
7.3.160.0250.00716.04
7.3.150.0290.00816.03
7.3.140.0230.00716.04
7.3.130.0230.00716.09
7.3.120.0200.00716.01
7.3.110.0160.01015.95
7.3.100.0170.01315.91
7.3.90.0210.00916.28
7.3.80.0160.01016.01
7.3.70.0190.00916.20
7.3.60.0240.00816.25
7.3.50.0190.00816.25
7.3.40.0250.00316.28
7.3.30.0200.00816.22
7.3.20.0200.00816.21
7.3.10.0200.00816.16
7.3.00.0240.00716.13

preferences:
22.91 ms | 401 KiB | 5 Q