3v4l.org

run code in 300+ PHP versions simultaneously
<?php function implode_wrapper($glue , $pieces) { return (version_compare(PHP_VERSION, '7.3.99', '>')) ? implode($glue, $pieces) : implode($pieces, $glue); } function test_func($a, $b, &$cRef) { $args = func_get_args(); echo __FUNCTION__."(".implode(",",$args) . ")\n"; $cRef+=$a; } $testdata = array( array(1,1), array(2,2), array(3,3), array(4,4) ); if(defined("E_STRICT")) ini_set("error_reporting", ini_get("error_reporting") | E_STRICT); $refTest = 10; foreach($testdata as $test) { $args = array(); foreach($test as $t) $args[] = &$t; $args[] = &$refTest; call_user_func_array("test_func", $args); }

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.40.0120.00318.72
8.3.30.0070.00718.87
8.3.20.0080.00421.02
8.3.10.0080.00020.30
8.3.00.0040.00420.61
8.2.170.0090.00618.99
8.2.160.0080.01222.96
8.2.150.0060.00324.18
8.2.140.0000.00724.66
8.2.130.0040.00426.16
8.2.120.0000.00820.78
8.2.110.0030.00620.93
8.2.100.0110.00018.03
8.2.90.0030.00518.09
8.2.80.0040.00420.35
8.2.70.0080.00017.75
8.2.60.0030.00518.05
8.2.50.0090.00318.07
8.2.40.0030.00621.11
8.2.30.0080.00017.82
8.2.20.0050.00218.06
8.2.10.0000.00719.32
8.2.00.0030.00619.25
8.1.270.0080.00020.64
8.1.260.0030.00526.35
8.1.250.0020.00528.09
8.1.240.0030.00622.05
8.1.230.0080.00320.91
8.1.220.0040.00417.74
8.1.210.0050.00318.85
8.1.200.0060.00317.25
8.1.190.0000.00817.35
8.1.180.0040.00418.10
8.1.170.0000.00818.91
8.1.160.0000.00718.90
8.1.150.0070.00018.77
8.1.140.0030.00322.20
8.1.130.0030.00317.46
8.1.120.0000.00717.38
8.1.110.0000.00717.40
8.1.100.0040.00417.46
8.1.90.0050.00317.46
8.1.80.0050.00317.41
8.1.70.0040.00417.37
8.1.60.0000.00917.58
8.1.50.0050.00317.46
8.1.40.0040.00417.49
8.1.30.0000.00917.57
8.1.20.0000.00817.60
8.1.10.0030.00617.55
8.1.00.0000.00717.46
8.0.300.0000.00720.16
8.0.290.0040.00416.75
8.0.280.0080.00018.37
8.0.270.0000.00717.94
8.0.260.0030.00316.77
8.0.250.0000.00616.94
8.0.240.0000.00617.02
8.0.230.0030.00317.02
8.0.220.0040.00416.84
8.0.210.0060.00016.99
8.0.200.0060.00017.09
8.0.190.0000.00817.04
8.0.180.0000.00716.91
8.0.170.0060.00316.95
8.0.160.0060.00317.00
8.0.150.0040.00416.95
8.0.140.0080.00316.91
8.0.130.0000.00613.41
8.0.120.0000.00716.92
8.0.110.0040.00416.79
8.0.100.0040.00416.79
8.0.90.0060.00317.00
8.0.80.0040.01116.92
8.0.70.0000.00716.93
8.0.60.0000.00716.91
8.0.50.0000.00716.86
8.0.30.0060.01217.30
8.0.20.0150.01217.17
8.0.10.0040.00416.92
8.0.00.0070.01116.80
7.4.330.0000.00515.55
7.4.320.0040.00416.63
7.4.300.0030.00316.52
7.4.290.0040.00416.61
7.4.280.0080.00316.51
7.4.270.0030.00616.66
7.4.260.0000.00513.30
7.4.250.0030.00316.48
7.4.240.0060.00216.55
7.4.230.0000.00716.73
7.4.220.0030.00416.57
7.4.210.0090.00816.52
7.4.200.0000.00716.66
7.4.130.0090.00916.54
7.4.120.0090.00916.42
7.4.110.0170.00416.60
7.4.100.0100.00616.52
7.4.90.0130.00916.35
7.4.80.0060.00919.39
7.4.70.0100.00716.55
7.4.60.0090.01316.60
7.4.50.0120.00316.35
7.4.40.0090.00916.51
7.4.00.0080.01114.69
7.3.330.0000.00716.34
7.3.320.0060.00013.39
7.3.310.0040.00416.43
7.3.300.0000.00716.27
7.3.290.0030.00316.39
7.3.280.0090.00616.47
7.3.260.0070.01016.53
7.3.230.0090.00816.64
7.3.210.0120.00416.67
7.3.200.0060.01016.54
7.3.190.0150.00616.63
7.3.180.0100.01316.39
7.3.170.0060.01016.38
7.3.160.0060.00916.57
7.3.120.0080.01214.41
7.3.110.0000.02214.66
7.3.100.0130.01314.71
7.3.90.0180.00714.52
7.3.80.0140.00714.48
7.3.70.0100.01114.63
7.3.60.0100.01014.74
7.3.50.0100.00814.32
7.3.40.0100.01014.27
7.3.30.0090.00914.39
7.3.20.0070.01214.22
7.3.10.0120.00514.34
7.3.00.0150.01514.71
7.2.330.0100.01416.84
7.2.320.0030.01916.77
7.2.310.0110.00516.74
7.2.300.0150.00916.83
7.2.290.0100.01016.48
7.2.250.0090.01215.07
7.2.240.0150.00915.14
7.2.230.0080.01615.23
7.2.220.0230.00014.69
7.2.210.0170.00515.21
7.2.200.0120.00814.78
7.2.190.0180.00314.80
7.2.180.0040.01414.52
7.2.170.0170.01414.52
7.2.160.0150.00915.02
7.2.150.0140.01214.95
7.2.140.0140.00715.08
7.2.130.0140.01015.01
7.2.120.0190.00714.95
7.2.110.0110.01614.93
7.2.100.0160.01315.11
7.2.90.0120.00914.79
7.2.80.0140.01014.90
7.2.70.0120.01214.94
7.2.60.0120.01215.12
7.2.50.0150.00715.05
7.2.40.0220.00015.16
7.2.30.0130.01314.96
7.2.20.0220.01215.20
7.2.10.0100.01014.98
7.2.00.0120.00314.92
7.1.330.0150.00614.02
7.1.320.0100.01513.67
7.1.310.0160.00813.59
7.1.300.0400.00313.56
7.1.290.0170.00013.40
7.1.280.0090.00713.37
7.1.270.0130.00713.43
7.1.260.0100.01013.47
7.1.250.0140.00914.00
7.1.240.0120.01213.87
7.1.230.0120.01213.94
7.1.220.0080.01213.94
7.1.210.0160.00314.12
7.1.200.0180.00313.80
7.1.190.0160.00713.91
7.1.180.0140.00914.10
7.1.170.0160.00814.03
7.1.160.0130.01013.92
7.1.150.0160.00414.14
7.1.140.0140.00614.09
7.1.130.0170.00314.09
7.1.120.0120.00613.58
7.1.110.0080.01114.18
7.1.100.0190.00813.61
7.1.90.0100.01414.00
7.1.80.0130.01014.05
7.1.70.0110.01114.26
7.1.60.0160.00514.08
7.1.50.0160.00413.59
7.1.40.0170.00813.75
7.1.30.0280.00614.20
7.1.20.0170.00314.00
7.1.10.0160.00614.12
7.1.00.0150.00713.77
7.0.330.0190.00313.40
7.0.320.0130.00613.45
7.0.310.0160.00313.70
7.0.300.0560.00013.66
7.0.290.0250.00513.46
7.0.280.0130.00513.35
7.0.270.0160.00413.61
7.0.260.0140.00913.46
7.0.250.0090.01013.27
7.0.240.0150.00913.50
7.0.230.0140.00613.73
7.0.220.0100.01413.64
7.0.210.0180.00613.61
7.0.200.0190.00013.46
7.0.190.0170.00813.25
7.0.180.0080.01213.27
7.0.170.0140.00513.56
7.0.160.0160.00713.64
7.0.150.0110.01313.79
7.0.140.0170.00413.46
7.0.130.0090.01213.63
7.0.120.0170.00313.47
7.0.110.0130.00913.52
7.0.100.0130.01013.71
7.0.90.0150.00513.49
7.0.80.0190.00713.70
7.0.70.0200.00613.50
7.0.60.0130.00313.61
7.0.50.0130.00913.68
7.0.40.0190.00313.47
7.0.30.0110.00813.79
7.0.20.0100.01113.66
7.0.10.0140.00513.56
7.0.00.0150.00413.71
5.6.400.0170.00714.69
5.6.390.0170.00614.71
5.6.380.0040.01814.64
5.6.370.0160.00614.35
5.6.360.0170.00314.34
5.6.350.0210.00014.57
5.6.340.0090.01214.67
5.6.330.0140.00814.32
5.6.320.0170.00314.57
5.6.310.0140.01014.07
5.6.300.0150.00614.30
5.6.290.0190.00614.34
5.6.280.0210.00013.89
5.6.270.0190.00614.32
5.6.260.0090.01214.16
5.6.250.0110.01114.22
5.6.240.0140.00514.18
5.6.230.0100.01014.27
5.6.220.0120.01314.45
5.6.210.0100.01014.29
5.6.200.0170.00714.43
5.6.190.0150.00314.03
5.6.180.0180.00914.26
5.6.170.0130.00814.57
5.6.160.0120.01214.32
5.6.150.0060.01614.12
5.6.140.0260.00913.96
5.6.130.0100.01014.24
5.6.120.0140.00414.30
5.6.110.0100.01314.10
5.6.100.0170.00914.28
5.6.90.0140.01414.42
5.6.80.0120.01014.33
5.6.70.0120.00714.21
5.6.60.0170.01114.12
5.6.50.0170.01114.20
5.6.40.0200.00614.60
5.6.30.0100.01514.29
5.6.20.0100.01314.40
5.6.10.0160.00314.19
5.6.00.0130.00814.57
5.5.380.0190.00414.41
5.5.370.0130.01114.41
5.5.360.0150.01014.41
5.5.350.0100.01314.04
5.5.340.0150.01214.37
5.5.330.0170.00514.05
5.5.320.0150.00514.55
5.5.310.0160.00614.06
5.5.300.0140.00614.04
5.5.290.0140.00714.54
5.5.280.0100.01014.36
5.5.270.0140.01213.93
5.5.260.0150.00514.35
5.5.250.0170.00514.25
5.5.240.0190.00714.30
5.5.230.0150.00414.21
5.5.220.0070.01514.40
5.5.210.0180.00814.55
5.5.200.0130.01014.12
5.5.190.0100.01013.86
5.5.180.0120.01514.43
5.5.170.0190.00614.36
5.5.160.0140.01014.00
5.5.150.0100.01014.30
5.5.140.0150.00614.43
5.5.130.0110.01414.34
5.5.120.0130.01014.47
5.5.110.0130.00914.19
5.5.100.0180.00414.11
5.5.90.0210.00314.15
5.5.80.0170.00714.28
5.5.70.0150.00614.02
5.5.60.0110.01114.12
5.5.50.0140.01014.12
5.5.40.0190.00614.40
5.5.30.0120.00614.23
5.5.20.0170.01014.44
5.5.10.0140.00314.20
5.5.00.0170.00614.55
5.4.450.0110.00312.70
5.4.440.0120.01012.70
5.4.430.0090.01312.70
5.4.420.0030.01212.70
5.4.410.0190.00312.70
5.4.400.0120.00912.70
5.4.390.0140.00312.70
5.4.380.0080.01112.70
5.4.370.0100.01012.70
5.4.360.0150.00612.70
5.4.350.0090.00612.70
5.4.340.0120.00412.70
5.4.330.0180.00012.70
5.4.320.0110.00512.70
5.4.310.0140.00012.70
5.4.300.0130.00412.70
5.4.290.0130.00712.70
5.4.280.0190.00712.70
5.4.270.0180.00012.70
5.4.260.0090.00912.70
5.4.250.0130.00312.70
5.4.240.0120.00212.70
5.4.230.0110.00612.70
5.4.220.0120.00412.70
5.4.210.0190.00012.70
5.4.200.0090.00912.70
5.4.190.0090.00612.70
5.4.180.0180.00312.70
5.4.170.0080.00812.70
5.4.160.0070.00712.70
5.4.150.0080.00512.70
5.4.140.0030.01212.70
5.4.130.0120.00712.70
5.4.120.0130.00012.70
5.4.110.0180.00412.70
5.4.100.0100.00312.70
5.4.90.0070.00812.70
5.4.80.0060.00612.70
5.4.70.0100.00312.70
5.4.60.0100.00512.70
5.4.50.0190.00012.70
5.4.40.0090.00612.70
5.4.30.0070.00712.70
5.4.20.0090.00512.70
5.4.10.0100.00712.70
5.4.00.0110.00612.70
5.3.290.0040.01012.70
5.3.280.0060.00812.70
5.3.270.0160.00012.70
5.3.260.0100.00512.70
5.3.250.0070.00712.70
5.3.240.0110.00012.70
5.3.230.0070.00712.70
5.3.220.0070.01012.70
5.3.210.0080.00612.70
5.3.200.0070.00712.70
5.3.190.0110.00312.70
5.3.180.0100.00312.70
5.3.170.0100.00312.70
5.3.160.0120.00312.70
5.3.150.0090.00612.70
5.3.140.0100.00312.70
5.3.130.0100.00312.70
5.3.120.0110.00312.70
5.3.110.0070.00712.70
5.3.100.0040.01112.70
5.3.90.0080.00812.70
5.3.80.0120.00412.70
5.3.70.0080.00812.70
5.3.60.0050.01112.70
5.3.50.0150.00612.70
5.3.40.0130.00012.70
5.3.30.0120.00612.70
5.3.20.0110.00612.70
5.3.10.0060.00912.70
5.3.00.0070.00512.70
5.2.170.0090.00312.70
5.2.160.0150.00012.70
5.2.150.0050.00812.70
5.2.140.0040.00912.70
5.2.130.0080.00512.70
5.2.120.0120.00012.70
5.2.110.0090.00312.70
5.2.100.0090.00312.70
5.2.90.0080.00412.70
5.2.80.0090.00312.70
5.2.70.0090.00212.70
5.2.60.0060.00612.70
5.2.50.0060.00612.70
5.2.40.0120.00412.70
5.2.30.0110.00512.70
5.2.20.0150.00012.70
5.2.10.0050.00612.70
5.2.00.0080.00312.70
5.1.60.0050.00512.70
5.1.50.0000.00912.70
5.1.40.0070.00212.70
5.1.30.0050.00512.70
5.1.20.0070.00512.70
5.1.10.0050.00512.70
5.1.00.0040.00712.70
5.0.50.0100.00012.70
5.0.40.0060.00312.70
5.0.30.0040.00412.70
5.0.20.0050.00312.70
5.0.10.0000.01112.70
5.0.00.0040.00812.70
4.4.90.0030.00312.70
4.4.80.0070.00012.70
4.4.70.0000.00712.70
4.4.60.0060.00012.70
4.4.50.0000.00712.70
4.4.40.0050.00212.70
4.4.30.0030.00312.70
4.4.20.0040.00412.70
4.4.10.0070.00012.70
4.4.00.0030.00512.70
4.3.110.0060.00212.70
4.3.100.0070.00012.70
4.3.90.0040.00412.70
4.3.80.0040.00412.70
4.3.70.0070.00012.70
4.3.60.0070.00412.70
4.3.50.0000.00712.70
4.3.40.0040.00712.70
4.3.30.0030.00612.70
4.3.20.0060.00312.70
4.3.10.0030.00312.70
4.3.00.0050.00312.70

preferences:
56.15 ms | 400 KiB | 5 Q