3v4l.org

run code in 300+ PHP versions simultaneously
<?php function by_ref(&$arg) { $arg = 42; } class ModuleHandler { public function invokeAll($hook, &$args) { by_ref($args[0]); } } $moduleHandler = new ModuleHandler(); $moduleHandler->invokeAll('example', array(23)); $array = array(25); $moduleHandler->invokeAll('example', $array); var_dump($array);

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.0120.00616.75
8.3.50.0130.00821.21
8.3.40.0040.01118.80
8.3.30.0090.00918.84
8.3.20.0000.00720.21
8.3.10.0000.00823.48
8.3.00.0040.00423.70
8.2.180.0140.00718.38
8.2.170.0140.00718.91
8.2.160.0040.01122.96
8.2.150.0080.00025.66
8.2.140.0040.00424.66
8.2.130.0020.00519.64
8.2.120.0070.00026.35
8.2.110.0080.00321.04
8.2.100.0080.00417.91
8.2.90.0060.00317.63
8.2.80.0030.00518.77
8.2.70.0050.00317.63
8.2.60.0050.00317.50
8.2.50.0050.00318.07
8.2.40.0030.00617.84
8.2.30.0000.00718.07
8.2.20.0070.00017.62
8.2.10.0040.00418.01
8.2.00.0040.00417.91
8.1.280.0090.01325.92
8.1.270.0060.00323.97
8.1.260.0040.00428.09
8.1.250.0040.00428.09
8.1.240.0090.00019.13
8.1.230.0060.00621.04
8.1.220.0040.00418.51
8.1.210.0000.00819.07
8.1.200.0040.00417.13
8.1.190.0030.00617.53
8.1.180.0030.00518.10
8.1.170.0030.00618.65
8.1.160.0040.00418.85
8.1.150.0040.00418.84
8.1.140.0080.00019.47
8.1.130.0040.00417.41
8.1.120.0040.00417.29
8.1.110.0080.00017.41
8.1.100.0040.00417.39
8.1.90.0020.00517.37
8.1.80.0000.00817.41
8.1.70.0030.00317.43
8.1.60.0000.00817.50
8.1.50.0050.00317.45
8.1.40.0050.00517.50
8.1.30.0000.00817.73
8.1.20.0050.00317.57
8.1.10.0050.00217.58
8.1.00.0000.00817.46
8.0.300.0000.00719.90
8.0.290.0050.00316.88
8.0.280.0000.00818.39
8.0.270.0080.00017.20
8.0.260.0030.00316.88
8.0.250.0030.00316.87
8.0.240.0030.00316.88
8.0.230.0000.00716.84
8.0.220.0000.00716.82
8.0.210.0000.00716.88
8.0.200.0000.01016.83
8.0.190.0040.00416.97
8.0.180.0040.00416.96
8.0.170.0050.00216.84
8.0.160.0070.00016.95
8.0.150.0030.00316.75
8.0.140.0080.00316.74
8.0.130.0000.00613.29
8.0.120.0040.00416.80
8.0.110.0000.00716.97
8.0.100.0040.00416.79
8.0.90.0040.00416.89
8.0.80.0120.00316.96
8.0.70.0080.00016.87
8.0.60.0040.00416.88
8.0.50.0040.00416.91
8.0.30.0110.00817.19
8.0.20.0080.01117.40
8.0.10.0040.00416.98
8.0.00.0120.01016.78
7.4.330.0050.00016.67
7.4.320.0030.00316.45
7.4.300.0000.00616.63
7.4.290.0040.00416.62
7.4.280.0000.00916.52
7.4.270.0070.00016.51
7.4.260.0100.00016.64
7.4.250.0000.00716.56
7.4.240.0010.00616.64
7.4.230.0000.00816.68
7.4.220.0110.00716.65
7.4.210.0060.01116.46
7.4.200.0070.00016.31
7.4.160.0120.00316.34
7.4.150.0120.00917.40
7.4.140.0080.01117.86
7.4.130.0050.01916.42
7.4.120.0110.00616.51
7.4.110.0140.00416.50
7.4.100.0140.00416.36
7.4.90.0100.00716.39
7.4.80.0070.01019.39
7.4.70.0080.00816.51
7.4.60.0150.00316.43
7.4.50.0030.00916.60
7.4.40.0120.00616.52
7.4.30.0070.01016.74
7.4.10.0110.00715.06
7.4.00.0050.01214.88
7.3.330.0030.00313.18
7.3.320.0050.00013.37
7.3.310.0030.00316.35
7.3.300.0000.00716.24
7.3.290.0070.00816.32
7.3.280.0100.00816.39
7.3.270.0050.01317.40
7.3.260.0060.01216.63
7.3.250.0120.00816.50
7.3.240.0150.00516.33
7.3.230.0060.01016.39
7.3.210.0090.00716.19
7.3.200.0130.01319.39
7.3.190.0140.00316.39
7.3.180.0040.01216.46
7.3.170.0090.01216.28
7.3.160.0030.01316.50
7.3.130.0040.00814.89
7.3.120.0100.01014.85
7.3.110.0110.00814.81
7.3.100.0040.01214.71
7.3.90.0080.00414.71
7.3.80.0060.00914.86
7.3.70.0030.00914.82
7.3.60.0000.01514.61
7.3.50.0040.01514.64
7.3.40.0060.00614.87
7.3.30.0000.01414.80
7.3.20.0070.01016.83
7.3.10.0060.00916.60
7.3.00.0050.00716.56
7.2.330.0100.00716.65
7.2.320.0100.00916.30
7.2.310.0060.01216.52
7.2.300.0040.01216.39
7.2.290.0140.00316.41
7.2.260.0030.01415.07
7.2.250.0060.01114.86
7.2.240.0030.01014.66
7.2.230.0040.01215.07
7.2.220.0070.01014.80
7.2.210.0080.00814.84
7.2.200.0030.01014.89
7.2.190.0000.01414.87
7.2.180.0030.00714.80
7.2.170.0070.00714.84
7.2.160.0070.01414.93
7.2.150.0040.00716.86
7.2.140.0060.00916.69
7.2.130.0060.00516.60
7.2.120.0080.00516.75
7.2.110.0070.00716.77
7.2.100.0060.00616.72
7.2.90.0070.00716.70
7.2.80.0070.00616.64
7.2.70.0070.00816.71
7.2.60.0050.00616.76
7.2.50.0070.00716.84
7.2.40.0070.00516.67
7.2.30.0060.00716.49
7.2.20.0060.00716.64
7.2.10.0030.01416.79
7.2.00.0100.00517.45
7.1.330.0060.00915.56
7.1.320.0060.00915.52
7.1.310.0030.01015.49
7.1.300.0100.00715.60
7.1.290.0030.00615.47
7.1.280.0040.01115.39
7.1.270.0120.00915.75
7.1.260.0030.01015.46
7.1.250.0080.00515.38
7.1.240.0000.01315.62
7.1.230.0070.00715.56
7.1.220.0070.00715.46
7.1.210.0060.00615.63
7.1.200.0040.00915.55
7.1.190.0060.00615.30
7.1.180.0110.00515.52
7.1.170.0050.00815.54
7.1.160.0020.01015.49
7.1.150.0080.00615.67
7.1.140.0070.00515.49
7.1.130.0030.00815.51
7.1.120.0050.00515.43
7.1.110.0020.00815.60
7.1.100.0090.00316.38
7.1.90.0050.01015.49
7.1.80.0050.00615.70
7.1.70.0040.01016.01
7.1.60.0030.01016.82
7.1.50.0100.00615.97
7.1.40.0050.00415.35
7.1.30.0040.00915.61
7.1.20.0030.01115.57
7.1.10.0020.01115.47
7.1.00.0080.02817.86
7.0.330.0030.00515.22
7.0.320.0070.00515.34
7.0.310.0060.00815.39
7.0.300.0040.01015.27
7.0.290.0080.00415.01
7.0.280.0100.00215.04
7.0.270.0050.00715.15
7.0.260.0070.00315.04
7.0.250.0050.00715.11
7.0.240.0040.00715.27
7.0.230.0070.00515.36
7.0.220.0060.00615.31
7.0.210.0040.01015.34
7.0.200.0050.00515.78
7.0.190.0050.00815.23
7.0.180.0030.00815.11
7.0.170.0040.00915.20
7.0.160.0090.00515.20
7.0.150.0060.00715.27
7.0.140.0060.00415.27
7.0.130.0060.00615.35
7.0.120.0040.00615.31
7.0.110.0090.00315.30
7.0.100.0050.00815.26
7.0.90.0050.00915.28
7.0.80.0040.00615.23
7.0.70.0090.00315.20
7.0.60.0050.03017.42
7.0.50.0050.03316.24
7.0.40.0080.03115.66
7.0.30.0140.01915.50
7.0.20.0150.03215.52
7.0.10.0050.03315.59
7.0.00.0030.02115.52
5.6.400.0000.01614.21
5.6.390.0000.01514.32
5.6.380.0060.00714.46
5.6.370.0020.01014.00
5.6.360.0020.00814.27
5.6.350.0060.00614.30
5.6.340.0020.00914.04
5.6.330.0070.00914.21
5.6.320.0070.00514.09
5.6.310.0090.00514.18
5.6.300.0080.00714.13
5.6.290.0050.00714.47
5.6.280.0070.01216.57
5.6.270.0030.01114.22
5.6.260.0100.00414.18
5.6.250.0050.01014.06
5.6.240.0110.00314.20
5.6.230.0090.00514.31
5.6.220.0030.01014.24
5.6.210.0070.02716.43
5.6.200.0060.02215.60
5.6.190.0050.02716.41
5.6.180.0250.02616.38
5.6.170.0100.02516.25
5.6.160.0040.02916.36
5.6.150.0040.02815.44
5.6.140.0030.03315.69
5.6.130.0080.03115.49
5.6.120.0050.03316.64
5.6.110.0060.03416.57
5.6.100.0090.02716.47
5.6.90.0080.03116.45
5.6.80.0070.01816.31
5.6.70.0050.00714.29
5.6.60.0050.00914.14
5.6.50.0060.00814.27
5.6.40.0020.01214.21
5.6.30.0040.00514.21
5.6.20.0060.00514.13
5.6.10.0080.00614.31
5.6.00.0040.00714.30
5.5.380.0080.00512.66
5.5.370.0030.00712.63
5.5.360.0070.00512.63
5.5.350.0070.03015.19
5.5.340.0040.03114.49
5.5.330.0100.02915.26
5.5.320.0110.03315.29
5.5.310.0110.03115.20
5.5.300.0040.02014.35
5.5.290.0060.01714.38
5.5.280.0080.03015.36
5.5.270.0030.03315.38
5.5.260.0070.01415.43
5.5.250.0070.03215.23
5.5.240.0130.02615.24
5.5.230.0070.00312.59
5.5.220.0040.00512.65
5.5.210.0050.00312.54
5.5.200.0110.00112.66
5.5.190.0080.00312.57
5.5.180.0030.00512.60
5.5.170.0100.00312.59
5.5.160.0040.01012.79
5.5.150.0030.00712.53
5.5.140.0060.00312.80
5.5.130.0030.00612.69
5.5.120.0070.00412.67
5.5.110.0030.00912.78
5.5.100.0080.00512.70
5.5.90.0070.00512.70
5.5.80.0020.00912.72
5.5.70.0030.00712.63
5.5.60.0080.00612.54
5.5.50.0070.00912.52
5.5.40.0030.01112.60
5.5.30.0030.00812.69
5.5.20.0090.00612.75
5.5.10.0060.00612.74
5.5.00.0020.00812.62

preferences:
52.59 ms | 401 KiB | 5 Q