3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo {} $foo = new Foo; $rounds = 1000000; $start = microtime(true); for($i=0; $i<$rounds; $i++) { get_class($foo); } echo (microtime(true) - $start); echo "\n"; $start = microtime(true); for($i=0; $i<$rounds; $i++) { (new ReflectionClass($foo))->getName(); } echo (microtime(true) - $start);

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.00.0100.30114.91
7.3.120.0130.41714.67
7.3.110.0030.42714.59
7.3.100.0030.28415.02
7.3.90.0030.27014.98
7.3.80.0030.28015.12
7.3.70.0070.30814.76
7.3.60.0030.24614.67
7.3.50.0030.27114.88
7.3.40.0030.25114.85
7.3.30.0000.34114.87
7.3.20.0030.30016.55
7.3.10.0030.25316.61
7.3.00.0070.24516.84
7.2.250.0030.50315.18
7.2.240.0030.37714.93
7.2.230.0030.38715.17
7.2.220.0100.34914.97
7.2.210.0030.40414.81
7.2.200.0030.40715.15
7.2.190.0100.40015.21
7.2.180.0030.44715.11
7.2.170.0100.38414.78
7.2.00.0030.28319.62
7.1.330.0030.58015.82
7.1.320.0100.50215.78
7.1.310.0100.53815.66
7.1.300.0030.57315.95
7.1.290.0100.52815.84
7.1.280.0030.49515.89
7.1.270.0000.54615.86
7.1.260.0000.52216.04
7.1.70.0100.25417.33
7.1.60.0630.28519.32
7.1.50.0070.36317.03
7.1.00.0030.37322.43
7.0.200.0100.30216.70
7.0.140.0070.43722.04
7.0.110.0000.32019.97
7.0.100.0130.37019.84
7.0.90.0070.39720.03
7.0.80.0130.36319.97
7.0.70.0070.33020.04
7.0.60.0030.34719.95
7.0.50.0070.34720.24
7.0.40.0100.36020.19
7.0.30.0070.38320.25
7.0.20.0030.35320.28
7.0.10.0100.36020.04
7.0.00.0030.31020.15
5.6.280.0030.66720.89
5.6.260.0070.66720.66
5.6.250.0070.58720.50
5.6.240.0030.64020.69
5.6.230.0030.63320.69
5.6.220.0030.66020.84
5.6.210.0100.64320.73
5.6.200.0030.63020.96
5.6.190.0170.65321.11
5.6.180.0170.62721.19
5.6.170.0070.64021.14
5.6.160.0030.64320.98
5.6.150.0230.64721.22
5.6.140.0170.62720.99
5.6.130.0130.62720.94
5.6.120.0130.65321.09
5.6.110.0100.62321.17
5.6.100.0030.63021.04
5.6.90.0000.64721.00
5.6.80.0100.63320.52
5.6.70.0100.62720.32
5.6.60.0030.64720.58
5.6.50.0100.77720.52
5.6.40.0070.60720.31
5.6.30.0030.59020.44
5.6.20.0030.60320.57
5.6.10.0070.66320.57
5.6.00.0070.59020.60
5.5.380.0070.58720.41
5.5.370.0130.65720.55
5.5.360.0100.66720.24
5.5.350.0100.68020.52
5.5.340.0100.65320.84
5.5.330.0070.66020.78
5.5.320.0100.67320.67
5.5.310.0070.68020.80
5.5.300.0130.67320.74
5.5.290.0100.66320.89
5.5.280.0000.65320.84
5.5.270.0030.65320.77
5.5.260.0070.64721.01
5.5.250.0070.65320.55
5.5.240.0170.63320.37
5.5.230.0070.63720.28
5.5.220.0070.65020.14
5.5.210.0100.64020.02
5.5.200.0100.63020.36
5.5.190.0070.65320.36
5.5.180.0030.63020.38
5.5.160.0130.62320.30
5.5.150.0100.62320.11
5.5.140.0030.66020.35
5.5.130.0070.64320.33
5.5.120.0030.65320.19
5.5.110.0130.64020.36
5.5.100.0170.65720.27
5.5.90.0070.67320.00
5.5.80.0070.64320.19
5.5.70.0030.65320.15
5.5.60.0000.66720.03
5.5.50.0100.65020.13
5.5.40.0070.64320.25
5.5.30.0030.66019.97
5.5.20.0100.65020.15
5.5.10.0100.71720.11
5.5.00.0130.65020.09
5.4.450.0070.65319.47
5.4.440.0070.63719.43
5.4.430.0030.64319.65
5.4.420.0070.64719.55
5.4.410.0100.64719.43
5.4.400.0070.63319.29
5.4.390.0100.63718.95
5.4.380.0070.65319.34
5.4.370.0100.61319.00
5.4.360.0130.64019.25
5.4.350.0030.56719.02
5.4.340.0030.59719.34
5.4.320.0030.61019.09
5.4.310.0100.59719.31
5.4.300.0200.60019.33
5.4.290.0070.63018.95
5.4.280.0100.63319.33
5.4.270.0170.61319.04
5.4.260.0100.64019.00
5.4.250.0070.63019.31
5.4.240.0070.63319.14
5.4.230.0070.62319.30
5.4.220.0130.63719.19
5.4.210.0070.63019.16
5.4.200.0070.63719.16
5.4.190.0070.64719.00
5.4.180.0070.66319.33
5.4.170.0070.66319.07
5.4.160.0030.59718.96
5.4.150.0130.64019.01
5.4.140.0130.59716.48
5.4.130.0070.69316.55
5.4.120.0070.63716.34
5.4.110.0030.63016.59
5.4.100.0030.64016.55
5.4.90.0000.66316.71
5.4.80.0100.62716.34
5.4.70.0030.62716.30
5.4.60.0070.64316.49
5.4.50.0100.63716.54
5.4.40.0070.62716.44
5.4.30.0070.62016.44
5.4.20.0070.61716.23
5.4.10.0170.61016.44
5.4.00.0030.64715.84
5.3.290.0000.04314.70
5.3.280.0030.08014.61
5.3.270.0100.06714.61
5.3.260.0100.06314.62
5.3.250.0030.07014.62
5.3.240.0130.07314.60
5.3.230.0100.07014.68
5.3.220.0030.04714.58
5.3.210.0100.07014.68
5.3.200.0100.07314.42
5.3.190.0070.07314.79
5.3.180.0070.07314.71
5.3.170.0100.07014.56
5.3.160.0170.06714.54
5.3.150.0070.07714.57
5.3.140.0000.08714.68
5.3.130.0030.07714.54
5.3.120.0070.08014.54
5.3.110.0100.07314.51
5.3.100.0130.06713.89
5.3.90.0100.07014.03
5.3.80.0030.08014.24
5.3.70.0100.04714.05
5.3.60.0100.07314.03
5.3.50.0130.06314.07
5.3.40.0030.06013.90
5.3.30.0000.07713.91
5.3.20.0130.06713.77
5.3.10.0100.06713.51
5.3.00.0070.05713.66
5.2.170.0100.06011.82
5.2.160.0070.05711.82
5.2.150.0030.06311.82
5.2.140.0030.06311.82
5.2.130.0030.06311.82
5.2.120.0070.06311.82
5.2.110.0030.06711.82
5.2.100.0170.03011.82
5.2.90.0030.06311.82
5.2.80.0030.05711.82
5.2.70.0000.07011.82
5.2.60.0030.04311.82
5.2.50.0000.06311.82
5.2.40.0100.05711.82
5.2.30.0070.06011.82
5.2.20.0030.06711.82
5.2.10.0100.04311.82
5.2.00.0100.02711.82
5.1.60.0070.04311.82
5.1.50.0000.05711.82
5.1.40.0100.04311.82
5.1.30.0130.04011.82
5.1.20.0030.05711.82
5.1.10.0030.06011.82
5.1.00.0070.05311.82
5.0.50.0030.04711.82
5.0.40.0130.03011.82
5.0.30.0000.05311.82
5.0.20.0130.03011.82
5.0.10.0100.04011.82
5.0.00.0000.06711.82
4.4.90.0000.03711.82
4.4.80.0030.02011.82
4.4.70.0100.02011.82
4.4.60.0030.03311.82
4.4.50.0000.04011.82
4.4.40.0030.05011.82
4.4.30.0000.04011.82
4.4.20.0100.02711.82
4.4.10.0000.03711.82
4.4.00.0130.04011.82
4.3.110.0030.03311.82
4.3.100.0030.03311.82
4.3.90.0000.03711.82
4.3.80.0070.05011.82
4.3.70.0000.03711.82
4.3.60.0070.03011.82
4.3.50.0030.03311.82
4.3.40.0030.05011.82
4.3.30.0030.02711.82
4.3.20.0030.01711.82
4.3.10.0030.03311.82
4.3.00.0000.03711.82

preferences:
38.55 ms | 401 KiB | 5 Q