3v4l.org

run code in 300+ PHP versions simultaneously
<?php function exception_error_handler($severity, $message, $file, $line) { if (!(error_reporting() & $severity)) { // This error code is not included in error_reporting return; } throw new ErrorException($message, 0, $severity, $file, $line); } set_error_handler("exception_error_handler"); $o=new StdClass(); $o->f=function(){ echo "i ran!"; }; try{ $o->f(); }catch(Throwable $ex){ echo 'didn\'t work: $o->f()',PHP_EOL; } try{ call_user_func([$o,'f']); }catch(Throwable $ex){ echo 'didn\'t work: call_user_func([$o,\'f\'])',PHP_EOL; } try{ get_object_vars($o)['f'](); }catch(Throwable $ex){var_dump($ex); echo 'didn\'t work: get_object_vars($o)[\'f\']()',PHP_EOL; }

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.70.0150.00316.75
8.3.60.0070.01017.00
8.3.50.0130.00316.72
8.3.40.0080.00818.83
8.3.30.0040.01118.79
8.3.20.0070.00020.87
8.3.10.0040.00421.75
8.3.00.0000.00821.94
8.2.180.0160.00618.54
8.2.170.0000.01522.96
8.2.160.0030.01320.52
8.2.150.0060.00324.18
8.2.140.0070.00024.66
8.2.130.0040.00426.16
8.2.120.0030.00919.26
8.2.110.0050.00521.11
8.2.100.0040.00818.22
8.2.90.0050.00319.17
8.2.80.0000.00817.97
8.2.70.0000.00817.75
8.2.60.0040.00417.63
8.2.50.0000.00817.75
8.2.40.0030.00518.09
8.2.30.0070.00019.52
8.2.20.0000.00718.09
8.2.10.0030.00619.34
8.2.00.0000.00719.23
8.1.280.0210.00025.92
8.1.270.0060.00320.52
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0080.00022.17
8.1.230.0000.01119.15
8.1.220.0040.00417.74
8.1.210.0000.00818.77
8.1.200.0060.00317.24
8.1.190.0000.00817.35
8.1.180.0030.00618.10
8.1.170.0080.00018.65
8.1.160.0040.00418.93
8.1.150.0030.00518.99
8.1.140.0040.00420.77
8.1.130.0000.00717.37
8.1.120.0040.00417.55
8.1.110.0050.00317.52
8.1.100.0000.00817.43
8.1.90.0040.00417.54
8.1.80.0050.00317.41
8.1.70.0030.00517.47
8.1.60.0030.00617.62
8.1.50.0090.00017.46
8.1.40.0040.00417.57
8.1.30.0080.00017.68
8.1.20.0000.00917.67
8.1.10.0050.00317.65
8.1.00.0090.00317.56
8.0.300.0060.00318.77
8.0.290.0070.00016.88
8.0.280.0000.00718.48
8.0.270.0030.00318.03
8.0.260.0040.00416.84
8.0.250.0000.00716.97
8.0.240.0000.00617.07
8.0.230.0000.00717.04
8.0.220.0000.00717.03
8.0.210.0000.00717.01
8.0.200.0050.00216.95
8.0.190.0000.00717.05
8.0.180.0030.00517.04
8.0.170.0040.00416.96
8.0.160.0000.00817.03
8.0.150.0000.00717.00
8.0.140.0000.00716.94
8.0.130.0000.00613.39
8.0.120.0040.00416.86
8.0.110.0000.00717.00
8.0.100.0040.00416.93
8.0.90.0060.00317.03
8.0.80.0100.00616.99
8.0.70.0000.00716.89
8.0.60.0080.00017.04
8.0.50.0000.00716.88
8.0.30.0030.01317.34
8.0.20.0120.01017.29
8.0.10.0000.00717.08
8.0.00.0060.01316.58
7.4.330.0000.00516.71
7.4.320.0000.00716.53
7.4.300.0070.00016.55
7.4.290.0030.00316.54
7.4.280.0100.00016.55
7.4.270.0030.00316.54
7.4.260.0050.00013.29
7.4.250.0040.00416.57
7.4.240.0030.00316.54
7.4.230.0000.00716.54
7.4.220.0040.00316.63
7.4.210.0030.01116.63
7.4.200.0030.00316.71
7.4.140.0070.01117.86
7.4.130.0080.01216.52
7.4.120.0130.01016.59
7.4.110.0120.00616.54
7.4.100.0100.00716.70
7.4.90.0120.00616.45
7.4.80.0030.01319.39
7.4.70.0160.00416.55
7.4.60.0110.01116.53
7.4.50.0120.00716.62
7.4.40.0120.00916.53
7.4.30.0110.01216.50
7.4.20.0090.00916.43
7.4.10.0090.00916.49
7.4.00.0080.00916.57
7.3.330.0000.00916.46
7.3.320.0030.00313.33
7.3.310.0050.00216.39
7.3.300.0020.00516.38
7.3.290.0000.00716.41
7.3.280.0090.01216.45
7.3.260.0070.01016.40
7.3.230.0100.00616.51
7.3.210.0030.01516.51
7.3.200.0060.01116.40
7.3.190.0070.01016.50
7.3.180.0140.00716.54
7.3.170.0050.01616.32
7.3.160.0190.00516.39
7.3.150.0120.00716.38
7.3.140.0120.00616.39
7.3.130.0090.01016.42
7.3.120.0110.00816.44
7.3.110.0070.01016.38
7.3.100.0090.00816.35
7.3.90.0090.00916.45
7.3.80.0070.01016.42
7.3.70.0090.01016.40
7.3.60.0100.00916.36
7.3.50.0100.00816.34
7.3.40.0080.01116.37
7.3.30.0110.00916.40
7.3.20.0130.01016.38
7.3.10.0100.00816.37
7.3.00.0110.00816.42
7.2.330.0100.01016.50
7.2.320.0090.00916.37
7.2.310.0150.00616.73
7.2.300.0130.01016.71
7.2.290.0110.01416.84
7.2.280.0060.01216.64
7.2.270.0090.01016.51
7.2.260.0120.00816.52
7.2.250.0090.00916.56
7.2.240.0090.01016.53
7.2.230.0100.00816.58
7.2.220.0090.01016.55
7.2.210.0090.01016.61
7.2.200.0110.00816.54
7.2.190.0120.00816.54
7.2.180.0120.00716.56
7.2.170.0100.01016.57
7.2.160.0080.01116.52
7.2.150.0170.00916.64
7.2.140.0080.01216.62
7.2.130.0100.01116.59
7.2.120.0120.01016.65
7.2.110.0130.00916.58
7.2.100.0110.01116.58
7.2.90.0140.01016.61
7.2.80.0120.00916.58
7.2.70.0120.01016.58
7.2.60.0080.01116.56
7.2.50.0090.01216.54
7.2.40.0100.01116.60
7.2.30.0090.01216.61
7.2.20.0100.00916.63
7.2.10.0100.01316.57
7.2.00.0140.01116.54
7.1.330.0130.01015.68
7.1.320.0140.00915.54
7.1.310.0120.01215.49
7.1.300.0130.00815.47
7.1.290.0090.01315.59
7.1.280.0160.00715.46
7.1.270.0130.01015.43
7.1.260.0120.01015.33
7.1.250.0170.00815.40
7.1.240.0150.01315.55
7.1.230.0170.01115.39
7.1.220.0140.01215.45
7.1.210.0170.00715.49
7.1.200.0100.01315.44
7.1.190.0160.00715.50
7.1.180.0150.00715.58
7.1.170.0150.00915.46
7.1.160.0200.00515.50
7.1.150.0170.00715.42
7.1.140.0080.01315.41
7.1.130.0160.00715.35
7.1.120.0090.01215.46
7.1.110.0130.00815.42
7.1.100.0100.01315.49
7.1.90.0130.00815.42
7.1.80.0090.01115.35
7.1.70.0140.01015.47
7.1.60.0130.00915.54
7.1.50.0100.01115.47
7.1.40.0120.00915.54
7.1.30.0140.00815.55
7.1.20.0090.01015.47
7.1.10.0110.00815.50
7.1.00.0120.00815.59
7.0.330.0150.00815.09
7.0.320.0160.00815.17
7.0.310.0160.00615.13
7.0.300.0130.00815.08
7.0.290.0130.01215.23
7.0.280.0080.01115.04
7.0.270.0130.00815.16
7.0.260.0100.01015.13
7.0.250.0120.00915.16
7.0.240.0130.00815.27
7.0.230.0130.00915.25
7.0.220.0200.00515.23
7.0.210.0160.00915.21
7.0.200.0240.00215.16
7.0.190.0170.01015.33
7.0.180.0110.01015.20
7.0.170.0110.01115.18
7.0.160.0120.00815.17
7.0.150.0120.00915.19
7.0.140.0120.00715.21
7.0.130.0150.00515.21
7.0.120.0180.00615.26
7.0.110.0100.01215.12
7.0.100.0160.00515.14
7.0.90.0160.00715.20
7.0.80.0130.01015.09
7.0.70.0150.00715.18
7.0.60.0120.00815.07
7.0.50.0170.00715.11
7.0.40.0150.00915.15
7.0.30.0230.00815.24
7.0.20.0190.00515.00
7.0.10.0230.00515.11
7.0.00.0130.00815.18
5.6.400.0140.00915.57
5.6.390.0110.01215.58
5.6.380.0140.01315.82
5.6.370.0110.01215.63
5.6.360.0170.01215.65
5.6.350.0110.01115.65
5.6.340.0130.01015.33
5.6.330.0110.01115.51
5.6.320.0090.01415.61
5.6.310.0140.01015.55
5.6.300.0130.00815.48
5.6.290.0100.00915.55
5.6.280.0110.01215.62
5.6.270.0120.01415.75
5.6.260.0130.01315.57
5.6.250.0130.00815.72
5.6.240.0120.01315.63
5.6.230.0130.01015.51
5.6.220.0120.01115.60
5.6.210.0120.01315.52
5.6.200.0140.01115.62
5.6.190.0130.01115.62
5.6.180.0130.01315.63
5.6.170.0100.01215.46
5.6.160.0140.00915.61
5.6.150.0140.00815.58
5.6.140.0110.01215.54
5.6.130.0110.01215.52
5.6.120.0150.00915.53
5.6.110.0150.00915.63
5.6.100.0160.01015.63
5.6.90.0150.00915.64
5.6.80.0150.00715.55
5.6.70.0110.01215.43
5.6.60.0100.01115.45
5.6.50.0130.01215.44
5.6.40.0120.01015.45
5.6.30.0170.00915.38
5.6.20.0120.00915.57
5.6.10.0100.01315.42
5.6.00.0100.01415.44
5.5.380.0130.01115.61
5.5.370.0130.01315.46
5.5.360.0120.01315.40
5.5.350.0140.01015.40
5.5.340.0150.01015.54
5.5.330.0140.01115.47
5.5.320.0120.01215.49
5.5.310.0150.00915.52
5.5.300.0100.01315.43
5.5.290.0090.01515.56
5.5.280.0180.00915.54
5.5.270.0140.01115.35
5.5.260.0130.01415.45
5.5.250.0160.01115.37
5.5.240.0120.01615.46
5.5.230.0160.00815.43
5.5.220.0150.01315.46
5.5.210.0120.01215.29
5.5.200.0150.01015.53
5.5.190.0170.00815.39
5.5.180.0130.01115.51
5.5.170.0180.01015.45
5.5.160.0130.01015.30
5.5.150.0160.00915.36
5.5.140.0110.01515.40
5.5.130.0120.01315.30
5.5.120.0160.00715.39
5.5.110.0130.01015.35
5.5.100.0070.01715.44
5.5.90.0130.01415.40
5.5.80.0130.01215.49
5.5.70.0130.01315.34
5.5.60.0200.00715.50
5.5.50.0140.01015.55
5.5.40.0140.01215.45
5.5.30.0120.01115.40
5.5.20.0140.01115.48
5.5.10.0130.01315.48
5.5.00.0160.01115.24
5.4.450.0090.01312.43
5.4.440.0140.00812.48
5.4.430.0080.01112.49
5.4.420.0140.00712.35
5.4.410.0140.00712.46
5.4.400.0110.01012.29
5.4.390.0160.00312.34
5.4.380.0080.01212.44
5.4.370.0160.00312.38
5.4.360.0150.00612.36
5.4.350.0130.00512.22
5.4.340.0130.00712.37
5.4.330.0130.00812.23
5.4.320.0070.01012.36
5.4.310.0100.01012.31
5.4.300.0150.00612.35
5.4.290.0090.01012.31
5.4.280.0100.00912.29
5.4.270.0090.01012.25
5.4.260.0110.01012.38
5.4.250.0140.00912.35
5.4.240.0120.00912.29
5.4.230.0110.00712.35
5.4.220.0120.00612.34
5.4.210.0110.01012.32
5.4.200.0090.00912.22
5.4.190.0100.00912.27
5.4.180.0110.00912.42
5.4.170.0110.01012.21
5.4.160.0090.01112.34
5.4.150.0130.00712.24
5.4.140.0090.00912.22
5.4.130.0120.00912.28
5.4.120.0140.00812.25
5.4.110.0100.01112.30
5.4.100.0120.00912.36
5.4.90.0120.00812.29
5.4.80.0140.00612.33
5.4.70.0080.01012.37
5.4.60.0110.00812.35
5.4.50.0050.01412.38
5.4.40.0110.00812.36
5.4.30.0050.01212.42
5.4.20.0050.01512.41
5.4.10.0110.01012.31
5.4.00.0130.00512.37
5.3.290.0110.01112.93
5.3.280.0130.00612.67
5.3.270.0110.00912.82
5.3.260.0100.01412.75
5.3.250.0100.01212.72
5.3.240.0090.01012.63
5.3.230.0070.01412.67
5.3.220.0100.01112.67
5.3.210.0110.01012.79
5.3.200.0150.00712.74
5.3.190.0150.00912.86
5.3.180.0100.01012.87
5.3.170.0070.01112.89
5.3.160.0060.01212.87
5.3.150.0100.01012.85
5.3.140.0060.01312.85
5.3.130.0120.00812.85
5.3.120.0100.01212.79
5.3.110.0080.01212.81
5.3.100.0090.01012.85
5.3.90.0170.00512.88
5.3.80.0110.01112.75
5.3.70.0130.00812.78
5.3.60.0100.00912.81
5.3.50.0060.01312.81
5.3.40.0130.00712.75
5.3.30.0100.00912.76
5.3.20.0070.01312.74
5.3.10.0070.01212.55
5.3.00.0090.01212.52
5.2.170.0070.00911.81
5.2.160.0100.00911.88
5.2.150.0060.00911.99
5.2.140.0080.00811.76
5.2.130.0110.00611.77
5.2.120.0060.01311.82
5.2.110.0100.00711.78
5.2.100.0080.01011.76
5.2.90.0080.01011.76
5.2.80.0110.00711.70
5.2.70.0140.00911.74
5.2.60.0140.00211.60
5.2.50.0080.00811.72
5.2.40.0090.00911.75
5.2.30.0100.00911.70
5.2.20.0110.00711.57
5.2.10.0110.00511.45
5.2.00.0080.00811.39
5.1.60.0110.00410.95
5.1.50.0080.00811.04
5.1.40.0080.00711.06
5.1.30.0100.00711.10
5.1.20.0080.00611.03
5.1.10.0080.00411.05
5.1.00.0070.00810.98
5.0.50.0090.00710.85
5.0.40.0070.00610.85
5.0.30.0080.00510.85
5.0.20.0070.00510.85
5.0.10.0040.00910.85
5.0.00.0050.00710.85
4.4.90.0070.00210.85
4.4.80.0040.00310.85
4.4.70.0060.00210.85
4.4.60.0060.00310.85
4.4.50.0050.00310.85
4.4.40.0050.00310.85
4.4.30.0040.00310.85
4.4.20.0060.00310.85
4.4.10.0020.00610.85
4.4.00.0050.00210.85
4.3.110.0060.00110.85
4.3.100.0060.00210.85
4.3.90.0060.00210.85
4.3.80.0010.00710.85
4.3.70.0060.00410.85
4.3.60.0040.00410.85
4.3.50.0040.00310.85
4.3.40.0030.00510.85
4.3.30.0040.00310.85
4.3.20.0060.00010.85
4.3.10.0020.00510.85
4.3.00.0040.00310.85

preferences:
72.96 ms | 400 KiB | 5 Q