3v4l.org

run code in 300+ PHP versions simultaneously
<?php $myarray = [ [ 'messageId' => '5ACE9D8841', 'sender' => 'john@doe.com' ], [ 'messageId' => '7EE67D8170', 'sender' => 'dan@doe.com' ], [ 'messageId' => '8095FD8836', 'sender' => 'cat@doe.com' ], [ 'messageId' => '7EE67D8170', 'dest' => 'mitch@doe.com', 'status' => 'sent', 'date' => '2021-02-01 11:06:55' ] ]; var_export( array_reduce( $myarray, function($result, $row) { static $ref; if (!isset($ref[$row['messageId']])) { $ref[$row['messageId']] = $row; $result[] = &$ref[$row['messageId']]; } else { $ref[$row['messageId']] += $row; } return $result; } ) );

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.80.0060.00318.31
8.3.70.0060.00916.50
8.3.60.0140.00418.55
8.3.50.0070.00716.60
8.3.40.0040.01123.84
8.3.30.0070.00718.82
8.3.20.0040.00424.18
8.3.10.0040.00424.66
8.3.00.0080.00026.16
8.2.200.0050.00518.14
8.2.190.0060.01216.72
8.2.180.0070.00718.13
8.2.170.0140.00318.93
8.2.160.0090.00922.96
8.2.150.0060.00325.66
8.2.140.0030.00624.66
8.2.130.0080.00026.16
8.2.120.0080.00026.16
8.2.110.0060.00320.92
8.2.100.0080.00317.84
8.2.90.0000.00817.97
8.2.80.0040.00418.22
8.2.70.0000.00817.75
8.2.60.0040.00417.63
8.2.50.0060.00317.55
8.2.40.0000.00919.29
8.2.30.0110.00417.65
8.2.20.0040.00817.78
8.2.10.0080.00817.78
8.2.00.0130.00317.70
8.1.290.0060.00318.88
8.1.280.0100.01025.92
8.1.270.0070.00024.66
8.1.260.0090.00026.35
8.1.250.0060.00328.09
8.1.240.0090.00023.89
8.1.230.0040.00822.82
8.1.220.0040.00417.74
8.1.210.0090.00318.77
8.1.200.0040.00417.36
8.1.190.0040.00717.23
8.1.180.0040.00418.10
8.1.170.0000.00817.68
8.1.160.0120.00417.46
8.1.150.0090.00617.47
8.1.140.0160.00017.39
8.1.130.0050.01017.57
8.1.120.0050.01017.58
8.1.110.0120.00417.59
8.1.100.0120.00417.41
8.1.90.0130.00317.58
8.1.80.0110.00717.51
8.1.70.0130.00317.45
8.1.60.0100.00317.59
8.1.50.0110.00417.50
8.1.40.0100.00517.70
8.1.30.0100.01017.62
8.1.20.0090.00917.69
8.1.10.0140.00417.61
8.1.00.0180.00017.46
8.0.300.0040.00420.03
8.0.290.0030.00516.88
8.0.280.0110.00416.77
8.0.270.0110.00416.85
8.0.260.0060.00416.91
8.0.250.0080.00416.87
8.0.240.0110.00416.78
8.0.230.0070.00716.90
8.0.220.0100.00516.91
8.0.210.0120.00316.92
8.0.200.0090.00616.88
8.0.190.0150.00016.84
8.0.180.0110.00416.83
8.0.170.0120.00316.88
8.0.160.0030.00916.95
8.0.150.0140.00016.78
8.0.140.0090.00616.83
8.0.130.0030.00916.82
8.0.120.0130.00316.80
8.0.110.0070.00716.73
8.0.100.0080.00416.87
8.0.90.0050.00516.89
8.0.80.0100.00016.90
8.0.70.0130.00016.89
8.0.60.0100.00416.89
8.0.50.0070.00716.94
8.0.30.0150.00016.89
8.0.20.0090.00416.82
8.0.10.0140.00016.98

preferences:
44.52 ms | 401 KiB | 5 Q