3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo memory_get_usage(), PHP_EOL; $s = str_repeat('c', 1000); echo memory_get_usage(), PHP_EOL; $s = (string) $s; echo memory_get_usage(), PHP_EOL;

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)
7.2.00.0030.00719.41
7.1.70.0000.00717.09
7.1.60.0110.01419.25
7.1.50.0100.01016.89
7.1.00.0100.02722.29
7.0.200.0000.00816.72
7.0.140.0070.07022.21
7.0.120.0000.07021.96
7.0.60.0230.08021.81
7.0.50.0070.03717.89
7.0.40.0100.04019.96
7.0.30.0330.07020.14
7.0.20.0400.06720.40
7.0.10.0000.04720.09
7.0.00.0030.08320.16
5.6.280.0030.07321.14
5.6.210.0170.06720.49
5.6.200.0070.07318.13
5.6.190.0200.07320.61
5.6.180.0200.06720.61
5.6.170.0400.06320.47
5.6.160.0000.05720.70
5.6.150.0070.07718.08
5.6.140.0070.05018.15
5.6.130.0130.08018.18
5.6.120.0100.07321.01
5.6.110.0130.04021.11
5.6.100.0100.06321.12
5.6.90.0170.05020.97
5.6.80.0070.06320.50
5.5.350.0230.06720.33
5.5.340.0070.04017.98
5.5.330.0070.07020.13
5.5.320.0230.04320.13
5.5.310.0370.07020.50
5.5.300.0070.08017.96
5.5.290.0170.03718.02
5.5.280.0130.06320.86
5.5.270.0130.06320.78
5.5.260.0100.04020.87
5.5.250.0100.07720.77
5.5.240.0330.06320.25
5.4.450.3900.04019.48
5.4.440.4130.03319.18
5.4.430.4070.03019.36
5.4.420.3500.03019.18
5.4.410.3930.03719.19
5.4.400.3630.04318.86
5.4.390.3370.04319.15
5.4.380.3800.02319.13
5.4.370.3630.04019.08
5.4.360.4030.03319.00
5.4.350.3930.03319.16
5.4.340.3870.03719.06
5.4.320.3630.03719.08
5.4.310.3800.03719.12
5.4.300.3970.03719.14
5.4.290.4300.04019.06
5.4.280.4500.03019.13
5.4.270.4470.04018.85
5.4.260.4070.03718.86
5.4.250.4330.04318.96
5.4.240.3770.03718.99
5.4.230.3970.03719.05
5.4.220.2030.04018.85
5.4.210.1570.03719.05
5.4.200.2630.03318.98
5.4.190.2430.03319.15
5.4.180.1870.04319.18
5.4.170.1200.02718.87
5.4.160.2500.03018.94
5.4.150.1400.03319.13
5.4.140.0700.03716.38
5.4.130.1400.02716.25
5.4.120.0470.03316.22
5.4.110.1770.04016.46
5.4.100.3370.04016.13
5.4.90.4000.03316.16
5.4.80.3900.03316.24
5.4.70.3700.03316.32
5.4.60.4100.03016.29
5.4.50.3430.03316.36
5.4.40.3970.03316.30
5.4.30.3830.03016.35
5.4.20.3970.03716.54
5.4.10.3770.03016.30
5.4.00.3970.03715.79
5.3.290.3670.04314.60
5.3.280.1700.05314.52
5.3.270.0830.04714.52
5.3.260.0870.04014.54
5.3.250.1170.04014.54
5.3.240.0970.03714.54
5.3.230.0330.03714.60
5.3.220.0500.03714.45
5.3.210.0730.04014.39
5.3.200.1700.03714.50
5.3.190.4070.03314.55
5.3.180.3930.03314.50
5.3.170.3170.04014.54
5.3.160.3800.03714.48
5.3.150.4000.03714.51
5.3.140.3970.03714.48
5.3.130.4100.03714.48
5.3.120.4000.04314.48
5.3.110.3800.03014.47
5.3.100.3830.04013.96
5.3.90.3270.04313.99
5.3.80.0130.04714.03
5.3.70.0170.03713.94
5.3.60.0000.06713.98
5.3.50.2030.06313.76
5.3.40.3670.03713.76
5.3.30.3870.03713.85
5.3.20.3900.03013.65
5.3.10.3870.03713.45
5.3.00.3870.03713.57
5.2.170.3330.03310.96
5.2.160.3100.03011.11
5.2.150.3270.03011.14
5.2.140.3070.03011.00
5.2.130.3200.02711.04
5.2.120.3400.02311.09
5.2.110.3100.02710.98
5.2.100.2900.03311.12
5.2.90.3570.04011.04
5.2.80.3200.02711.25
5.2.70.3300.03310.95
5.2.60.2970.03010.89
5.2.50.2930.02311.02
5.2.40.2570.02310.89
5.2.30.2470.03010.90
5.2.20.0700.02710.94
5.2.10.0030.04710.86
5.2.00.0070.05710.60
5.1.60.0030.0539.89
5.1.50.2500.02310.05
5.1.40.2470.0279.88
5.1.30.2700.03310.34
5.1.20.2630.02710.30
5.1.10.2570.0279.97
5.1.00.2500.03010.04
5.0.50.1270.0238.53
5.0.40.1300.0178.42
5.0.30.1400.0308.24
5.0.20.1430.0208.11
5.0.10.1500.0208.07
5.0.00.1330.0338.10
4.4.90.1500.0135.86
4.4.80.1230.0175.86
4.4.70.0030.0205.88
4.4.60.0000.0375.86
4.4.50.0000.0335.86
4.4.40.1470.0275.86
4.4.30.1230.0175.86
4.4.20.1430.0205.86
4.4.10.0830.0175.88
4.4.00.1200.0275.86
4.3.110.1470.0205.86
4.3.100.1270.0175.86
4.3.90.1530.0135.86
4.3.80.1270.0235.86
4.3.70.1200.0135.86
4.3.60.1530.0135.86
4.3.50.1300.0175.86
4.3.40.1200.0275.86
4.3.30.0730.0205.86
4.3.20.0630.0175.86
4.3.10.0600.0175.86
4.3.00.0600.0175.86

preferences:
37.19 ms | 401 KiB | 5 Q