3v4l.org

run code in 300+ PHP versions simultaneously
<?php function append($str) { if(mb_strlen($str)>10) { str_replace($str, ' ...', -3); } } var_dump(append('very very long string'))

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)
5.4.270.0100.08018.79
5.4.260.0130.07019.00
5.4.250.0130.07318.90
5.4.240.0170.07318.90
5.4.230.0100.07318.76
5.4.220.0130.07319.00
5.4.210.0200.07318.99
5.4.200.0070.06318.84
5.4.190.0070.06318.97
5.4.180.0200.07318.74
5.4.170.0230.05318.94
5.4.160.0200.07018.63
5.4.150.0300.05718.75
5.4.140.0130.06316.43
5.4.130.0130.07316.36
5.4.120.0170.05316.55
5.4.110.0070.08316.43
5.4.100.0130.06016.56
5.4.90.0170.06316.41
5.4.80.0130.04716.63
5.4.70.0100.07716.39
5.4.60.0170.05316.35
5.4.50.0100.07716.52
5.4.40.0200.05716.38
5.4.30.0130.06316.36
5.4.20.0230.05316.59
5.4.10.0130.05716.53
5.4.00.0130.06715.85
5.3.280.0200.06314.59
5.3.270.0070.07314.68
5.3.260.0100.07714.79
5.3.250.0170.06314.69
5.3.240.0130.07014.61
5.3.230.0200.05014.60
5.3.220.0170.05714.55
5.3.210.0100.06714.55
5.3.200.0230.04714.55
5.3.190.0130.05014.54
5.3.180.0200.07314.56
5.3.170.0200.07014.46
5.3.160.0170.06014.56
5.3.150.0100.07714.56
5.3.140.0100.05314.56
5.3.130.0070.06314.55
5.3.120.0030.06714.57
5.3.110.0070.08014.65
5.3.100.0100.05014.05
5.3.90.0130.06714.10
5.3.80.0130.06714.00
5.3.70.0070.06314.10
5.3.60.0330.05314.18
5.3.50.0100.05714.03
5.3.40.0100.06713.93
5.3.30.0270.05714.08
5.3.20.0270.04713.76
5.3.10.0170.06313.73
5.3.00.0170.06013.71
5.2.170.0130.05311.12
5.2.160.0100.05011.14
5.2.150.0130.04711.20
5.2.140.0130.05311.12
5.2.130.0070.04011.17
5.2.120.0100.04711.17
5.2.110.0070.05711.32
5.2.100.0100.05711.31
5.2.90.0070.05011.06
5.2.80.0030.06311.16
5.2.70.0100.05311.07
5.2.60.0030.05011.05
5.2.50.0100.04010.97
5.2.40.0130.05310.99
5.2.30.0070.04710.94
5.2.20.0100.04710.86
5.2.10.0100.05310.82
5.2.00.0130.05310.71
5.1.60.0130.04010.09
5.1.50.0070.0479.96
5.1.40.0030.0379.94
5.1.30.0070.05710.41
5.1.20.0130.05010.18
5.1.10.0070.04010.13
5.1.00.0030.04010.14
5.0.50.0000.0408.51
5.0.40.0070.0338.56
5.0.30.0100.0538.28
5.0.20.0000.0378.18
5.0.10.0030.0378.26
5.0.00.0070.0538.35
4.4.90.0100.0177.45
4.4.80.0070.0207.45
4.4.70.0000.0307.45
4.4.60.0130.0207.45
4.4.50.0000.0337.45
4.4.40.0070.0407.45
4.4.30.0070.0277.45
4.4.20.0070.0277.45
4.4.10.0030.0237.45
4.4.00.0170.0337.45
4.3.110.0030.0237.45
4.3.100.0030.0307.45
4.3.90.0000.0237.45
4.3.80.0030.0437.45
4.3.70.0030.0307.45
4.3.60.0030.0277.45
4.3.50.0070.0177.45
4.3.40.0100.0377.45
4.3.30.0030.0307.45
4.3.20.0030.0237.45
4.3.10.0030.0307.45
4.3.00.0000.0236.88

preferences:
138.23 ms | 1394 KiB | 7 Q