3v4l.org

run code in 300+ PHP versions simultaneously
<?php gc_enable(); class test { private static $count = 0; public function __construct() { self::$count ++; } } $i = 0; while($i < 500) { $test = new test(); unset($test); gc_collect_cycles(); echo number_format(memory_get_usage()) . " B \n"; $i++; }

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)
7.4.10.0090.00614.85
7.4.00.0030.01714.98
7.3.130.0030.01314.80
7.3.120.0070.01014.90
7.3.110.0140.00714.77
7.3.100.0040.01414.86
7.3.90.0120.00014.69
7.3.80.0100.00715.12
7.3.70.0040.00714.73
7.3.60.0120.00914.40
7.3.50.0030.01014.70
7.3.40.0060.00614.77
7.3.30.0060.01014.82
7.3.20.0110.00416.69
7.3.10.0040.00716.65
7.3.00.0060.00616.34
7.2.260.0100.01015.35
7.2.250.0070.01315.07
7.2.240.0060.00915.21
7.2.230.0030.01615.13
7.2.220.0000.01915.33
7.2.210.0100.00615.17
7.2.200.0080.00815.13
7.2.190.0090.00615.13
7.2.180.0060.00615.29
7.2.170.0100.00614.93
7.2.160.0060.00915.16
7.2.150.0030.01316.98
7.2.140.0080.00816.84
7.2.130.0070.01016.79
7.2.120.0040.00817.09
7.2.110.0110.00916.61
7.2.100.0070.01316.66
7.2.90.0130.01116.60
7.2.80.0110.01116.77
7.2.70.0160.00716.86
7.2.60.0170.00516.87
7.2.50.0150.00916.80
7.2.40.0150.00516.90
7.2.30.0100.01016.69
7.2.20.0070.01316.85
7.2.10.0140.00716.48
7.2.00.0080.00917.63
7.1.330.0120.00315.62
7.1.320.0070.01115.99
7.1.310.0100.00615.66
7.1.300.0070.00615.51
7.1.290.0070.00715.79
7.1.280.0000.01315.60
7.1.270.0070.00315.51
7.1.260.0080.00515.61
7.1.250.0030.01315.83
7.1.240.0090.00515.86
7.1.230.0140.00515.54
7.1.220.0110.00915.55
7.1.210.0140.00615.64
7.1.200.0110.01115.50
7.1.190.0100.00815.71
7.1.180.0130.00815.74
7.1.170.0110.00515.59
7.1.160.0150.00315.63
7.1.150.0120.00915.55
7.1.140.0150.00815.65
7.1.130.0130.00615.49
7.1.120.0130.01315.76
7.1.110.0080.00815.65
7.1.100.0130.00715.57
7.1.90.0140.00815.65
7.1.80.0120.01015.75
7.1.70.0110.00616.26
7.1.60.0110.01316.91
7.1.50.0140.01016.15
7.1.40.0740.00815.57
7.1.30.0100.01015.72
7.1.20.0070.00915.79
7.1.10.0090.00715.83
7.1.00.0050.01717.98
7.0.330.0110.00315.32
7.0.320.0060.00915.21
7.0.310.0100.01015.28
7.0.300.0080.00915.31
7.0.290.0100.00815.23
7.0.280.0130.00415.20
7.0.270.0110.01015.18
7.0.260.0140.00715.40
7.0.250.0070.01115.30
7.0.240.0150.00815.40
7.0.230.0110.01015.37
7.0.220.0130.01015.40
7.0.210.0110.01115.28
7.0.200.0070.01115.82
7.0.190.0160.00415.35
7.0.180.0110.00615.51
7.0.170.0050.01015.56
7.0.160.0100.00715.43
7.0.150.0090.00515.41
7.0.140.0040.03317.63
7.0.130.0070.00815.55
7.0.120.0120.00615.46
7.0.110.0110.00615.36
7.0.100.0060.01315.47
7.0.90.0180.00115.39
7.0.80.0100.00615.40
7.0.70.0130.00615.24
7.0.60.0110.02816.92
7.0.50.0180.02616.18
7.0.40.0090.03215.72
7.0.30.0130.02615.76
7.0.20.0150.03115.60
7.0.10.0090.03215.66
7.0.00.0080.02615.66
5.6.400.0040.01514.66
5.6.390.0060.00914.51
5.6.380.0070.00814.15
5.6.370.0070.00814.13
5.6.360.0090.01014.15
5.6.350.0110.00714.36
5.6.340.0100.01014.44
5.6.330.0130.00814.19
5.6.320.0080.01014.04
5.6.310.0020.01314.06
5.6.300.0090.00714.49
5.6.290.0060.00814.35
5.6.280.0060.03216.52
5.6.270.0120.00314.41
5.6.260.0070.00814.28
5.6.250.0080.00714.21
5.6.240.0060.01114.28
5.6.230.0100.00414.14
5.6.220.0050.01114.15
5.6.210.0050.03716.44
5.6.200.0020.02615.72
5.6.190.0080.03216.43
5.6.180.0170.01916.48
5.6.170.0140.02216.38
5.6.160.0090.03516.19
5.6.150.0030.03415.57
5.6.140.0080.03215.56
5.6.130.0140.02915.58
5.6.120.0090.02816.56
5.6.110.0080.03516.49
5.6.100.0100.03216.46
5.6.90.0080.03416.53
5.6.80.0070.03516.35
5.6.70.0110.00713.97
5.6.60.0120.00614.12
5.6.50.0100.00614.22
5.6.40.0090.00814.14
5.6.30.0060.00814.29
5.6.20.0090.00914.20
5.6.10.0090.00814.41
5.6.00.0050.01314.29
5.5.380.0040.00912.61
5.5.370.0040.01112.39
5.5.360.0080.00512.52
5.5.350.0130.02315.36
5.5.340.0060.01714.44
5.5.330.0050.02015.24
5.5.320.0160.03115.29
5.5.310.0130.03115.21
5.5.300.0060.03214.48
5.5.290.0080.03314.35
5.5.280.0040.02015.38
5.5.270.0070.03615.34
5.5.260.0040.03415.26
5.5.250.0040.03615.42
5.5.240.0080.02715.12
5.5.230.0090.00612.66
5.5.220.0060.00812.76
5.5.210.0040.01112.71
5.5.200.0060.00712.74
5.5.190.0090.00912.70
5.5.180.0050.01012.60
5.5.170.0110.00713.87
5.5.160.0120.00312.72
5.5.150.0060.00712.82
5.5.140.0090.00812.58
5.5.130.0090.00612.82
5.5.120.0110.00712.66
5.5.110.0050.00912.79
5.5.100.0050.01112.81
5.5.90.0090.00512.82
5.5.80.0060.00912.50
5.5.70.0050.00812.68
5.5.60.0090.00812.79
5.5.50.0080.00312.52
5.5.40.0090.00812.78
5.5.30.0040.01112.76
5.5.20.0120.00512.63
5.5.10.0110.00612.67
5.5.00.0060.01112.60
5.4.450.0110.03013.95
5.4.440.0120.02514.07
5.4.430.0120.02614.04
5.4.420.0080.02414.05
5.4.410.0080.01813.92
5.4.400.0140.01513.97
5.4.390.0110.01713.84
5.4.380.0120.02813.77
5.4.370.0120.03013.88
5.4.360.0150.02613.91
5.4.350.0110.03013.96
5.4.340.0100.03113.87
5.4.330.0030.00911.39
5.4.320.0130.03113.95
5.4.310.0110.02014.01
5.4.300.0130.02714.08
5.4.290.0110.03013.81
5.4.280.0140.02713.92
5.4.270.0140.02113.94
5.4.260.0130.01813.87
5.4.250.0160.02513.79
5.4.240.0140.01614.10
5.4.230.0140.03013.91
5.4.220.0160.02813.95
5.4.210.0150.02813.92
5.4.200.0110.02114.04
5.4.190.0140.02813.80
5.4.180.0130.02013.99
5.4.170.0150.02413.95
5.4.160.0080.02213.91
5.4.150.0110.02713.96
5.4.140.0070.02412.93
5.4.130.0110.02713.03
5.4.120.0160.01513.01
5.4.110.0150.02713.17
5.4.100.0170.02413.08
5.4.90.0110.02013.09
5.4.80.0150.01313.09
5.4.70.0100.02213.07
5.4.60.0160.02413.03
5.4.50.0120.03012.98
5.4.40.0130.01613.04
5.4.30.0110.01813.04
5.4.20.0150.02313.07
5.4.10.0110.03313.19
5.4.00.0100.02912.97
5.3.290.0130.02712.31
5.3.280.0100.02012.33
5.3.270.0180.02112.31
5.3.260.0110.03112.36
5.3.250.0100.02212.38
5.3.240.0110.01512.22
5.3.230.0170.01912.35
5.3.220.0100.03112.19
5.3.210.0110.03112.21
5.3.200.0130.02612.29
5.3.190.0140.02612.33
5.3.180.0160.02012.38
5.3.170.0120.01712.35
5.3.160.0100.02912.35
5.3.150.0120.02612.43
5.3.140.0130.02812.36
5.3.130.0110.01812.35
5.3.120.0090.03412.34
5.3.110.0130.02712.38
5.3.100.0150.02312.15
5.3.90.0090.01912.18
5.3.80.0150.02312.11
5.3.70.0140.02811.96
5.3.60.0120.02812.01
5.3.50.0090.02712.10
5.3.40.0110.02412.08
5.3.30.0090.03012.16
5.3.20.0130.03012.00
5.3.10.0130.02611.88
5.3.00.0160.01911.90
5.2.170.0100.02311.31
5.2.160.0120.02411.16
5.2.150.0110.02411.25
5.2.140.0150.03011.32
5.2.130.0150.03211.20
5.2.120.0140.03011.25
5.2.110.0140.03211.32
5.2.100.0090.03311.27
5.2.90.0110.02811.26
5.2.80.0130.02711.18
5.2.70.0190.02611.20
5.2.60.0090.02011.19
5.2.50.0150.02211.26
5.2.40.0140.02011.26
5.2.30.0130.02711.13
5.2.20.0100.02811.18
5.2.10.0070.03311.14
5.2.00.0050.03311.10
5.1.60.0100.02110.97
5.1.50.0140.02510.97
5.1.40.0120.01510.97
5.1.30.0120.02410.97
5.1.20.0120.01510.97
5.1.10.0070.02410.97
5.1.00.0130.02710.97
5.0.50.0050.02510.97
5.0.40.0080.01710.97
5.0.30.0090.02210.97
5.0.20.0070.02310.97
5.0.10.0090.01710.97
5.0.00.0020.03110.97
4.4.90.0070.01010.97
4.4.80.0050.02110.97
4.4.70.0080.01110.97
4.4.60.0100.01510.97
4.4.50.0110.01510.97
4.4.40.0070.02110.97
4.4.30.0050.01210.97
4.4.20.0130.01310.97
4.4.10.0080.01610.97
4.4.00.0050.02510.97
4.3.110.0070.01210.97
4.3.100.0090.00810.97
4.3.90.0050.01510.97
4.3.80.0050.01810.97
4.3.70.0100.01710.97
4.3.60.0050.02010.97
4.3.50.0050.01610.97
4.3.40.0050.02810.97
4.3.30.0030.02310.97
4.3.20.0070.00810.97
4.3.10.0030.01110.97
4.3.00.0020.01410.97

preferences:
36.2 ms | 400 KiB | 5 Q