3v4l.org

run code in 300+ PHP versions simultaneously
<?php $classNames = array("StdClass", "ArrayObject", "SplFileObject"); foreach($classNames as $className) { var_dump(instanitateWithoutConstructorThroughUnserialize($className)); var_dump(instanitateWithoutConstructorThroughReflection($className)); } function instanitateWithoutConstructorThroughUnserialize($className) { return unserialize(sprintf('O:%d:"%s":0:{}', strlen($className), $className)); } function instanitateWithoutConstructorThroughReflection($className) { $ref = new ReflectionClass($className); return $ref->newInstanceWithoutConstructor(); }

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.0080.00818.30
8.3.50.0080.01121.89
8.3.40.0170.00318.76
8.3.30.0120.00619.14
8.3.20.0040.00720.16
8.3.10.0040.00423.52
8.3.00.0110.00719.25
8.2.180.0100.01018.14
8.2.170.0070.00722.96
8.2.160.0110.00420.38
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0000.00926.16
8.2.120.0070.01022.25
8.2.110.0060.00320.47
8.2.100.0080.00417.78
8.2.90.0040.00419.25
8.2.80.0080.00017.97
8.2.70.0080.00017.75
8.2.60.0030.00717.92
8.2.50.0030.00618.07
8.2.40.0050.00319.94
8.2.30.0050.00218.15
8.2.20.0000.00817.70
8.2.10.0030.00518.16
8.2.00.0000.00817.75
8.1.280.0210.00025.92
8.1.270.0040.00423.99
8.1.260.0000.00726.35
8.1.250.0070.00328.09
8.1.240.0060.00323.95
8.1.230.0080.00322.20
8.1.220.0030.00617.74
8.1.210.0050.00318.77
8.1.200.0030.00617.35
8.1.190.0000.01017.23
8.1.180.0040.00418.10
8.1.170.0030.00618.62
8.1.160.0050.00322.05
8.1.150.0070.00018.64
8.1.140.0070.00317.54
8.1.130.0000.00717.85
8.1.120.0050.00217.50
8.1.110.0000.00717.47
8.1.100.0040.00417.48
8.1.90.0040.00417.52
8.1.80.0080.00017.50
8.1.70.0000.00717.36
8.1.60.0030.00617.64
8.1.50.0000.00817.53
8.1.40.0030.00717.56
8.1.30.0080.00017.69
8.1.20.0060.00317.68
8.1.10.0040.00417.50
8.1.00.0040.00417.55
8.0.300.0070.00018.77
8.0.290.0070.00017.05
8.0.280.0000.00718.36
8.0.270.0030.00317.29
8.0.260.0000.00717.25
8.0.250.0040.00416.96
8.0.240.0040.00417.04
8.0.230.0070.00016.93
8.0.220.0030.00517.01
8.0.210.0030.00316.88
8.0.200.0030.00317.00
8.0.190.0040.00417.05
8.0.180.0030.00517.05
8.0.170.0030.00616.86
8.0.160.0000.00717.04
8.0.150.0040.00417.02
8.0.140.0040.00416.84
8.0.130.0030.00313.38
8.0.120.0040.00416.92
8.0.110.0040.00416.90
8.0.100.0030.00316.94
8.0.90.0000.00716.93
8.0.80.0030.01217.04
8.0.70.0000.00816.99
8.0.60.0000.00717.06
8.0.50.0000.00816.99
8.0.30.0130.00917.12
8.0.20.0140.00517.40
8.0.10.0040.00417.08
8.0.00.0090.00916.86
7.4.330.0000.00515.00
7.4.320.0090.00016.49
7.4.300.0030.00316.43
7.4.290.0050.00216.46
7.4.280.0030.00416.55
7.4.270.0070.00016.61
7.4.260.0030.00316.56
7.4.250.0000.00716.57
7.4.240.0000.00716.64
7.4.230.0000.00716.70
7.4.220.0170.00916.66
7.4.210.0120.00716.53
7.4.200.0040.00316.48
7.4.190.0050.00316.64
7.4.160.0110.01116.70
7.4.150.0090.01617.40
7.4.140.0100.00817.86
7.4.130.0110.00616.65
7.4.120.0060.01316.72
7.4.110.0080.00816.56
7.4.100.0110.00716.53
7.4.90.0120.01216.73
7.4.80.0240.00019.39
7.4.70.0110.00716.48
7.4.60.0060.00916.44
7.4.50.0030.00616.66
7.4.40.0090.00916.59
7.4.30.0140.00716.32
7.4.00.0040.01415.09
7.3.330.0000.00513.48
7.3.320.0070.00013.48
7.3.310.0080.00016.58
7.3.300.0000.00716.42
7.3.290.0120.00316.40
7.3.280.0120.00816.45
7.3.270.0140.00617.40
7.3.260.0100.00716.38
7.3.250.0080.00916.59
7.3.240.0030.01516.34
7.3.230.0100.00616.69
7.3.210.0040.01316.38
7.3.200.0060.01219.39
7.3.190.0060.01016.71
7.3.180.0150.00316.36
7.3.170.0110.01116.41
7.3.160.0030.01216.48
7.3.120.0080.00814.76
7.2.330.0110.00616.67
7.2.320.0040.01316.71
7.2.310.0110.00616.81
7.2.300.0030.01316.81
7.2.290.0030.01916.73
7.2.60.0090.00616.97
7.2.00.0040.00819.45
7.1.200.0100.00015.89
7.1.100.0030.00618.25
7.1.70.0000.00817.17
7.1.60.0070.01819.46
7.1.50.0130.00316.63
7.1.00.0000.08022.57
7.0.200.0000.01016.76
7.0.140.0030.07021.98
7.0.110.0070.05020.07
7.0.100.0130.04719.97
7.0.90.0030.05021.79
7.0.80.0000.05021.74
7.0.70.0030.04321.72
7.0.60.0000.04321.84
7.0.50.0070.03722.04
7.0.40.0000.05020.09
7.0.30.0070.04720.26
7.0.20.0000.04020.05
7.0.10.0100.03719.95
7.0.00.0000.04320.18
5.6.280.0100.06721.13
5.6.260.0070.04020.69
5.6.250.0030.04020.76
5.6.240.0000.05020.57
5.6.230.0100.04320.71
5.6.220.0030.04720.60
5.6.210.0100.04020.64
5.6.200.0000.05020.95
5.6.190.0070.04321.09
5.6.180.0030.04021.22
5.6.170.0000.05020.94
5.6.160.0030.04721.06
5.6.150.0130.04720.95
5.6.140.0070.04320.93
5.6.130.0030.05021.18
5.6.120.0000.05020.99
5.6.110.0000.05320.91
5.6.100.0000.04321.23
5.6.90.0030.03321.20
5.6.80.0030.04720.68
5.6.70.0000.04720.53
5.6.60.0100.03720.45
5.6.50.0070.03020.45
5.6.40.0030.04720.58
5.6.30.0070.04020.45
5.6.20.0000.04320.29
5.6.10.0030.04020.30
5.6.00.0100.02720.49
5.5.380.0030.04720.56
5.5.370.0030.04720.56
5.5.360.0030.05020.34
5.5.350.0070.04020.46
5.5.340.0030.04320.98
5.5.330.0030.03720.91
5.5.320.0030.04020.77
5.5.310.0000.05020.99
5.5.300.0030.04720.78
5.5.290.0070.04020.83
5.5.280.0100.03720.88
5.5.270.0070.04720.91
5.5.260.0070.03720.81
5.5.250.0030.03720.63
5.5.240.0000.04720.38
5.5.230.0070.03020.29
5.5.220.0070.03720.35
5.5.210.0070.04720.16
5.5.200.0000.04720.07
5.5.190.0030.04720.14
5.5.180.0030.04720.17
5.5.160.0030.03720.25
5.5.150.0000.04020.17
5.5.140.0070.04020.14
5.5.130.0030.04320.30
5.5.120.0000.04720.24
5.5.110.0000.04320.32
5.5.100.0030.04320.03
5.5.90.0000.04720.16
5.5.80.0030.03720.18
5.5.70.0000.03320.23
5.5.60.0000.03720.02
5.5.50.0000.03320.07
5.5.40.0030.06320.10
5.5.30.0000.04320.07
5.5.20.0000.05719.99
5.5.10.0000.04720.03
5.5.00.0000.05319.91
5.4.450.0000.04019.34
5.4.440.0030.04719.31
5.4.430.0030.03719.46
5.4.420.0070.04019.51
5.4.410.0030.04719.23
5.4.400.0030.04019.02
5.4.390.0070.04018.99
5.4.380.0030.04319.32
5.4.370.0030.03319.00
5.4.360.0030.04319.03
5.4.350.0030.04019.16
5.4.340.0030.04319.18
5.4.320.0030.04019.22
5.4.310.0000.04319.18
5.4.300.0030.03319.30
5.4.290.0070.04019.34
5.4.280.0000.04719.00
5.4.270.0030.03019.18
5.4.260.0000.04019.23
5.4.250.0000.04319.16
5.4.240.0030.03719.18
5.4.230.0030.04319.02
5.4.220.0000.03319.08
5.4.210.0000.07019.01
5.4.200.0000.03719.22
5.4.190.0070.08718.98
5.4.180.0030.05019.00
5.4.170.0070.02718.99
5.4.160.0030.05019.01
5.4.150.0070.03319.16
5.4.140.0000.04316.40
5.4.130.0030.03716.53
5.4.120.0030.03316.43
5.4.110.0000.04016.68
5.4.100.0000.03316.66
5.4.90.0030.03316.55
5.4.80.0000.04016.45
5.4.70.0070.03716.50
5.4.60.0130.02316.44
5.4.50.0030.03716.41
5.4.40.0030.03716.68
5.4.30.0030.03716.24
5.4.20.0130.02316.23
5.4.10.0000.04316.52
5.4.00.0000.04015.79
5.3.290.0170.03314.68
5.3.280.0000.03014.73
5.3.270.0000.04014.47
5.3.260.0000.04314.65
5.3.250.0000.04314.69
5.3.240.0000.03714.84
5.3.230.0000.04014.59
5.3.220.0030.03014.43
5.3.210.0000.04314.56
5.3.200.0070.03014.66
5.3.190.0100.03014.57
5.3.180.0070.02714.57
5.3.170.0000.04314.59
5.3.160.0000.04014.60
5.3.150.0000.04314.79
5.3.140.0070.03714.55
5.3.130.0000.04714.56
5.3.120.0000.03314.68
5.3.110.0030.04314.54
5.3.100.0030.03014.12
5.3.90.0000.03014.03
5.3.80.0030.03314.02
5.3.70.0030.03713.88
5.3.60.0100.03014.01
5.3.50.0030.03313.95
5.3.40.0000.04014.09
5.3.30.0000.04014.04
5.3.20.0000.03713.71
5.3.10.0070.03313.67
5.3.00.0000.03713.64
5.2.170.0000.03311.46
5.2.160.0000.03311.46
5.2.150.0000.03311.46
5.2.140.0000.02711.46
5.2.130.0030.03011.46
5.2.120.0130.02011.46
5.2.110.0030.02711.46
5.2.100.0000.03311.46
5.2.90.0100.03011.46
5.2.80.0000.03311.46
5.2.70.0000.03311.46
5.2.60.0000.02711.46
5.2.50.0000.03311.46
5.2.40.0070.02011.46
5.2.30.0000.03311.46
5.2.20.0030.03011.46
5.2.10.0000.03011.46
5.2.00.0070.02711.46
5.1.60.0000.03011.46
5.1.50.0000.02711.46
5.1.40.0000.02011.46
5.1.30.0000.03011.46
5.1.20.0030.02711.46
5.1.10.0000.02311.46
5.1.00.0000.02711.46
5.0.50.0000.02311.46
5.0.40.0000.01711.46
5.0.30.0000.02711.46
5.0.20.0000.02011.46
5.0.10.0000.01711.46
5.0.00.0030.02311.46
4.4.90.0000.01711.46
4.4.80.0000.01711.46
4.4.70.0000.01711.46
4.4.60.0000.01711.46
4.4.50.0000.01711.46
4.4.40.0030.02311.46
4.4.30.0030.01311.46
4.4.20.0000.01711.46
4.4.10.0000.01711.46
4.4.00.0000.02711.46
4.3.110.0000.01311.46
4.3.100.0000.01311.46
4.3.90.0000.01311.46
4.3.80.0000.02011.46
4.3.70.0000.01011.46
4.3.60.0000.01011.46
4.3.50.0030.01011.46
4.3.40.0000.02011.46
4.3.30.0030.01011.46
4.3.20.0030.01011.46
4.3.10.0030.01011.46
4.3.00.0000.01311.46

preferences:
45.76 ms | 401 KiB | 5 Q