3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = array( 'DOCUMENT_ROOT' => 'this', 'bob' => 'that' ); echo "Before: $foo[DOCUMENT_ROOT]\n"; define('DOCUMENT_ROOT', 'bob'); echo "After: $foo[DOCUMENT_ROOT]\n"; echo "Expected: ", $foo[DOCUMENT_ROOT];

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.0060.00916.58
8.3.60.0130.00618.56
8.3.50.0120.00421.14
8.3.40.0050.01018.85
8.3.30.0030.01020.38
8.3.20.0040.00420.18
8.3.10.0040.00421.95
8.3.00.0080.00022.58
8.2.180.0070.00725.92
8.2.170.0070.00722.96
8.2.160.0070.00722.09
8.2.150.0060.00325.66
8.2.140.0050.00224.66
8.2.130.0160.00326.16
8.2.120.0000.00720.92
8.2.110.0110.00722.27
8.2.100.0080.00417.84
8.2.90.0030.00619.17
8.2.80.0060.00319.38
8.2.70.0000.00817.61
8.2.60.0050.00318.04
8.2.50.0040.00418.07
8.2.40.0040.00418.15
8.2.30.0030.00518.00
8.2.20.0040.00417.59
8.2.10.0040.00417.74
8.2.00.0080.00317.55
8.1.280.0100.01025.92
8.1.270.0050.00522.03
8.1.260.0050.00326.35
8.1.250.0070.00028.09
8.1.240.0060.00321.95
8.1.230.0080.00319.00
8.1.220.0060.00317.74
8.1.210.0080.00018.77
8.1.200.0060.00317.23
8.1.190.0000.00817.66
8.1.180.0050.00518.10
8.1.170.0070.00018.61
8.1.160.0000.00718.90
8.1.150.0000.00718.63
8.1.140.0040.00417.51
8.1.130.0030.00317.93
8.1.120.0070.00017.38
8.1.110.0000.00717.36
8.1.100.0050.00217.39
8.1.90.0040.00417.45
8.1.80.0070.00017.46
8.1.70.0000.00717.44
8.1.60.0060.00317.48
8.1.50.0000.00717.51
8.1.40.0000.00817.55
8.1.30.0030.00517.62
8.1.20.0040.00417.73
8.1.10.0040.00417.55
8.1.00.0050.00517.43
8.0.300.0040.00418.77
8.0.290.0080.00017.05
8.0.280.0070.00018.44
8.0.270.0000.00716.80
8.0.260.0000.00816.69
8.0.250.0070.00016.92
8.0.240.0040.00416.95
8.0.230.0030.00316.88
8.0.220.0070.00016.87
8.0.210.0030.00316.82
8.0.200.0030.00316.84
8.0.190.0030.00616.94
8.0.180.0000.00716.78
8.0.170.0040.00416.86
8.0.160.0030.00316.90
8.0.150.0070.00016.91
8.0.140.0000.00816.83
8.0.130.0050.00013.39
8.0.120.0040.00416.75
8.0.110.0040.00416.78
8.0.100.0040.00416.75
8.0.90.0040.00416.75
8.0.80.0000.01716.83
8.0.70.0080.00016.86
8.0.60.0050.00216.84
8.0.50.0020.00516.88
8.0.30.0120.00517.03
8.0.20.0090.01117.40
8.0.10.0070.00017.05
8.0.00.0080.01416.72
7.4.330.0070.00015.00
7.4.320.0000.00716.51
7.4.300.0030.00316.51
7.4.290.0040.00416.60
7.4.280.0000.00816.59
7.4.270.0060.00016.61
7.4.260.0000.00713.29
7.4.250.0030.00316.57
7.4.240.0040.00416.56
7.4.230.0000.00816.31
7.4.220.0160.00316.53
7.4.210.0060.01116.54
7.4.200.0030.00316.57
7.4.190.0070.00016.77
7.4.160.0110.00416.57
7.4.150.0110.00817.40
7.4.140.0100.01117.86
7.4.130.0070.01216.48
7.4.120.0100.00816.47
7.4.110.0150.00316.56
7.4.100.0120.01216.34
7.4.90.0140.00716.39
7.4.80.0100.00619.39
7.4.70.0110.00716.45
7.4.60.0050.01116.58
7.4.50.0000.00816.38
7.4.40.0060.01222.77
7.4.30.0030.01316.63
7.4.00.0040.00715.04
7.3.330.0050.00013.20
7.3.320.0000.00613.19
7.3.310.0040.00416.20
7.3.300.0000.00616.28
7.3.290.0030.01016.15
7.3.280.0080.00816.26
7.3.270.0100.00717.40
7.3.260.0130.00616.29
7.3.250.0070.01316.44
7.3.240.0070.01016.25
7.3.230.0130.00716.52
7.3.210.0100.00716.17
7.3.200.0140.00919.39
7.3.190.0110.01116.48
7.3.180.0060.01016.44
7.3.170.0090.00616.31
7.3.160.0130.00316.50
7.3.120.0120.00014.88
7.2.330.0090.00916.84
7.2.320.0150.00916.52
7.2.310.0060.01216.54
7.2.300.0060.01116.56
7.2.290.0120.00416.62
7.2.60.0000.00816.90
7.1.200.0080.00515.85
7.1.70.0030.00616.81
7.1.60.0070.01119.32
7.1.50.0070.00716.86
7.1.00.0070.07322.45
7.0.200.0030.00316.85
7.0.140.0000.07722.00
7.0.60.0100.08020.02
7.0.50.0030.04017.78
7.0.40.0030.08720.04
7.0.30.0170.05020.30
7.0.20.0430.06320.18
7.0.10.0030.07320.20
7.0.00.0030.08720.16
5.6.280.0070.06721.14
5.6.210.0100.07720.53
5.6.200.0030.04318.12
5.6.190.0030.08720.61
5.6.180.0500.07720.43
5.6.170.0300.07320.56
5.6.160.0130.07720.37
5.6.150.0030.04018.11
5.6.140.0030.09018.17
5.6.130.0000.04318.08
5.6.120.0070.08320.98
5.6.110.0130.08321.04
5.6.100.0030.04720.98
5.6.90.0070.08021.06
5.6.80.0100.06320.37
5.5.350.0000.03720.42
5.5.340.0100.07317.92
5.5.330.0070.05020.21
5.5.320.0000.04320.50
5.5.310.0330.07020.30
5.5.300.0100.06317.95
5.5.290.0100.06317.95
5.5.280.0100.05720.77
5.5.270.0070.08020.89
5.5.260.0070.06320.86
5.5.250.0100.08720.46
5.5.240.0200.08020.27
5.4.450.0300.05319.46
5.4.440.0370.04319.41
5.4.430.0330.06319.41
5.4.420.0270.04719.47
5.4.410.0330.07019.28
5.4.400.0430.05718.81
5.4.390.0370.06718.95
5.4.380.0270.04019.09
5.4.370.0270.07319.25
5.4.360.0300.04318.80
5.4.350.0230.03319.07
5.4.340.0300.07319.10
5.4.320.0330.05718.79
5.4.310.0330.04718.79
5.4.300.0270.04319.13
5.4.290.0300.04019.21
5.4.280.0330.03018.91
5.4.270.0200.04319.24
5.4.260.0270.03719.08
5.4.250.0300.07718.91
5.4.240.0400.05719.15
5.4.230.0370.04719.07
5.4.220.0270.04018.78
5.4.210.0470.03719.13
5.4.200.0370.04718.82
5.4.190.0330.04319.12
5.4.180.0370.07018.92
5.4.170.0470.07319.23
5.4.160.0300.03718.77
5.4.150.0370.06719.06
5.4.140.0330.06716.16
5.4.130.0330.06716.34
5.4.120.0500.04316.37
5.4.110.0400.06716.50
5.4.100.0300.04316.19
5.4.90.0370.03016.39
5.4.80.0330.04716.44
5.4.70.0370.06716.46
5.4.60.0300.03316.36
5.4.50.0400.06016.27
5.4.40.0270.03716.18
5.4.30.0300.03316.36
5.4.20.0430.03716.16
5.4.10.0300.04016.41
5.4.00.0270.07315.90
5.3.290.0370.04014.51
5.3.280.0430.03714.68
5.3.270.0370.05314.63
5.3.260.0300.04014.54
5.3.250.0270.03714.53
5.3.240.0370.04014.51
5.3.230.0270.04714.54
5.3.220.0330.06014.51
5.3.210.0270.04714.67
5.3.200.0270.05314.52
5.3.190.0300.06314.65
5.3.180.0400.06314.41
5.3.170.0330.05314.39
5.3.160.0430.06014.43
5.3.150.0400.06314.50
5.3.140.0270.05014.60
5.3.130.0300.04314.63
5.3.120.0500.05314.55
5.3.110.0230.07714.38
5.3.100.0400.06013.98
5.3.90.0200.07313.86
5.3.80.0370.07013.85
5.3.70.0230.04713.96
5.3.60.0370.04713.95
5.3.50.0270.03713.77
5.3.40.0230.03713.90
5.3.30.0400.03313.84
5.3.20.0330.06013.53
5.3.10.0300.07013.51
5.3.00.0300.04313.66
5.2.170.0170.03311.15
5.2.160.0200.03011.23
5.2.150.0200.03010.99
5.2.140.0230.03011.08
5.2.130.0300.05311.20
5.2.120.0300.04711.15
5.2.110.0170.03311.12
5.2.100.0170.03310.96
5.2.90.0300.03711.15
5.2.80.0230.03011.14
5.2.70.0330.05011.19
5.2.60.0230.03710.96
5.2.50.0230.02711.18
5.2.40.0170.02710.82
5.2.30.0200.03010.90
5.2.20.0270.02711.00
5.2.10.0130.03010.78
5.2.00.0200.02710.63
5.1.60.0130.02310.05
5.1.50.0170.0279.89
5.1.40.0230.0239.90
5.1.30.0130.02710.20
5.1.20.0170.02310.39
5.1.10.0170.02710.14
5.1.00.0170.02710.15
5.0.50.0070.0238.63
5.0.40.0070.0208.41
5.0.30.0100.0278.38
5.0.20.0100.0178.18
5.0.10.0070.0208.05
5.0.00.0100.0338.30
4.4.90.0130.0307.84
4.4.80.0100.0137.84
4.4.70.0070.0207.84
4.4.60.0070.0177.84
4.4.50.0100.0137.84
4.4.40.0100.0237.84
4.4.30.0100.0177.84
4.4.20.0130.0137.84
4.4.10.0100.0177.84
4.4.00.0070.0237.84
4.3.110.0030.0277.84
4.3.100.0070.0137.84
4.3.90.0070.0137.84
4.3.80.0070.0237.84
4.3.70.0070.0137.84
4.3.60.0070.0137.84
4.3.50.0030.0177.84
4.3.40.0100.0207.84
4.3.30.0030.0177.84
4.3.20.0030.0177.84
4.3.10.0030.0177.84
4.3.00.0070.0137.84

preferences:
48.92 ms | 401 KiB | 5 Q