3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Active assert and make it quiet assert_options(ASSERT_ACTIVE, 1); assert_options(ASSERT_WARNING, 0); assert_options(ASSERT_QUIET_EVAL, 1); // Create a handler function function my_assert_handler($file, $line, $code, $desc = null) { echo "Assertion failed at file $file, line $line, code $code"; if ($desc) { echo ": $desc"; } echo "\n"; } // Set up the callback assert_options(ASSERT_CALLBACK, 'my_assert_handler'); // Make an assertion that should fail assert('2 < 1', 'Testing if two is less than one');

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.0110.00716.50
8.3.60.0030.01216.63
8.3.50.0140.00917.33
8.3.40.0190.00618.84
8.3.30.0110.00418.50
8.3.20.0000.00818.76
8.3.10.0040.00418.69
8.3.00.0060.00319.28
8.2.180.0000.01516.63
8.2.170.0070.00722.96
8.2.160.0110.00418.68
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0050.00226.16
8.2.120.0000.00720.78
8.2.110.0060.00320.38
8.2.100.0090.00317.72
8.2.90.0000.00817.63
8.2.80.0000.00818.73
8.2.70.0040.00417.73
8.2.60.0000.00819.65
8.2.50.0050.00318.07
8.2.40.0040.00419.47
8.2.30.0060.00317.72
8.2.20.0060.00617.60
8.2.10.0070.00017.68
8.2.00.0040.00417.73
8.1.280.0070.01025.92
8.1.270.0060.00323.99
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0030.00618.88
8.1.230.0060.00617.72
8.1.220.0000.00817.79
8.1.210.0000.00818.77
8.1.200.0000.00917.35
8.1.190.0040.00417.10
8.1.180.0000.00819.00
8.1.170.0040.00418.86
8.1.160.0070.00018.98
8.1.150.0000.00718.53
8.1.140.0020.00517.34
8.1.130.0000.00717.74
8.1.120.0000.00817.37
8.1.110.0000.00817.29
8.1.100.0050.00217.29
8.1.90.0000.00717.34
8.1.80.0000.00717.30
8.1.70.0000.00817.39
8.1.60.0000.00917.48
8.1.50.0000.00817.39
8.1.40.0040.00417.48
8.1.30.0000.00917.61
8.1.20.0040.00417.62
8.1.10.0000.00717.45
8.1.00.0040.00417.46
8.0.300.0030.00518.77
8.0.290.0080.00016.75
8.0.280.0000.00918.58
8.0.270.0030.00317.25
8.0.260.0070.00016.80
8.0.250.0040.00416.93
8.0.240.0090.00017.01
8.0.230.0030.00317.12
8.0.220.0030.00316.86
8.0.210.0030.00516.97
8.0.200.0040.00416.98
8.0.190.0030.00517.07
8.0.180.0000.00817.00
8.0.170.0060.00316.86
8.0.160.0040.00416.86
8.0.150.0030.00616.86
8.0.140.0000.00816.98
8.0.130.0000.00613.45
8.0.120.0100.00216.97
8.0.110.0000.00816.87
8.0.100.0040.00417.02
8.0.90.0040.00416.75
8.0.80.0120.00317.02
8.0.70.0040.00416.74
8.0.60.0090.00016.95
8.0.50.0000.00716.90
8.0.30.0130.01017.25
8.0.20.0060.01317.11
8.0.10.0000.00716.93
8.0.00.0160.02816.90
7.4.330.0000.00512.87
7.4.320.0030.00316.30
7.4.300.0060.00016.54
7.4.290.0030.00316.40
7.4.280.0050.00316.41
7.4.270.0000.00716.41
7.4.260.0050.00213.11
7.4.250.0000.00816.46
7.4.240.0030.00316.48
7.4.230.0000.00716.38
7.4.220.0100.01116.58
7.4.210.0060.01216.51
7.4.200.0070.00016.30
7.4.190.0000.00716.25
7.4.160.0060.00916.48
7.4.150.0060.01216.26
7.4.140.0070.01116.37
7.4.130.0120.00616.41
7.4.120.0140.00716.38
7.4.110.0160.00616.41
7.4.100.0140.00316.54
7.4.90.0120.00616.35
7.4.80.0030.01319.39
7.4.70.0060.01316.29
7.4.60.0060.00916.45
7.4.50.0120.00016.35
7.4.40.0100.00516.09
7.4.30.0080.01016.37
7.4.00.0050.00914.92
7.3.330.0040.00413.41
7.3.320.0000.00613.41
7.3.310.0030.00316.41
7.3.300.0060.00016.29
7.3.290.0050.01416.36
7.3.280.0140.00716.38
7.3.270.0120.00616.54
7.3.260.0100.01016.42
7.3.250.0110.00616.43
7.3.240.0030.01316.52
7.3.230.0110.01116.41
7.3.210.0160.00016.58
7.3.200.0100.00716.30
7.3.190.0030.01316.49
7.3.180.0030.01716.41
7.3.170.0100.00716.37
7.3.160.0110.00716.60
7.3.120.0050.01014.76
7.3.110.0070.01114.76
7.3.100.0080.00814.95
7.3.90.0030.01014.57
7.3.80.0040.01115.09
7.3.70.0000.01314.65
7.3.60.0040.01114.89
7.3.50.0100.00614.93
7.3.40.0090.00614.70
7.3.30.0090.00014.55
7.3.20.0030.01016.79
7.3.10.0070.00716.74
7.3.00.0040.00416.70
7.2.330.0140.00416.26
7.2.320.0060.00916.50
7.2.310.0090.00916.52
7.2.300.0090.00916.40
7.2.290.0100.01016.47
7.2.250.0030.01314.93
7.2.240.0090.00914.70
7.2.230.0090.00614.91
7.2.220.0060.00614.97
7.2.210.0030.01315.06
7.2.200.0030.01314.84
7.2.190.0000.00915.05
7.2.180.0110.00415.05
7.2.170.0030.01314.88
7.2.80.0070.00316.52
7.2.60.0000.01316.90
7.1.330.0060.00915.82
7.1.320.0080.00815.86
7.1.310.0040.00915.61
7.1.300.0040.01115.83
7.1.290.0060.01015.74
7.1.280.0080.00415.61
7.1.270.0090.00315.69
7.1.260.0060.00815.46
7.1.200.0000.01115.59
7.1.100.0000.01117.98
7.1.70.0040.00717.23
7.1.60.0180.00719.30
7.1.50.0070.00716.68
7.1.00.0070.06322.41
7.0.200.0080.00516.89
7.0.140.0070.07022.00
7.0.120.0100.07022.23
7.0.60.0100.08020.04
7.0.50.0030.05017.89
7.0.40.0100.04020.05
7.0.30.0330.08020.25
7.0.20.0270.07020.26
7.0.10.0170.08720.06
7.0.00.0100.05720.23
5.6.280.0030.07320.82
5.6.210.0200.06720.54
5.6.200.0130.05718.15
5.6.190.0100.08020.59
5.6.180.0200.06720.44
5.6.170.0370.07720.71
5.6.160.0100.06720.48
5.6.150.0070.06318.16
5.6.140.0030.08318.15
5.6.130.0030.07718.15
5.6.120.0030.04321.09
5.6.110.0030.04720.96
5.6.100.0030.06020.98
5.6.90.0070.06720.97
5.6.80.0100.07320.50
5.6.70.0270.07020.51
5.5.350.0200.05320.35
5.5.340.0030.07717.98
5.5.330.0070.09320.29
5.5.320.0070.08320.38
5.5.310.0370.06020.36
5.5.300.0100.08017.95
5.5.290.0130.04717.94
5.5.280.0030.04020.74
5.5.270.0170.06020.97
5.5.260.0030.04020.96
5.5.250.0070.03720.46
5.5.240.0070.07020.23
5.4.450.0100.04719.41
5.4.440.0100.07719.33
5.4.430.0030.06719.48
5.4.420.0000.08319.40
5.4.410.0030.04019.43
5.4.400.0170.06718.89
5.4.390.0070.04718.85
5.4.380.0030.05019.24
5.4.370.0100.05318.87
5.4.360.0170.06718.85
5.4.350.0170.04719.24
5.4.340.0030.07718.98
5.4.320.0070.03719.14
5.4.310.0100.05019.17
5.4.300.0170.03719.20
5.4.290.0070.06719.20
5.4.280.0030.06719.14
5.4.270.0070.06318.87
5.4.260.0070.07019.24
5.4.250.0000.07319.14
5.4.240.0100.07319.21
5.4.230.0070.03318.85
5.4.220.0130.07319.14
5.4.210.0070.07019.14
5.4.200.0030.05719.20
5.4.190.0100.06019.14
5.4.180.0030.06719.21
5.4.170.0130.03019.07
5.4.160.0030.05719.24
5.4.150.0070.03719.23
5.4.140.0070.03316.34
5.4.130.0000.05716.32
5.4.120.0030.08016.59
5.4.110.0070.06716.30
5.4.100.0070.04316.43
5.4.90.0070.06316.72
5.4.80.0070.06716.44
5.4.70.0000.04016.41
5.4.60.0030.06716.39
5.4.50.0100.07016.38
5.4.40.0070.06316.40
5.4.30.0070.07316.30
5.4.20.0000.05016.46
5.4.10.0000.05716.38
5.4.00.0070.04015.85
5.3.290.0170.04714.66
5.3.280.0030.04014.62
5.3.270.0070.05014.63
5.3.260.0070.04014.50
5.3.250.0130.06014.61
5.3.240.0130.07314.63
5.3.230.0170.07014.59
5.3.220.0000.08314.45
5.3.210.0070.05014.56
5.3.200.0070.04714.59
5.3.190.0030.05314.57
5.3.180.0070.04314.61
5.3.170.0030.05714.57
5.3.160.0100.03314.55
5.3.150.0130.07014.71
5.3.140.0070.06014.46
5.3.130.0270.03014.52
5.3.120.0000.08314.57
5.3.110.0100.07714.69
5.3.100.0100.07014.07
5.3.90.0070.03714.05
5.3.80.0100.04314.04
5.3.70.0030.05713.97
5.3.60.0030.07713.92
5.3.50.0100.07313.97
5.3.40.0070.06313.96
5.3.30.0100.05713.95
5.3.20.0030.07313.73
5.3.10.0030.07313.71
5.3.00.0100.06713.56
5.2.170.0070.06011.19
5.2.160.0030.04011.30
5.2.150.0100.05711.12
5.2.140.0030.05711.07
5.2.130.0030.04011.27
5.2.120.0070.05711.10
5.2.110.0070.06011.02
5.2.100.0070.03711.18
5.2.90.0070.03311.07
5.2.80.0030.04011.02
5.2.70.0100.05011.16
5.2.60.0100.02311.11
5.2.50.0030.02710.99
5.2.40.0000.03310.94
5.2.30.0070.02310.92
5.2.20.0000.03311.01
5.2.10.0030.03011.04
5.2.00.0070.05710.77
5.1.60.0000.03310.06
5.1.50.0000.03010.14
5.1.40.0030.0279.95
5.1.30.0030.03710.39
5.1.20.0030.02710.43
5.1.10.0070.04310.02
5.1.00.0000.03710.22
5.0.50.0030.0208.59
5.0.40.0030.0408.41
5.0.30.0100.0538.22
5.0.20.0000.0338.22
5.0.10.0070.0208.08
5.0.00.0000.0738.07
4.4.90.0030.0207.91
4.4.80.0000.0177.91
4.4.70.0070.0177.91
4.4.60.0000.0207.91
4.4.50.0030.0277.91
4.4.40.0000.0277.91
4.4.30.0030.0137.91
4.4.20.0000.0177.91
4.4.10.0000.0207.91
4.4.00.0030.0237.91
4.3.110.0030.0207.91
4.3.100.0030.0337.91
4.3.90.0030.0207.91
4.3.80.0030.0537.91
4.3.70.0000.0237.91
4.3.60.0000.0237.91
4.3.50.0000.0207.91
4.3.40.0030.0407.91
4.3.30.0000.0237.91
4.3.20.0000.0377.91
4.3.10.0030.0377.91
4.3.00.0000.0337.91

preferences:
69.46 ms | 401 KiB | 5 Q