3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(E_ALL); $iterations = 1000000; $start = microtime(true); for ($i=0; $i<$iterations; $i++) { $page = @$_GET['page'] ?: 'home'; } $suppressedTime = round(microtime(true) - $start, 8); $start = microtime(true); for ($i=0; $i<$iterations; $i++) { $page = isset($_GET['page']) ? $_GET['page'] : 'home'; } $issetTime = round(microtime(true) - $start, 8); echo "results for {$iterations} iterations:\n\n"; echo "suppressed time: {$suppressedTime}\n"; echo "isset time: {$issetTime}\n\n"; echo "speed difference: " . round(100 / $suppressedTime * $issetTime, 2) . "%";

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.2.00.0030.26519.57
7.1.70.0070.25417.20
7.1.60.0030.27517.22
7.1.50.0100.28017.12
7.1.00.0030.35322.41
7.0.200.0070.29016.46
7.0.140.0000.36722.08
7.0.100.0100.32020.07
7.0.90.0070.31019.96
7.0.80.0130.30020.00
7.0.70.0030.32720.14
7.0.60.0030.26719.99
7.0.50.0100.31020.30
7.0.40.0100.28720.13
7.0.30.0100.32320.08
7.0.20.0230.28020.09
7.0.10.0000.31720.07
7.0.00.0100.32020.08
5.6.280.0070.61721.13
5.6.250.0070.47020.61
5.6.240.0100.48320.60
5.6.230.0030.47020.63
5.6.220.0100.50720.74
5.6.210.0070.48320.78
5.6.200.0100.46021.08
5.6.190.0030.40720.94
5.6.180.0100.44321.17
5.6.170.0000.47021.03
5.6.160.0130.46721.01
5.6.150.0170.44321.01
5.6.140.0130.48321.17
5.6.130.0100.53021.02
5.6.120.0130.49720.93
5.6.110.0100.40021.00
5.6.100.0030.43321.10
5.6.90.0030.45021.07
5.6.80.0030.44320.40
5.6.70.0070.40720.42
5.6.60.0100.39020.44
5.6.50.0100.48020.40
5.6.40.0370.45720.33
5.6.30.0030.49320.32
5.6.20.0070.41320.42
5.6.10.0100.42020.38
5.6.00.0200.46320.44
5.5.380.0130.46020.41
5.5.370.0100.54020.46
5.5.360.0130.52020.36
5.5.350.0100.51720.38
5.5.340.0130.47320.92
5.5.330.0030.45020.77
5.5.320.0070.48020.65
5.5.310.0030.45320.79
5.5.300.0100.54320.73
5.5.290.0030.53020.77
5.5.280.0130.45720.74
5.5.270.0070.44020.87
5.5.260.0030.48320.87
5.5.250.0000.45020.65
5.5.240.0500.39020.30
5.5.230.0130.45319.99
5.5.220.0030.39720.12
5.5.210.0100.46320.18
5.5.200.0100.47720.26
5.5.190.0170.44320.19
5.5.180.0070.47720.25
5.5.160.0100.45320.15
5.5.150.0070.47320.25
5.5.140.0030.48020.13
5.5.130.0030.44720.15
5.5.120.0030.49720.26
5.5.110.0030.48019.99
5.5.100.0070.46719.98
5.5.90.0100.45020.04
5.5.80.0030.44720.09
5.5.70.0030.42019.96
5.5.60.0130.45020.15
5.5.50.0330.38020.04
5.5.40.0100.45720.16
5.5.30.0070.41020.07
5.5.20.0000.42320.14
5.5.10.0100.49020.04
5.5.00.0030.48320.13
5.4.450.0070.45719.29
5.4.440.0030.42319.51
5.4.430.0030.42719.46
5.4.420.0070.47019.41
5.4.410.0870.35719.03
5.4.400.0000.41718.85
5.4.390.0100.33719.11
5.4.380.0030.39318.96
5.4.370.0070.46719.06
5.4.360.0030.45319.11
5.4.350.0000.45718.98
5.4.340.0030.46719.05
5.4.320.0100.48719.09
5.4.310.0100.43319.03
5.4.300.0030.43719.01
5.4.290.0070.41719.15
5.4.280.0100.46718.96
5.4.270.0000.45018.84
5.4.260.0030.51019.06
5.4.250.0100.52319.14
5.4.240.0030.43718.84
5.4.230.0100.51019.15
5.4.220.0130.40019.15
5.4.210.0170.47319.08
5.4.200.0030.40319.07
5.4.190.0130.47018.94
5.4.180.0100.42718.99
5.4.170.0070.48719.15
5.4.160.0030.56319.08
5.4.150.0230.44718.95
5.4.140.0100.47016.35
5.4.130.0070.45316.12
5.4.120.0100.45316.27
5.4.110.0030.46016.27
5.4.100.0070.47716.37
5.4.90.0100.45716.27
5.4.80.0000.46316.22
5.4.70.0170.45716.20
5.4.60.0100.51016.38
5.4.50.0030.46716.41
5.4.40.0030.50716.30
5.4.30.0130.45316.43
5.4.20.0070.51316.42
5.4.10.0130.52716.38
5.4.00.0100.46315.81
5.3.290.0100.62714.63
5.3.280.0030.63714.50
5.3.270.0000.63014.54
5.3.260.0070.60314.54
5.3.250.0000.71314.61
5.3.240.0030.61714.57
5.3.230.0130.60314.66
5.3.220.0100.62314.52
5.3.210.0070.67314.63
5.3.200.0070.68714.50
5.3.190.0070.63314.52
5.3.180.0100.59714.50
5.3.170.0030.65314.50
5.3.160.0000.65714.55
5.3.150.0130.64314.55
5.3.140.0100.66314.54
5.3.130.0030.70314.48
5.3.120.0600.58714.45
5.3.110.0100.58714.50
5.3.100.0170.71014.05
5.3.90.0070.60313.91
5.3.80.0130.66313.95
5.3.70.0030.60014.07
5.3.60.0130.63313.99
5.3.50.0100.59013.95
5.3.40.0070.60313.91
5.3.30.0070.52713.92
5.3.20.0030.48713.56
5.3.10.0030.53013.64
5.3.00.0000.46313.64
5.2.170.0000.07011.06
5.2.160.0070.06011.11
5.2.150.0030.05010.98
5.2.140.0030.03311.16
5.2.130.0000.02711.09
5.2.120.0000.03310.92
5.2.110.0000.04311.08
5.2.100.0000.03311.08
5.2.90.0000.02311.09
5.2.80.0030.03710.93
5.2.70.0000.03010.96
5.2.60.0000.03311.07
5.2.50.0000.03010.86
5.2.40.0000.03010.99
5.2.30.0030.03010.99
5.2.20.0000.02310.88
5.2.10.0030.02710.68
5.2.00.0030.02310.61
5.1.60.0070.02010.03
5.1.50.0000.0239.98
5.1.40.0030.0239.86
5.1.30.0000.02710.26
5.1.20.0000.03010.40
5.1.10.0030.02010.12
5.1.00.0000.02310.06
5.0.50.0030.0208.83
5.0.40.0000.0178.83
5.0.30.0000.0408.83
5.0.20.0000.0208.83
5.0.10.0000.0208.83
5.0.00.0030.0238.83
4.4.90.0000.0178.83
4.4.80.0000.0278.83
4.4.70.0070.0138.83
4.4.60.0000.0138.83
4.4.50.0000.0138.83
4.4.40.0030.0238.83
4.4.30.0000.0178.83
4.4.20.0030.0138.83
4.4.10.0030.0108.83
4.4.00.0100.0378.83
4.3.110.0000.0138.83
4.3.100.0000.0138.83
4.3.90.0030.0138.83
4.3.80.0070.0238.83
4.3.70.0030.0108.83
4.3.60.0000.0138.83
4.3.50.0070.0078.83
4.3.40.0000.0238.83
4.3.30.0000.0238.83
4.3.20.0070.0138.83
4.3.10.0000.0178.83
4.3.00.0000.0178.83

preferences:
34.28 ms | 401 KiB | 5 Q