3v4l.org

run code in 300+ PHP versions simultaneously
<?php $inputs = [ 'Windows' => "Dog\r\nCat\r\nMouse", 'Linux' => "Bicycle\nCar\nTrain\nAirplane", 'Mac' => "iPhone\riPod\rMacBook", 'Win + Linux' => "int main() {\n return 0;\r\n}\n", 'All mixed up' => "This is a Windows new line\r\n, followed by a Linux new line\n and finally an old Mac with a single carriage return\rat the end", ]; var_export( preg_replace('/\R/', '*', $inputs) );

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.5.10.0130.00916.79
8.5.00.0080.01321.86
8.4.160.0130.01123.80
8.4.150.0020.00014.05
8.4.140.0120.00917.69
8.4.130.0030.00618.77
8.4.120.0120.00824.21
8.4.110.0100.01018.86
8.4.100.0120.00918.87
8.4.90.0120.01020.63
8.4.80.0070.00320.40
8.4.70.0090.00718.89
8.4.60.0060.00218.96
8.4.50.0130.00718.59
8.4.40.0140.00317.95
8.4.30.0090.00918.80
8.4.20.0130.00619.84
8.4.10.0130.00319.79
8.3.280.0100.00918.64
8.3.270.0100.00916.47
8.3.260.0120.00816.75
8.3.250.0090.01019.06
8.3.240.0130.00616.71
8.3.230.0120.00716.50
8.3.220.0120.00718.86
8.3.210.0080.00618.55
8.3.200.0050.00416.61
8.3.190.0110.00517.14
8.3.180.0030.00718.68
8.3.170.0150.00320.50
8.3.160.0060.01216.86
8.3.150.0110.00716.98
8.3.140.0040.00418.64
8.3.130.0110.00718.71
8.3.120.0060.01019.02
8.3.110.0110.00416.61
8.3.100.0000.00816.72
8.3.90.0040.00426.77
8.3.80.0070.01430.84
8.3.70.0330.01130.84
8.3.60.0210.01130.84
8.3.50.0120.00930.84
8.3.40.0260.00630.84
8.3.30.0310.00030.84
8.3.20.0310.00930.84
8.3.10.0360.00030.84
8.3.00.0360.00030.84
8.2.290.0100.00820.63
8.2.280.0140.00818.77
8.2.270.0120.00617.00
8.2.260.0040.01118.20
8.2.250.0040.00418.63
8.2.240.0180.00317.18
8.2.230.0040.00420.94
8.2.220.0000.01837.54
8.2.210.0040.00426.77
8.2.200.0260.01030.84
8.2.190.0310.00730.84
8.2.180.0230.01530.84
8.2.170.0280.00830.84
8.2.160.0270.01330.84
8.2.150.0140.01030.84
8.2.140.0200.00330.84
8.2.130.0130.00730.84
8.2.120.0200.00030.84
8.2.110.0180.00330.84
8.2.100.0110.01530.84
8.2.90.0180.01430.84
8.2.80.0390.00830.84
8.2.70.0180.01130.84
8.2.60.0220.00430.84
8.2.50.0290.01030.84
8.2.40.0330.00730.84
8.2.30.0240.01230.84
8.2.20.0240.02030.84
8.2.10.0330.01330.84
8.2.00.0240.00830.84
8.1.330.0110.00921.85
8.1.320.0100.00616.41
8.1.310.0070.00716.91
8.1.300.0200.00019.70
8.1.290.0370.00630.84
8.1.280.0280.01430.84
8.1.270.0270.01330.84
8.1.260.0220.00430.84
8.1.250.0310.00630.84
8.1.240.0200.01430.84
8.1.230.0280.00330.84
8.1.220.0430.00430.84
8.1.210.0230.01130.84
8.1.200.0170.00030.84
8.1.190.0340.00330.84
8.1.180.0280.00930.84
8.1.170.0340.00330.84
8.1.160.0270.01130.84
8.1.150.0130.01730.84
8.1.140.0170.00730.84
8.1.130.0110.00630.84
8.1.120.0140.00330.84
8.1.110.0340.00630.84
8.1.100.0290.01130.84
8.1.90.0320.00830.84
8.1.80.0350.00930.84
8.1.70.0350.00330.84
8.1.60.0380.01030.84
8.1.50.0330.00030.84
8.1.40.0260.01530.84
8.1.30.0350.00730.84
8.1.20.0360.00630.84
8.1.10.0470.00730.84
8.1.00.0290.00630.84

preferences:
77.31 ms | 403 KiB | 5 Q