3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class TestClass { public static $currentValue; public static function toValue($value) { self::$currentValue = $value; return __CLASS__; } public static function add($value) { self::$currentValue = self::$currentValue + $value; return __CLASS__; } public static function subtract($value) { self::$currentValue = self::$currentValue - $value; return __CLASS__; } public static function result() { return self::$currentValue; } } $value = TestClass::toValue(5)::add(3)::subtract(2)::add(8)::result(); echo $value;

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.140.0000.01419.07
8.3.130.0060.00318.43
8.3.120.0100.01020.73
8.3.110.0080.00020.94
8.3.100.0080.00024.06
8.3.90.0090.00626.77
8.3.80.0090.00016.50
8.3.70.0000.01416.63
8.3.60.0100.00716.50
8.3.50.0110.01022.11
8.3.40.0070.00718.67
8.3.30.0030.01118.71
8.3.20.0070.00021.90
8.3.10.0050.00323.64
8.3.00.0050.00319.38
8.2.250.0040.00416.70
8.2.240.0040.00417.27
8.2.230.0060.00322.58
8.2.220.0040.00437.54
8.2.210.0050.00326.77
8.2.200.0070.00316.50
8.2.190.0090.00918.16
8.2.180.0080.01125.92
8.2.170.0120.00318.71
8.2.160.0160.00022.96
8.2.150.0020.00525.66
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0070.00321.13
8.2.110.0060.00320.97
8.2.100.0060.00617.84
8.2.90.0000.00917.97
8.2.80.0080.00018.09
8.2.70.0040.00417.50
8.2.60.0050.00317.50
8.2.50.0050.00317.63
8.2.40.0040.00418.22
8.2.30.0040.00419.70
8.2.20.0000.00718.07
8.2.10.0070.00018.12
8.2.00.0040.00417.62
8.1.300.0000.00818.03
8.1.290.0040.00418.88
8.1.280.0070.00725.92
8.1.270.0040.00424.66
8.1.260.0070.00026.35
8.1.250.0040.00428.09
8.1.240.0090.00023.97
8.1.230.0080.00422.83
8.1.220.0050.00317.74
8.1.210.0000.00918.77
8.1.200.0000.00817.23
8.1.190.0040.00417.23
8.1.180.0030.00618.10
8.1.170.0000.00818.54
8.1.160.0000.00718.71
8.1.150.0030.00320.19
8.1.140.0000.00719.53
8.1.130.0040.00417.27
8.1.120.0040.00417.43
8.1.110.0040.00417.37
8.1.100.0000.00717.29
8.1.90.0070.00017.43
8.1.80.0000.00717.30
8.1.70.0030.00317.44
8.1.60.0030.00517.63
8.1.50.0040.00417.58
8.1.40.0040.00417.42
8.1.30.0040.00417.68
8.1.20.0040.00417.56
8.1.10.0000.00717.61
8.1.00.0080.00017.49
8.0.300.0040.00420.04
8.0.290.0040.00416.75
8.0.280.0070.00018.45
8.0.270.0050.00516.71
8.0.260.0070.00016.75
8.0.250.0040.00416.91
8.0.240.0050.00317.03
8.0.230.0040.00416.77
8.0.220.0000.00816.73
8.0.210.0030.00316.86
8.0.200.0000.00616.81
8.0.190.0000.00716.87
8.0.180.0000.00716.73
8.0.170.0000.00716.75
8.0.160.0000.00716.73
8.0.150.0000.00716.79
8.0.140.0070.00016.75
8.0.130.0030.00313.27
8.0.120.0040.00416.76
8.0.110.0040.00416.83
8.0.100.0000.00716.84
8.0.90.0030.00516.84
8.0.80.0030.01216.73
8.0.70.0000.00716.70
8.0.60.0000.00716.71
8.0.50.0080.00016.82
8.0.30.0060.01316.83
8.0.20.0100.00917.41
8.0.10.0040.00417.02
8.0.00.0100.00916.68
7.4.330.0040.00015.55
7.4.320.0060.00016.47
7.4.300.0040.00416.65
7.4.290.0000.00716.65
7.4.280.0000.00816.58
7.4.270.0040.00416.59
7.4.260.0050.00216.55
7.4.250.0030.00516.45
7.4.240.0000.00716.59
7.4.230.0070.00016.54
7.4.220.0000.01816.49
7.4.210.0040.01116.55
7.4.200.0030.00316.26
7.4.150.0160.00917.40
7.4.140.0080.00917.86
7.4.130.0100.00816.42
7.4.120.0080.01116.36
7.4.110.0070.01416.40
7.4.100.0100.00716.43
7.4.90.0060.01416.34
7.4.80.0040.01519.39
7.4.70.0100.00716.43
7.4.60.0030.01516.51
7.4.50.0000.01016.51
7.4.40.0080.00816.43
7.4.30.0100.01016.55
7.4.10.0030.01415.65
7.4.00.0110.00615.39
7.3.330.0030.00313.36
7.3.320.0060.00013.25
7.3.310.0030.00316.32
7.3.300.0000.00716.41
7.3.290.0090.00616.31
7.3.280.0060.00916.33
7.3.270.0140.00417.40
7.3.260.0080.01416.49
7.3.250.0100.00716.42
7.3.240.0060.01116.53
7.3.230.0130.00316.46
7.3.210.0060.01016.57
7.3.200.0070.01016.59
7.3.190.0140.00716.44
7.3.180.0060.00916.61
7.3.170.0040.01316.58
7.3.160.0100.00916.33
7.3.130.0090.00715.64
7.3.120.0090.00915.39
7.3.110.0080.00515.47
7.3.100.0090.00515.25
7.3.90.0070.00715.30
7.3.80.0060.00815.44
7.3.70.0060.00815.21
7.3.60.0060.00715.38
7.3.50.0030.00815.36
7.3.40.0080.00515.26
7.3.30.0100.00615.30
7.3.20.0090.00417.16
7.3.10.0070.00817.03
7.3.00.0070.01117.02
7.2.330.0110.00816.76
7.2.320.0120.00616.75
7.2.310.0030.01316.81
7.2.300.0080.01316.69
7.2.290.0060.01016.71
7.2.260.0090.01016.05
7.2.250.0110.00815.71
7.2.240.0060.01015.72
7.2.230.0080.00915.66
7.2.220.0060.00915.44
7.2.210.0030.00915.66
7.2.200.0060.00615.52
7.2.190.0030.01215.63
7.2.180.0050.00615.52
7.2.170.0020.01115.52
7.2.160.0100.00315.52
7.2.150.0070.00617.38
7.2.140.0050.00817.46
7.2.130.0060.00917.27
7.2.120.0080.00717.22
7.2.110.0050.00917.22
7.2.100.0080.00517.29
7.2.90.0070.00717.30
7.2.80.0050.00917.28
7.2.70.0080.00817.28
7.2.60.0040.01017.10
7.2.50.0040.00917.17
7.2.40.0060.01117.28
7.2.30.0040.01017.37
7.2.20.0080.00817.35
7.2.10.0060.01017.22
7.2.00.0110.00817.17
7.1.330.0060.00916.19
7.1.320.0070.00616.26
7.1.310.0040.01016.39
7.1.300.0080.00716.19
7.1.290.0060.00616.30
7.1.280.0060.00716.34
7.1.270.0070.00416.28
7.1.260.0080.00616.19
7.1.250.0060.00716.04
7.1.240.0090.00216.52
7.1.230.0050.00916.37
7.1.220.0030.00716.48
7.1.210.0030.00816.52
7.1.200.0130.00416.27
7.1.190.0050.00916.51
7.1.180.0070.00616.54
7.1.170.0050.01016.56
7.1.160.0100.00316.52
7.1.150.0110.00516.54
7.1.140.0060.00616.53
7.1.130.0050.01016.41
7.1.120.0040.01116.39
7.1.110.0050.00716.47
7.1.100.0070.00716.56
7.1.90.0080.00516.51
7.1.80.0050.01016.51
7.1.70.0040.00916.73
7.1.60.0030.01016.60
7.1.50.0060.00416.73
7.1.40.0080.00516.51
7.1.30.0050.00716.47
7.1.20.0070.00716.58
7.1.10.0030.00916.48
7.1.00.0060.00816.60
7.0.330.0050.00616.20
7.0.320.0120.00316.30
7.0.310.0070.00416.14
7.0.300.0090.00716.16
7.0.290.0060.00916.23
7.0.280.0020.01016.35
7.0.270.0040.00916.14
7.0.260.0110.00516.02
7.0.250.0110.00216.00
7.0.240.0080.00416.37
7.0.230.0090.00316.20
7.0.220.0050.01016.21
7.0.210.0070.00716.27
7.0.200.0040.00716.38
7.0.190.0060.00616.31
7.0.180.0060.00516.25
7.0.170.0020.00916.16
7.0.160.0070.00816.24
7.0.150.0030.00716.17
7.0.140.0050.00616.25
7.0.130.0060.00716.34
7.0.120.0060.00516.25
7.0.110.0030.00816.27
7.0.100.0030.00816.29
7.0.90.0050.00816.29
7.0.80.0040.00516.22
7.0.70.0040.01216.25
7.0.60.0050.00616.08
7.0.50.0030.00916.29
7.0.40.0050.00614.56
7.0.30.0060.00714.54
7.0.20.0060.00614.59
7.0.10.0050.00814.64
7.0.00.0070.00414.54
5.6.400.0030.00814.62
5.6.390.0020.00814.92
5.6.380.0040.00915.16
5.6.370.0040.01215.02
5.6.360.0060.00914.78
5.6.350.0050.00715.01
5.6.340.0090.00314.78
5.6.330.0020.01015.01
5.6.320.0100.00514.88
5.6.310.0080.00814.91
5.6.300.0060.01916.85
5.6.290.0050.02116.88
5.6.280.0080.01916.97
5.6.270.0060.01816.88
5.6.260.0040.01816.88
5.6.250.0050.01817.05
5.6.240.0080.01616.82
5.6.230.0020.02416.88
5.6.220.0040.02016.87
5.6.210.0060.02116.95
5.6.200.0030.02216.87
5.6.190.0070.01716.94
5.6.180.0060.02016.73
5.6.170.0050.02016.83
5.6.160.0060.01916.87
5.6.150.0070.01716.92
5.6.140.0040.02416.93
5.6.130.0100.02816.82
5.6.120.0040.02816.89
5.6.110.0070.01816.74
5.6.100.0030.02216.84
5.6.90.0030.03216.87
5.6.80.0030.02116.66
5.6.70.0030.02016.64
5.6.60.0080.01416.68
5.6.50.0040.01816.42
5.6.40.0070.02016.59
5.6.30.0070.01516.55
5.6.20.0050.01816.64
5.6.10.0020.01816.64
5.6.00.0040.01816.59
5.5.380.0030.03817.50
5.5.370.0030.04317.68
5.5.360.0030.04417.62
5.5.350.0030.04417.66
5.5.340.0000.04718.04
5.5.330.0030.03918.05
5.5.320.0030.04017.84
5.5.310.0030.04418.09
5.5.300.0030.04518.09
5.5.290.0060.04818.05
5.5.280.0100.08918.10
5.5.270.0070.03817.83
5.5.260.0030.03917.73
5.5.250.0030.04317.84
5.5.240.0040.03917.52
5.5.230.0030.04117.47
5.5.220.0130.03517.39
5.5.210.0000.04617.51
5.5.200.0030.03717.36
5.5.190.0030.03817.41
5.5.180.0100.03617.41
5.5.160.0030.04117.38
5.5.150.0030.03617.44
5.5.140.0040.03917.52
5.5.130.0300.03317.44
5.5.120.0060.04817.35
5.5.110.0000.04217.35
5.5.100.0030.03617.26
5.5.90.0030.03717.29
5.5.80.0030.03717.34
5.5.70.0030.03717.25
5.5.60.0130.06217.08
5.5.50.0060.04216.99
5.5.40.0030.04217.34
5.5.30.0070.05317.41
5.5.20.0030.04117.38
5.5.10.0030.04417.36
5.5.00.0030.04117.24
5.4.450.0000.04819.25
5.4.440.0000.06019.39
5.4.430.0030.04119.38
5.4.420.0100.07819.49
5.4.410.0000.04819.40
5.4.400.0030.04219.17
5.4.390.0060.03919.07
5.4.380.0270.03419.04
5.4.370.0000.04219.23
5.4.360.0230.03619.23
5.4.350.0030.04319.12
5.4.340.0030.03718.90
5.4.320.0000.04418.98
5.4.310.0060.03518.92
5.4.300.0000.05118.89
5.4.290.0060.03418.98
5.4.280.0040.04618.98
5.4.270.0030.03819.07
5.4.260.0000.04118.92
5.4.250.0070.06219.08
5.4.240.0030.03619.08
5.4.230.0000.04119.18
5.4.220.0070.07819.13
5.4.210.0040.03618.97
5.4.200.0070.03619.20
5.4.190.0000.04419.13
5.4.180.0030.04319.15
5.4.170.0060.03519.20
5.4.160.0040.03918.98
5.4.150.0030.04519.21
5.4.140.0030.03416.48
5.4.130.0070.03716.68
5.4.120.0070.04416.49
5.4.110.0130.04316.47
5.4.100.0030.03516.69
5.4.90.0030.05116.54
5.4.80.0030.05916.79
5.4.70.0000.04516.77
5.4.60.0000.03716.57
5.4.50.0000.03916.71
5.4.40.0000.04416.66
5.4.30.0030.03416.60
5.4.20.0070.03016.71
5.4.10.0060.03916.68
5.4.00.0070.03316.14
5.3.290.0030.03615.25
5.3.280.0030.03915.25
5.3.270.0030.04515.25
5.3.260.0000.04115.25
5.3.250.0030.03915.25
5.3.240.0000.04715.25
5.3.230.0030.03915.25
5.3.220.0030.04715.25
5.3.210.0070.04415.25
5.3.200.0100.03215.25
5.3.190.0070.04015.25
5.3.180.0070.03315.25
5.3.170.0000.04015.25
5.3.160.0000.04315.25
5.3.150.0000.04715.25
5.3.140.0030.03915.25
5.3.130.0000.04215.25
5.3.120.0030.05015.25
5.3.110.0030.03515.25
5.3.100.0030.03915.25
5.3.90.0060.03515.25
5.3.80.0070.03315.25
5.3.70.0230.04715.25
5.3.60.0030.03315.25
5.3.50.0000.04915.25
5.3.40.0030.04115.25
5.3.30.0070.04215.25
5.3.20.0030.03315.25
5.3.10.0060.03415.25
5.3.00.0000.03715.25
5.2.170.0000.03015.25
5.2.160.0000.03215.25
5.2.150.0030.02915.25
5.2.140.0030.03215.25
5.2.130.0000.03115.25
5.2.120.0070.02315.25
5.2.110.0070.02315.25
5.2.100.0030.03115.25
5.2.90.0000.03115.25
5.2.80.0060.02515.25
5.2.70.0030.03615.25
5.2.60.0070.02415.25
5.2.50.0000.03615.25
5.2.40.0030.02915.25
5.2.30.0000.03215.25
5.2.20.0000.03815.25
5.2.10.0000.03215.25
5.2.00.0030.02715.25
5.1.60.0030.03115.25
5.1.50.0030.02415.25
5.1.40.0030.02315.25
5.1.30.0000.03115.25
5.1.20.0030.02615.25
5.1.10.0030.03515.25
5.1.00.0030.03915.25
5.0.50.0070.04115.25
5.0.40.0030.02415.25
5.0.30.0000.03515.25
5.0.20.0040.01915.25
5.0.10.0000.02315.25
5.0.00.0040.03215.25
4.4.90.0030.01315.25
4.4.80.0030.01815.25
4.4.70.0000.01715.25
4.4.60.0000.01815.25
4.4.50.0030.01315.25
4.4.40.0000.02515.25
4.4.30.0040.01815.25
4.4.20.0000.01615.25
4.4.10.0000.01815.25
4.4.00.0000.02715.25
4.3.110.0000.01615.25
4.3.100.0000.01615.25
4.3.90.0000.01615.25
4.3.80.0000.02715.25
4.3.70.0000.01915.25
4.3.60.0000.01515.25
4.3.50.0040.01215.25
4.3.40.0030.02215.25
4.3.30.0070.01415.25
4.3.20.0000.02315.25
4.3.10.0060.01615.25
4.3.00.0030.01315.25

preferences:
76.75 ms | 403 KiB | 5 Q