3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public $dummy1; public $dummy2; } class ErrorHandler { private $private = 'THIS IS PRIVATE'."\n"; function __construct() { set_error_handler( function ($errno, $errstr, $errfile, $errline) { $this->handleError($errno, $errstr, $errfile, $errline); } ); } private function handleError($errno, $errstr, $errfile, $errline, $errmodule = null) { echo __METHOD__. " dealing with error $errstr, $errfile:$errline\n"; // This attribute is no longer accessible in this object. Same for other // objects and their private attributes once we reach in this state. echo $this->private; echo "Never executed in PHP7.2; there is a fatal error in the line above\n"; } } function reproduceBug(Foo $f) { unset($f->dummy2); foreach ((new ReflectionObject($f))->getProperties() as $p) echo $p->getName() .' = '. $p->getValue($f) ."\n"; echo "This line is not reached in PHP7.2; but it is reached in PHP 7.0\n"; } $errorHandler = new ErrorHandler(); //echo $x; # uncommenting this fixes it reproduceBug(new Foo);

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.0100.00718.43
8.3.50.0120.00318.20
8.3.40.0060.01018.70
8.3.30.0130.00318.93
8.3.20.0080.00018.96
8.3.10.0080.00021.95
8.3.00.0040.00423.66
8.2.180.0110.00718.28
8.2.170.0070.00722.96
8.2.160.0150.00018.86
8.2.150.0040.00424.18
8.2.140.0030.00624.66
8.2.130.0000.00821.08
8.2.120.0000.00826.35
8.2.110.0030.00620.28
8.2.100.0040.00717.91
8.2.90.0040.00418.02
8.2.80.0050.00318.04
8.2.70.0040.00418.05
8.2.60.0040.00418.22
8.2.50.0050.00418.10
8.2.40.0000.00822.32
8.2.30.0040.00420.64
8.2.20.0000.01018.00
8.2.10.0040.00418.09
8.2.00.0080.00018.08
8.1.280.0110.00425.92
8.1.270.0000.00720.37
8.1.260.0000.00826.35
8.1.250.0080.00028.09
8.1.240.0040.00817.11
8.1.230.0110.00022.49
8.1.220.0090.00017.74
8.1.210.0000.00918.77
8.1.200.0030.00617.35
8.1.190.0030.00617.35
8.1.180.0090.00018.10
8.1.170.0040.00418.58
8.1.160.0000.00718.80
8.1.150.0030.00618.89
8.1.140.0040.00418.92
8.1.130.0030.00320.30
8.1.120.0000.00717.54
8.1.110.0000.01117.48
8.1.100.0080.00317.38
8.1.90.0000.00817.50
8.1.80.0050.00317.46
8.1.70.0040.00417.49
8.1.60.0040.00417.62
8.1.50.0040.00717.56
8.1.40.0040.00417.45
8.1.30.0000.01017.63
8.1.20.0030.00517.68
8.1.10.0040.00417.61
8.1.00.0040.00417.43
8.0.300.0080.00021.37
8.0.290.0000.00916.75
8.0.280.0000.00718.52
8.0.270.0000.00717.18
8.0.260.0000.00620.22
8.0.250.0060.00317.02
8.0.240.0040.00416.97
8.0.230.0040.00417.05
8.0.220.0030.00616.95
8.0.210.0070.00016.94
8.0.200.0070.00017.04
8.0.190.0080.00016.95
8.0.180.0000.00817.03
8.0.170.0030.00517.02
8.0.160.0000.00816.88
8.0.150.0040.00416.79
8.0.140.0000.00716.90
8.0.130.0000.00513.42
8.0.120.0030.00616.91
8.0.110.0040.00416.88
8.0.100.0080.00016.90
8.0.90.0000.00716.88
8.0.80.0100.00616.98
8.0.70.0040.00417.02
8.0.60.0000.00817.06
8.0.50.0000.00716.99
8.0.30.0100.01017.16
8.0.20.0050.01717.40
8.0.10.0040.00417.06
8.0.00.0170.00416.90
7.4.330.0000.00515.55
7.4.320.0000.00616.64
7.4.300.0040.00416.55
7.4.290.0030.00316.50
7.4.280.0000.00816.56
7.4.270.0080.00016.47
7.4.260.0000.00716.55
7.4.250.0030.00416.48
7.4.240.0000.00716.66
7.4.230.0040.00416.54
7.4.220.0040.00416.54
7.4.210.0090.00316.57
7.4.200.0040.00416.55
7.4.160.0100.00616.51
7.4.140.0110.00717.86
7.4.130.0040.01316.49
7.4.120.0110.00716.61
7.4.110.0090.01216.56
7.4.100.0100.00716.76
7.4.90.0130.00616.64
7.4.80.0040.01319.39
7.4.70.0060.00916.62
7.4.60.0100.00716.70
7.4.50.0060.00616.57
7.4.40.0170.00616.44
7.4.00.0110.00514.99
7.3.330.0000.00513.46
7.3.320.0060.00013.42
7.3.310.0050.00216.30
7.3.300.0000.00716.41
7.3.290.0120.00616.42
7.3.280.0120.00316.44
7.3.260.0110.00916.55
7.3.240.0140.00816.62
7.3.230.0080.01116.66
7.3.210.0120.00616.52
7.3.200.0090.01316.56
7.3.190.0030.01316.48
7.3.180.0060.01116.55
7.3.170.0070.01016.50
7.3.160.0120.00516.39
7.3.120.0030.01314.96
7.3.110.0070.01014.92
7.3.100.0000.01514.79
7.3.90.0040.01114.79
7.3.80.0110.00414.89
7.3.70.0040.00714.90
7.3.60.0080.00414.90
7.3.50.0000.01414.74
7.3.40.0070.00414.60
7.3.30.0030.01214.96
7.3.20.0060.00916.71
7.3.10.0000.01416.62
7.3.00.0050.00916.47
7.2.330.0140.01016.81
7.2.320.0070.01716.86
7.2.310.0040.01316.52
7.2.300.0120.00616.75
7.2.290.0100.01416.59
7.2.250.0090.00915.16
7.2.240.0170.00314.87
7.2.230.0060.00915.22
7.2.220.0110.00014.76
7.2.210.0060.00614.81
7.2.200.0120.00315.16
7.2.190.0030.00914.93
7.2.180.0070.00314.92
7.2.170.0040.01115.00
7.2.130.0060.01016.89
7.2.120.0040.01117.04
7.2.110.0060.00316.91
7.2.100.0950.00715.66
7.2.90.3270.00815.64
7.2.80.3240.01015.84
7.2.70.3300.00616.04
7.2.60.3320.00716.08
7.2.50.3850.00716.11
7.2.40.3480.01216.03
7.2.30.2980.00815.84
7.2.20.3740.00815.88
7.2.10.2960.00515.86
7.2.00.3630.00716.07
7.1.330.0110.00415.58
7.1.320.0030.01015.86
7.1.310.0000.00915.82
7.1.300.0000.01315.40
7.1.290.0030.00915.79
7.1.280.0060.00915.79
7.1.270.0070.00715.81
7.1.260.0070.00715.54
7.1.250.0090.00615.75
7.1.220.0100.00813.45
7.1.210.0650.00313.83
7.1.200.6460.00013.67
7.1.190.6260.00713.75
7.1.180.8120.00613.98
7.1.170.6300.00913.77
7.1.160.7260.01313.72
7.1.150.7430.00714.04
7.1.140.5510.00613.73
7.1.130.6880.01313.75
7.1.120.5000.01013.76
7.1.110.2840.00313.99
7.1.100.4510.01014.00
7.1.90.0890.01613.83
7.1.80.1180.00713.89
7.1.70.2900.00313.68
7.1.60.1100.01031.98
7.1.51.4890.01031.36
7.1.41.4760.01031.71
7.1.31.6410.02031.69
7.1.20.5430.00631.91
7.1.10.0760.00413.68
7.1.00.0250.01013.71
5.6.380.0070.01013.94

preferences:
63.4 ms | 401 KiB | 5 Q