3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class ExceptionA extends Exception {} class ExceptionB extends ExceptionA {} class ExceptionTest { public function example() { try { throw new ExceptionB(); } catch ( ExceptionB $e ) { echo 'ExceptionB was caught'; } catch ( ExceptionA $e ) { echo 'ExceptionA was caught'; } catch ( Exception $e ) { echo 'Exception was caught'; } } } (new ExceptionTest())->example();

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.5.10.0090.00818.74
8.5.00.0100.01220.12
8.4.160.0130.00823.90
8.4.150.0080.00417.86
8.4.140.0140.00717.84
8.4.130.0150.00617.65
8.4.120.0040.00520.55
8.4.110.0080.01018.88
8.4.100.0130.00818.52
8.4.90.0090.00718.60
8.4.80.0090.00920.70
8.4.70.0050.00518.08
8.4.60.0120.00820.37
8.4.50.0140.00618.03
8.4.40.0100.01019.51
8.4.30.0100.00718.84
8.4.20.0000.02120.49
8.4.10.0040.00419.54
8.3.280.0020.00114.05
8.3.270.0100.00816.53
8.3.260.0080.00616.73
8.3.250.0120.00517.01
8.3.240.0060.00316.69
8.3.230.0130.00416.91
8.3.220.0130.00618.82
8.3.210.0070.00316.77
8.3.200.0040.00516.70
8.3.190.0050.00317.41
8.3.180.0120.00718.26
8.3.170.0160.00316.43
8.3.160.0120.00618.52
8.3.150.0110.00816.32
8.3.140.0120.00618.38
8.3.130.0090.00016.62
8.3.120.0060.00320.84
8.3.110.0000.00920.94
8.3.100.0150.00020.36
8.3.90.0000.00826.77
8.3.80.0190.00925.10
8.3.70.0290.00523.72
8.3.60.0280.00324.70
8.3.50.0120.00626.01
8.3.40.0250.00624.75
8.3.30.0240.00924.77
8.3.20.0200.00325.72
8.3.10.0110.00724.58
8.3.00.0140.00523.08
8.2.290.0100.00620.55
8.2.280.0110.00818.30
8.2.270.0030.01017.09
8.2.260.0000.00818.52
8.2.250.0060.00316.64
8.2.240.0050.00519.14
8.2.230.0070.00322.58
8.2.220.0080.00024.06
8.2.210.0040.00726.77
8.2.200.0110.00424.86
8.2.190.0090.00924.75
8.2.180.0110.00724.63
8.2.170.0140.00424.93
8.2.160.0210.01026.50
8.2.150.0180.00228.25
8.2.140.0110.00324.95
8.2.130.0090.00424.44
8.2.120.0090.00623.40
8.2.110.0130.00422.79
8.2.100.0140.00321.32
8.2.90.0110.00621.26
8.2.80.0100.00521.58
8.2.70.0110.00521.23
8.2.60.0110.00820.44
8.2.50.0140.00820.55
8.2.40.0170.00320.69
8.2.30.0130.00620.28
8.2.20.0150.00420.10
8.2.10.0110.00520.02
8.2.00.0120.00519.95
8.1.330.0120.00722.04
8.1.320.0120.00616.35
8.1.310.0030.01418.42
8.1.300.0040.01516.46
8.1.290.0200.00530.84
8.1.280.0180.00828.38
8.1.270.0170.00223.99
8.1.260.0130.00425.28
8.1.250.0110.00526.22
8.1.240.0090.00821.47
8.1.230.0120.00721.56
8.1.220.0160.00220.63
8.1.210.0110.00621.07
8.1.200.0100.00620.44
8.1.190.0130.00519.97
8.1.180.0110.00620.10
8.1.170.0090.00820.10
8.1.160.0140.00320.40
8.1.150.0130.00620.14
8.1.140.0130.00620.26
8.1.130.0110.00420.25
8.1.120.0090.00619.39
8.1.110.0100.00619.73
8.1.100.0090.00619.33
8.1.90.0100.00519.77
8.1.80.0110.00319.52
8.1.70.0120.00319.37
8.1.60.0090.00519.27
8.1.50.0100.00319.22
8.1.40.0090.00519.32
8.1.30.0100.00519.34
8.1.20.0130.00419.31
8.1.10.0120.00519.11
8.1.00.0140.00419.23
8.0.300.0090.00621.02
8.0.290.0120.00619.79
8.0.280.0130.00419.87
8.0.270.0110.00419.67
8.0.260.0110.00419.68
8.0.250.0110.00319.47
8.0.240.0130.00318.82
8.0.230.0090.00518.87
8.0.220.0080.00618.77
8.0.210.0100.00518.75
8.0.200.0080.00618.65
8.0.190.0080.00518.79
8.0.180.0090.00518.84
8.0.170.0140.00418.76
8.0.160.0110.00418.76
8.0.150.0110.00518.46
8.0.140.0110.00418.33
8.0.130.0100.00518.01
8.0.120.0110.00518.31
8.0.110.0080.00618.66
8.0.100.0100.00618.28
8.0.90.0100.00518.35
8.0.80.0110.00418.37
8.0.70.0090.00518.32
8.0.60.0120.00418.33
8.0.50.0100.00418.44
8.0.30.0090.00618.40
8.0.20.0120.00318.43
8.0.10.0110.00618.44
8.0.00.0090.00618.81
7.4.330.0110.00517.28
7.4.320.0100.00518.67
7.4.300.0100.00518.30
7.4.290.0110.00318.09
7.4.280.0100.00618.11
7.4.270.0120.00517.99
7.4.260.0120.00417.98
7.4.250.0100.00518.01
7.4.240.0110.00517.94
7.4.230.0120.00418.19
7.4.220.0110.00418.01
7.4.210.0130.00517.81
7.4.200.0120.00418.14
7.4.190.0120.00418.20
7.4.180.0120.00518.26
7.4.160.0110.00618.27
7.4.150.0110.00518.04
7.4.140.0110.00518.04
7.4.130.0100.00617.93
7.4.120.0100.00717.80
7.4.110.0120.00617.50
7.4.100.0140.00417.72
7.4.90.0130.00717.49
7.4.80.0140.00617.86
7.4.70.0120.00717.41
7.4.60.0130.00617.48
7.4.50.0130.00717.34
7.4.40.0130.00717.50
7.4.30.0120.00817.49
7.4.20.0130.00617.46
7.4.10.0120.00617.39
7.4.00.0110.00617.50
7.3.330.0120.00518.05
7.3.320.0150.00317.74
7.3.310.0150.00618.00
7.3.300.0140.00617.92
7.3.290.0130.00517.63
7.3.280.0160.00517.87
7.3.270.0140.00617.97
7.3.260.0150.00417.73
7.3.250.0160.00417.87
7.3.240.0160.00517.86
7.3.230.0140.00517.64
7.3.220.0150.00517.57
7.3.210.0160.00517.36
7.3.200.0140.00717.41
7.3.190.0150.00517.41
7.3.180.0130.00517.43
7.3.170.0140.00517.51
7.3.160.0140.00417.42
7.3.150.0120.00617.51
7.3.140.0120.00617.49
7.3.130.0140.00417.38
7.3.120.0110.00717.35
7.3.110.0120.00617.28
7.3.100.0120.00717.24
7.3.90.0110.00717.52
7.3.80.0140.00517.29
7.3.70.0130.00617.36
7.3.60.0140.00617.45
7.3.50.0140.00617.35
7.3.40.0140.00717.40
7.3.30.0130.00717.47
7.3.20.0150.00618.22
7.3.10.0120.00818.16
7.3.00.0120.00718.15
7.2.340.0120.00617.97
7.2.330.0120.00817.53
7.2.320.0130.00717.58
7.2.310.0120.00817.53
7.2.300.0130.00617.58
7.2.290.0120.00617.57
7.2.280.0140.00717.65
7.2.270.0140.00617.65
7.2.260.0120.00817.40
7.2.250.0140.00617.37
7.2.240.0140.00617.49
7.2.230.0120.00617.48
7.2.220.0130.00617.44
7.2.210.0110.00817.46
7.2.200.0140.00617.49
7.2.190.0140.00617.45
7.2.180.0150.00517.43
7.2.170.0140.00617.50
7.2.160.0140.00717.49
7.2.150.0170.00518.38
7.2.140.0140.00718.33
7.2.130.0150.00618.39
7.2.120.0130.00818.38
7.2.110.0120.00818.35
7.2.100.0130.00618.38
7.2.90.0130.00618.33
7.2.80.0140.00618.40
7.2.70.0130.00718.36
7.2.60.0150.00618.37
7.2.50.0130.00618.37
7.2.40.0120.00618.39
7.2.30.0150.00518.40
7.2.20.0130.00618.40
7.2.10.0130.00818.33
7.2.00.0130.00718.36

preferences:
39.05 ms | 403 KiB | 5 Q