3v4l.org

run code in 300+ PHP versions simultaneously
<?php function OhYea2GunNukesSpamUsingDruszAvatarAndLotsOfHardcodedCrapYOLOSWAGHeyKarlSupMan($input) { $blacklist = array('a-xxx-site-with-spam.com','visual.merriam-webster.com','example.com'); $output=$input; foreach ($blacklist as $a_blacklisted) { $output = preg_replace('/<img(.*?)src=.http(.*?)'.str_replace('.','\.',$a_blacklisted).'(.*?)>/', '<img src="http://standardsurvival.com/faces/64/drusz.png">', $output); } return $output; } echo OhYea2GunNukesSpamUsingDruszAvatarAndLotsOfHardcodedCrapYOLOSWAGHeyKarlSupMan('a spammy one: <img src="http://www.a-xxx-site-with-spam.com/test1.jpg">'); echo "\n"; echo OhYea2GunNukesSpamUsingDruszAvatarAndLotsOfHardcodedCrapYOLOSWAGHeyKarlSupMan('a legit one: <img src="http://www.google.com/test1.jpg">'); echo OhYea2GunNukesSpamUsingDruszAvatarAndLotsOfHardcodedCrapYOLOSWAGHeyKarlSupMan('another legit: <img src="http://www.domain.com/test1.jpg">'); echo OhYea2GunNukesSpamUsingDruszAvatarAndLotsOfHardcodedCrapYOLOSWAGHeyKarlSupMan('a spammy: <img src="http://visual.merriam-webster.com/test1.jpg">'); echo OhYea2GunNukesSpamUsingDruszAvatarAndLotsOfHardcodedCrapYOLOSWAGHeyKarlSupMan('a legit: <img src="http://www.example.com/test1.jpg">');

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.60.0090.00618.55
8.3.50.0120.00822.23
8.3.40.0040.01518.79
8.3.30.0100.01319.10
8.3.20.0030.00620.34
8.3.10.0120.00622.09
8.3.00.0040.00422.45
8.2.180.0100.01017.00
8.2.170.0160.00322.96
8.2.160.0110.00420.96
8.2.150.0060.00324.18
8.2.140.0030.00624.66
8.2.130.0070.00026.16
8.2.120.0060.00617.75
8.2.110.0060.00322.43
8.2.100.0120.00018.03
8.2.90.0030.00519.05
8.2.80.0040.00418.03
8.2.70.0030.00617.73
8.2.60.0050.00517.91
8.2.50.0040.00418.07
8.2.40.0040.00418.16
8.2.30.0050.00218.21
8.2.20.0040.00417.82
8.2.10.0000.00717.79
8.2.00.0000.00717.96
8.1.280.0100.00725.92
8.1.270.0050.00322.14
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0030.00623.91
8.1.230.0070.00318.88
8.1.220.0040.00417.77
8.1.210.0000.00818.77
8.1.200.0000.00917.35
8.1.190.0050.00317.41
8.1.180.0050.00318.48
8.1.170.0040.00418.76
8.1.160.0040.00422.04
8.1.150.0050.00218.71
8.1.140.0000.00717.57
8.1.130.0070.00017.82
8.1.120.0000.00717.53
8.1.110.0030.00517.67
8.1.100.0050.00317.64
8.1.90.0040.00417.65
8.1.80.0040.00417.63
8.1.70.0000.00717.57
8.1.60.0000.00917.70
8.1.50.0000.00817.56
8.1.40.0030.00617.58
8.1.30.0060.00317.79
8.1.20.0000.00817.86
8.1.10.0040.00417.63
8.1.00.0000.00817.53
8.0.300.0040.00418.77
8.0.290.0070.00017.17
8.0.280.0000.00718.47
8.0.270.0000.00717.29
8.0.260.0000.00716.92
8.0.250.0030.00617.09
8.0.240.0000.00716.99
8.0.230.0030.00317.03
8.0.220.0000.00717.04
8.0.210.0030.00317.04
8.0.200.0100.00017.08
8.0.190.0040.00416.97
8.0.180.0040.00417.08
8.0.170.0080.00017.08
8.0.160.0040.00417.01
8.0.150.0000.00717.03
8.0.140.0000.00816.94
8.0.130.0000.00613.39
8.0.120.0030.00617.02
8.0.110.0040.00417.04
8.0.100.0000.00716.94
8.0.90.0040.00416.90
8.0.80.0060.00917.09
8.0.70.0000.00817.05
8.0.60.0000.00716.92
8.0.50.0050.00317.01
8.0.30.0170.00617.39
8.0.20.0080.01217.40
8.0.10.0070.00017.13
8.0.00.0100.01116.89
7.4.330.0030.00315.18
7.4.320.0030.00316.82
7.4.300.0030.00316.84
7.4.290.0040.00416.83
7.4.280.0030.00316.71
7.4.270.0030.00316.64
7.4.260.0080.00316.71
7.4.250.0000.00716.80
7.4.240.0040.00416.75
7.4.230.0080.00016.64
7.4.220.0130.00416.74
7.4.210.0080.00916.80
7.4.200.0000.00716.71
7.4.190.0030.00316.97
7.4.160.0080.00816.84
7.4.150.0070.01117.40
7.4.140.0110.01117.86
7.4.130.0100.00716.67
7.4.120.0130.00716.72
7.4.110.0090.00916.75
7.4.100.0140.00716.80
7.4.90.0070.01116.60
7.4.80.0120.00619.39
7.4.70.0120.00616.84
7.4.60.0130.00316.57
7.4.50.0000.00816.60
7.4.40.0030.01422.77
7.4.30.0100.00716.83
7.4.00.0090.00715.07
7.3.330.0040.00413.48
7.3.320.0050.00013.54
7.3.310.0030.00316.53
7.3.300.0030.00316.41
7.3.290.0080.01116.54
7.3.280.0070.01116.56
7.3.270.0140.00317.40
7.3.260.0140.00916.66
7.3.250.0080.01216.84
7.3.240.0100.01016.89
7.3.230.0120.00916.58
7.3.210.0070.01016.69
7.3.200.0140.00719.39
7.3.190.0100.00716.76
7.3.180.0060.00916.47
7.3.170.0080.00916.84
7.3.160.0050.01116.69
7.3.120.0110.00515.16
7.3.110.0080.01115.10
7.3.100.0030.01215.17
7.3.90.0030.01014.99
7.3.80.0040.00714.81
7.3.70.0040.00914.87
7.3.60.0020.01415.01
7.3.50.0090.00515.09
7.3.40.0060.00814.95
7.3.30.0070.00614.88
7.3.20.0060.00616.73
7.3.10.0180.00716.88
7.3.00.0090.00816.80
7.2.330.0150.00616.87
7.2.320.0150.00916.93
7.2.310.0160.00616.92
7.2.300.0120.01116.74
7.2.290.0040.01316.86
7.2.250.0110.00915.17
7.2.240.0090.01215.25
7.2.230.0090.00714.98
7.2.220.0050.00915.17
7.2.210.0050.01115.30
7.2.200.0070.00615.17
7.2.190.0050.01015.29
7.2.180.0090.00715.27
7.2.170.0030.00915.17
7.2.130.0150.01117.01
7.2.120.0190.00816.98
7.2.110.0210.01017.16
7.2.100.0190.00616.88
7.2.90.0250.00016.56
7.2.80.0140.01416.94
7.2.70.0350.00316.90
7.2.60.0050.01416.91
7.2.50.0030.01416.77
7.2.40.0090.00616.83
7.2.30.0110.00316.90
7.2.20.0060.01017.13
7.2.10.0050.01216.90
7.2.00.0060.00818.41
7.1.330.0060.00815.94
7.1.320.0040.00715.97
7.1.310.0080.00716.09
7.1.300.0030.00915.76
7.1.290.0030.00716.03
7.1.280.0050.00515.81
7.1.270.0100.00315.97
7.1.260.0060.00615.79
7.1.250.0310.00716.03
7.1.100.0040.00718.35
7.1.70.0060.00317.34
7.1.60.0120.01219.82
7.1.50.0030.01317.07
7.1.00.0070.08722.47
7.0.200.0070.00716.99
7.0.140.0070.06721.99
7.0.60.0100.07319.95
7.0.50.0130.06017.85
7.0.40.0070.08320.16
7.0.30.0270.04320.10
7.0.20.0270.06320.10
7.0.10.0200.07720.18
7.0.00.0100.06020.21
5.6.280.0030.07320.89
5.6.210.0130.07020.52
5.6.200.0030.09018.27
5.6.190.0000.05020.61
5.6.180.3230.03720.61
5.6.170.0370.07320.39
5.6.160.0130.06320.48
5.6.150.0030.04018.12
5.6.140.0100.07018.16
5.6.130.0000.05318.21
5.6.120.0070.07720.90
5.6.110.0170.06321.00
5.6.100.0100.05021.12
5.6.90.0030.09021.04
5.6.80.0030.07720.38
5.6.70.0370.06020.38
5.5.350.0100.07720.45
5.5.340.0030.04318.08
5.5.330.0100.08320.39
5.5.320.0270.07720.36
5.5.310.0500.03720.19
5.5.300.0070.07017.92
5.5.290.0130.07717.95
5.5.280.0130.05020.78
5.5.270.0000.09720.87
5.5.260.0130.08020.68
5.5.250.0100.03320.69
5.5.240.0100.05720.27
5.4.450.0470.06019.48
5.4.440.0670.05719.48
5.4.430.0430.06719.32
5.4.420.0670.07019.38
5.4.410.0570.05019.32
5.4.400.0770.00018.84
5.4.390.0870.00018.89
5.4.380.0230.05718.79
5.4.370.0330.05018.70
5.4.360.0330.04718.57
5.4.350.0200.05718.57
5.4.340.0530.04018.61
5.4.320.0090.05112.51
5.4.310.0070.04012.50
5.4.300.0070.03512.51
5.4.290.0050.03912.50
5.4.280.0050.03612.40
5.4.270.0030.03912.40
5.4.260.0100.04719.04
5.4.250.0070.05719.04
5.4.240.0100.05019.11
5.4.230.0000.06018.95
5.4.220.0100.07319.00
5.4.210.0130.04318.80
5.4.200.0100.06018.90
5.4.190.0070.06018.79
5.4.180.0170.04018.98
5.4.170.0030.05718.93
5.4.160.0030.06018.98
5.4.150.0070.05718.82
5.4.140.0100.04716.63
5.4.130.0100.04316.36
5.4.120.0170.04716.39
5.4.110.0030.06016.54
5.4.100.0070.05716.57
5.4.90.0100.06316.60
5.4.80.0030.05016.57
5.4.70.0000.06316.45
5.4.60.0130.04316.56
5.4.50.0070.04716.36
5.4.40.0100.05016.51
5.4.30.0070.06016.39
5.4.20.0070.06316.38
5.4.10.0100.06716.53
5.4.00.0100.05715.99
5.3.290.0040.04312.80
5.3.280.0070.05014.59
5.3.270.0130.04314.59
5.3.260.0130.04714.68
5.3.250.0170.04314.44
5.3.240.0170.07014.68
5.3.230.0030.05314.68
5.3.220.0200.04314.65
5.3.210.0100.06314.65
5.3.200.0100.04714.56
5.3.190.0030.07714.65
5.3.180.0070.05014.73
5.3.170.0030.05014.65
5.3.160.0100.04714.54
5.3.150.0170.04714.79
5.3.140.0030.05314.54
5.3.130.0130.04714.54
5.3.120.0030.05714.63
5.3.110.0030.05714.63
5.3.100.0100.05014.25
5.3.90.0100.06714.00
5.3.80.0170.04713.92
5.3.70.0070.05314.18
5.3.60.0030.05313.97
5.3.50.0100.05314.11
5.3.40.0130.04313.95
5.3.30.0130.04313.98
5.3.20.0100.04313.77
5.3.10.0070.04713.61
5.3.00.0170.05313.71
5.2.170.0100.04711.31
5.2.160.0070.03711.13
5.2.150.0000.04710.98
5.2.140.0100.03711.06
5.2.130.0100.03311.27
5.2.120.0070.03711.01
5.2.110.0000.05011.07
5.2.100.0030.04011.18
5.2.90.0070.04011.11
5.2.80.0030.04311.07
5.2.70.0130.04011.31
5.2.60.0100.03711.13
5.2.50.0130.04011.11
5.2.40.0130.03311.07
5.2.30.0000.06310.95
5.2.20.0130.03711.14
5.2.10.0170.03010.69
5.2.00.0030.04010.80
5.1.60.0070.03310.11
5.1.50.0100.0339.96
5.1.40.0070.03010.13
5.1.30.0200.02310.31
5.1.20.0070.03310.44
5.1.10.0070.03310.27
5.1.00.0030.05310.14
5.0.50.0070.0278.71
5.0.40.0100.0338.25
5.0.30.0030.0438.38
5.0.20.0100.0208.20
5.0.10.0000.0408.01
5.0.00.0070.0538.13
4.4.90.0000.0306.90
4.4.80.0000.0276.90
4.4.70.0030.0236.90
4.4.60.0030.0206.90
4.4.50.0000.0306.90
4.4.40.0100.0236.90
4.4.30.0000.0236.90
4.4.20.0100.0236.90
4.4.10.0030.0236.90
4.4.00.0030.0406.90
4.3.110.0000.0336.90
4.3.100.0000.0236.90
4.3.90.0030.0236.90
4.3.80.0030.0336.90
4.3.70.0070.0176.90
4.3.60.0070.0136.90
4.3.50.0030.0206.90
4.3.40.0070.0306.90
4.3.30.0000.0236.90
4.3.20.0000.0236.90
4.3.10.0000.0236.90
4.3.00.0130.0239.30

preferences:
43.66 ms | 401 KiB | 5 Q