3v4l.org

run code in 300+ PHP versions simultaneously
<?php $errored = FALSE; set_error_handler(function ($errno, $errstr) use (&$errored) { $errored = TRUE; return TRUE; }); $excludedClasses = [ // These cause fatal errors on instantiation "Closure", "SQLite3", "Filter", "PDO" ]; var_dump( array_filter( get_declared_classes(), function ($className) use (&$errored, $excludedClasses) { $errored = FALSE; $class = new ReflectionClass($className); if ($class->hasMethod('__construct')) { $constructor = $class->getMethod('__construct'); $constructor->setAccessible(true); } if (!$class->isInstantiable()) { return FALSE; } foreach ($excludedClasses as $bannedClass) { if (substr($className, 0, strlen($bannedClass)) === $bannedClass) { return FALSE; } } if (!(new ReflectionClass($className))->hasMethod('__toString')) { try { $x = new $className; $x = (string)$x; return !$errored; } catch (Exception $e) { return FALSE; } } return 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.3.60.0100.00318.56
8.3.50.0140.00521.15
8.3.40.0070.00718.64
8.3.30.0090.00619.05
8.3.20.0000.00820.31
8.3.10.0060.00320.59
8.3.00.0050.00519.28
8.2.180.0080.00818.29
8.2.170.0040.01122.96
8.2.160.0030.01320.46
8.2.150.0050.00324.18
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0000.00722.06
8.2.110.0000.00920.53
8.2.100.0040.00817.91
8.2.90.0050.00319.28
8.2.80.0000.00817.97
8.2.70.0080.00017.75
8.2.60.0070.00318.05
8.2.50.0060.00318.07
8.2.40.0000.00818.21
8.2.30.0060.00319.21
8.2.20.0000.00817.84
8.2.10.0000.00818.19
8.2.00.0040.00417.82
8.1.280.0060.00925.92
8.1.270.0080.00023.92
8.1.260.0040.00426.35
8.1.250.0050.00228.09
8.1.240.0060.00323.96
8.1.230.0040.00818.97
8.1.220.0040.00417.75
8.1.210.0030.00518.77
8.1.200.0070.00317.35
8.1.190.0000.00817.35
8.1.180.0000.00818.10
8.1.170.0000.00918.60
8.1.160.0040.00422.10
8.1.150.0000.00718.92
8.1.140.0040.00417.49
8.1.130.0000.00717.86
8.1.120.0070.00017.51
8.1.110.0000.00717.39
8.1.100.0050.00317.49
8.1.90.0000.00717.57
8.1.80.0020.00517.46
8.1.70.0070.00017.39
8.1.60.0040.00717.59
8.1.50.0060.00317.63
8.1.40.0040.00417.55
8.1.30.0030.00517.55
8.1.20.0000.00717.69
8.1.10.0000.00717.67
8.1.00.0030.00617.55
8.0.300.0000.00818.77
8.0.290.0060.00316.88
8.0.280.0070.00018.52
8.0.270.0040.00417.27
8.0.260.0000.00617.15
8.0.250.0030.00316.94
8.0.240.0000.00716.94
8.0.230.0000.00717.03
8.0.220.0000.00716.97
8.0.210.0000.00717.02
8.0.200.0000.00716.91
8.0.190.0040.00417.06
8.0.180.0000.00717.04
8.0.170.0050.00316.89
8.0.160.0030.00317.01
8.0.150.0040.00416.96
8.0.140.0040.00416.92
8.0.130.0030.00313.47
8.0.120.0050.00316.93
8.0.110.0000.00717.03
8.0.100.0040.00416.96
8.0.90.0040.00416.88
8.0.80.0070.00717.02
8.0.70.0070.00016.97
8.0.60.0040.00416.90
8.0.50.0000.00716.84
8.0.30.0090.01017.06
8.0.20.0140.00917.40
8.0.10.0000.00717.07
8.0.00.0190.01517.04
7.4.330.0050.00015.09
7.4.320.0040.00416.68
7.4.300.0060.00016.53
7.4.290.0000.00716.54
7.4.280.0080.00016.61
7.4.270.0000.00716.67
7.4.260.0030.00316.44
7.4.250.0040.00416.49
7.4.240.0010.00616.62
7.4.230.0000.00716.52
7.4.220.0100.00716.48
7.4.210.0070.00716.47
7.4.200.0060.00316.71
7.4.160.0090.00616.53
7.4.150.0120.00617.40
7.4.140.0150.00217.86
7.4.130.0110.00616.51
7.4.120.0090.00916.54
7.4.110.0100.01316.59
7.4.100.0090.01016.54
7.4.90.0080.01116.57
7.4.80.0060.00919.03
7.4.70.0080.00916.43
7.4.60.0060.01616.45
7.4.50.0050.00216.52
7.4.40.0060.01316.64
7.4.30.0070.01016.66
7.4.10.0130.00314.95
7.4.00.0080.00815.01
7.3.330.0060.00013.30
7.3.320.0000.00613.27
7.3.310.0050.00216.50
7.3.300.0030.00316.45
7.3.290.0150.00016.44
7.3.280.0080.00816.45
7.3.270.0100.00717.40
7.3.260.0060.01216.57
7.3.250.0120.00516.49
7.3.240.0060.01216.32
7.3.230.0110.00616.64
7.3.210.0100.00716.57
7.3.200.0100.01319.39
7.3.190.0160.00316.48
7.3.180.0130.00916.44
7.3.170.0090.00916.61
7.3.160.0100.00716.59
7.3.130.0060.01114.94
7.3.120.0100.00514.85
7.3.110.0130.00514.87
7.3.100.0150.00114.74
7.3.90.0050.00914.92
7.3.80.0050.00514.91
7.3.70.0020.00814.77
7.3.60.0050.00614.97
7.3.50.0090.00514.82
7.3.40.0030.01014.56
7.3.30.0030.00914.71
7.3.20.0080.00316.68
7.3.10.0110.00416.73
7.3.00.0140.00916.54
7.2.330.0030.01316.53
7.2.320.0120.00616.79
7.2.310.0070.01016.82
7.2.300.0060.01116.73
7.2.290.0090.01216.77
7.2.260.0060.01314.97
7.2.250.0050.01015.12
7.2.240.0040.01415.00
7.2.230.0020.01214.90
7.2.220.0110.00515.15
7.2.210.0100.00514.90
7.2.200.0070.00515.02
7.2.190.0040.00915.15
7.2.180.0080.00815.00
7.2.170.0050.00914.96
7.2.160.0050.01014.91
7.2.150.0050.00916.99
7.2.140.0060.00816.84
7.2.130.0110.00616.86
7.2.120.0130.00516.77
7.2.110.0100.00816.83
7.2.100.0100.00816.93
7.2.90.0230.00717.02
7.2.80.0120.00716.74
7.2.70.0080.00716.79
7.2.60.0160.00716.84
7.2.50.0280.00616.89
7.2.40.0130.00916.88
7.2.30.0230.00716.90
7.2.20.0200.00816.87
7.2.10.0130.00616.88
7.2.00.0520.01116.95
7.1.330.0130.00315.77
7.1.320.0020.00815.64
7.1.310.0080.00515.73
7.1.300.0040.00615.99
7.1.290.0100.00615.76
7.1.280.0060.00315.86
7.1.270.0100.00515.78
7.1.260.0100.00815.72
7.1.250.0140.00815.86
7.1.240.0030.01015.82
7.1.230.0050.00815.73
7.1.220.0030.01015.72
7.1.210.0030.00915.79
7.1.200.0050.00915.81
7.1.190.0080.00515.86
7.1.180.0040.00615.82
7.1.170.0030.01015.71
7.1.160.0070.00615.77
7.1.150.0040.01115.69
7.1.140.0080.00715.61
7.1.130.0090.00515.81
7.1.120.0030.01415.93
7.1.110.0050.00515.84
7.1.100.0040.00916.57
7.1.90.0050.00715.89
7.1.80.0020.01315.89
7.1.70.0030.00916.21
7.1.60.0070.00917.09
7.1.50.0050.00716.20
7.1.40.0030.01115.80
7.1.30.0060.01015.76
7.1.20.0050.00715.67
7.1.10.0050.00715.93
7.1.00.0030.03117.89
7.0.330.0060.00515.37
7.0.320.0050.01015.23
7.0.310.0050.00815.50
7.0.300.0030.00915.28
7.0.290.0070.00815.38
7.0.280.0050.00715.38
7.0.270.0060.00815.46
7.0.260.0050.01015.35
7.0.250.0010.01215.46
7.0.240.0100.00415.39
7.0.230.0050.00815.30
7.0.220.0060.00815.41
7.0.210.0080.00515.60
7.0.200.0020.00815.78
7.0.190.0090.00415.38
7.0.180.0100.00515.42
7.0.170.0070.00615.39
7.0.160.0010.00915.51
7.0.150.0030.01015.42
7.0.140.0040.02817.59
7.0.130.0040.00715.36
7.0.120.0060.00415.46
7.0.110.0050.00615.46
7.0.100.0070.01015.37
7.0.90.0060.00715.32
7.0.80.0040.00815.28
7.0.70.0040.00815.21
7.0.60.0040.03716.98
7.0.50.0060.02816.30
7.0.40.0060.02915.72
7.0.30.0160.02715.82
7.0.20.0090.02915.65
7.0.10.0080.02815.64
7.0.00.0060.03315.67
5.6.400.0120.01016.99
5.6.390.0050.01017.04
5.6.380.0030.01016.96
5.6.370.0030.00816.72
5.6.360.0030.00816.96
5.6.350.0050.01117.00
5.6.340.0030.01017.03
5.6.330.0090.00917.05
5.6.320.0030.01116.92
5.6.310.0060.01316.82
5.6.300.0030.01016.99
5.6.290.0030.01016.91
5.6.280.0050.03119.02
5.6.270.0080.01016.88
5.6.260.0050.00716.91
5.6.250.0070.00916.86
5.6.240.0040.01516.98
5.6.230.0020.01216.94
5.6.220.0090.00816.95
5.6.210.0070.03118.83
5.6.200.0110.03117.39
5.6.190.0050.02018.86
5.6.180.0060.02718.86
5.6.170.0170.02918.88
5.6.160.0070.03418.80
5.6.150.0010.02217.42
5.6.140.0030.02517.45
5.6.130.0080.03017.43
5.6.120.0070.03619.10
5.6.110.0070.01719.17
5.6.100.0050.02219.03
5.6.90.0030.03119.07
5.6.80.0100.02718.85
5.6.70.0040.00816.92
5.6.60.0030.01516.73
5.6.50.0080.00816.86
5.6.40.0110.00516.87
5.6.30.0070.00716.81
5.6.20.0070.00816.67
5.6.10.0080.00816.97
5.6.00.0050.00917.01
5.5.380.0070.00916.84
5.5.370.0070.00716.70
5.5.360.0040.01316.82
5.5.350.0130.02818.70
5.5.340.0100.02416.97
5.5.330.0090.03118.43
5.5.320.0080.02218.52
5.5.310.0070.01918.39
5.5.300.0070.03117.18
5.5.290.0080.03317.16
5.5.280.0160.01418.82
5.5.270.0020.03318.63
5.5.260.0090.03418.81
5.5.250.0080.03018.55
5.5.240.0160.03018.60
5.5.230.0050.00916.71
5.5.220.0060.00816.76
5.5.210.0030.01116.69
5.5.200.0080.00816.71
5.5.190.0070.00716.60
5.5.180.0050.01016.71
5.5.170.0050.01516.57
5.5.160.0010.01116.65
5.5.150.0050.00916.74
5.5.140.0030.01316.54
5.5.130.0080.00716.72
5.5.120.0050.00816.51
5.5.110.0050.01116.79
5.5.100.0080.00916.63
5.5.90.0030.01216.44
5.5.80.0040.01016.72
5.5.70.0030.01116.63
5.5.60.0060.01016.35
5.5.50.0020.01116.45
5.5.40.0030.01316.67
5.5.30.0050.00916.33
5.5.20.0080.01116.21
5.5.10.0050.01116.64
5.5.00.0050.00816.78
5.4.450.0070.02015.23
5.4.440.0310.02315.13
5.4.430.0300.02715.23
5.4.420.0290.00815.16
5.4.410.0250.00415.12
5.4.400.0260.00415.08
5.4.390.0340.00315.04
5.4.380.0170.02914.93
5.4.370.0150.02414.95
5.4.360.0120.03014.89
5.4.350.0190.02314.94
5.4.340.0210.02214.94
5.4.330.0020.00712.63
5.4.320.0030.01812.63
5.4.310.0050.02012.62
5.4.300.0040.01912.63
5.4.290.0010.02012.62
5.4.280.0080.01712.59
5.4.270.0070.01912.59
5.4.260.0050.01912.59
5.4.250.0050.01512.59
5.4.240.0040.01712.59
5.4.230.0040.01912.59
5.4.220.0020.01912.59
5.4.210.0040.01812.59
5.4.200.0070.01712.59
5.4.190.0070.02012.59
5.4.180.0060.01212.59
5.4.170.0060.01812.59
5.4.160.0040.01712.59
5.4.150.0070.01412.59
5.4.140.0040.01712.48
5.4.130.0030.01812.48
5.4.120.0050.01712.46
5.4.110.0060.01612.46
5.4.100.0030.02012.46
5.4.90.0040.01912.46
5.4.80.0050.01912.46
5.4.70.0020.02112.46
5.4.60.0060.01512.46
5.4.50.0030.02012.46
5.4.40.0030.02112.46
5.4.30.0010.01912.46
5.4.20.0050.01912.46
5.4.10.0040.01912.46
5.4.00.0070.01412.29
5.3.290.0080.03812.80
5.3.280.0030.04012.71
5.3.270.0100.03512.72
5.3.260.0060.03912.72
5.3.250.0050.04212.72
5.3.240.0080.03412.72
5.3.230.0080.03912.71
5.3.220.0040.03812.68
5.3.210.0060.03612.68
5.3.200.0080.03912.68
5.3.190.0070.04212.67
5.3.180.0060.03512.67
5.3.170.0070.04312.67
5.3.160.0040.03712.68
5.3.150.0070.04112.67
5.3.140.0070.03812.66
5.3.130.0040.04012.65
5.3.120.0090.04012.65
5.3.110.0090.03712.66
5.3.100.0060.03912.13
5.3.90.0060.03612.11
5.3.80.0030.03912.10
5.3.70.0040.03812.09
5.3.60.0060.03612.08
5.3.50.0090.03312.02
5.3.40.0040.03912.04
5.3.30.0050.03611.98
5.3.20.0040.03611.76
5.3.10.0090.03211.73
5.3.00.0060.03711.72
5.2.170.0070.0369.18
5.2.160.0050.0299.18
5.2.150.0050.0299.18
5.2.140.0040.0339.18
5.2.130.0040.0389.14
5.2.120.0030.0309.14
5.2.110.0080.0259.14
5.2.100.0060.0279.14
5.2.90.0060.0279.14
5.2.80.0020.0339.14
5.2.70.0020.0339.14
5.2.60.0050.0309.09
5.2.50.0080.0279.07
5.2.40.0050.0289.04
5.2.30.0050.0289.01
5.2.20.0070.0329.01
5.2.10.0060.0268.93
5.2.00.0060.0288.78
5.1.60.0060.0238.07
5.1.50.0060.0238.07
5.1.40.0050.0268.05
5.1.30.0060.0248.39
5.1.20.0030.0278.42
5.1.10.0050.0248.14
5.1.00.0040.0258.14
5.0.50.0020.0226.63
5.0.40.0060.0176.48
5.0.30.0050.0366.29
5.0.20.0030.0256.27
5.0.10.0020.0246.25
5.0.00.0020.0326.24
4.4.90.0020.0164.78
4.4.80.0030.0154.75
4.4.70.0030.0154.75
4.4.60.0020.0164.75
4.4.50.0020.0174.77
4.4.40.0040.0234.71
4.4.30.0040.0134.76
4.4.20.0030.0154.84
4.4.10.0020.0164.84
4.4.00.0050.0224.76
4.3.110.0040.0144.67
4.3.100.0030.0144.66
4.3.90.0020.0144.64
4.3.80.0040.0224.59
4.3.70.0020.0154.63
4.3.60.0020.0154.63
4.3.50.0030.0154.63
4.3.40.0020.0244.54
4.3.30.0020.0153.29
4.3.20.0030.0153.27
4.3.10.0000.0173.22
4.3.00.0030.01715.60

preferences:
42.39 ms | 401 KiB | 5 Q