3v4l.org

run code in 300+ PHP versions simultaneously
<?php $body = 'sdfsf dfg <h2 dgdfg>dxfdgdfg </h2> dfdsgdfg > sdf<>'; $body = preg_replace("/<h2.*?<\/h2>/","", $body); var_dump($body);

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.40.0080.01118.93
8.3.30.0070.00718.96
8.3.20.0000.00720.16
8.3.10.0050.00321.73
8.3.00.0040.00417.54
8.2.170.0090.00622.96
8.2.160.0140.00320.39
8.2.150.0070.00024.18
8.2.140.0050.00224.66
8.2.130.0040.00426.16
8.2.120.0070.00021.15
8.2.110.0120.00019.27
8.2.100.0060.00617.84
8.2.90.0060.00317.63
8.2.80.0030.00618.90
8.2.70.0030.00517.75
8.2.60.0040.00417.88
8.2.50.0040.00417.80
8.2.40.0060.00319.77
8.2.30.0080.00020.61
8.2.20.0040.00417.84
8.2.10.0000.00718.03
8.2.00.0040.00417.80
8.1.270.0080.00023.88
8.1.260.0050.00226.35
8.1.250.0040.00428.09
8.1.240.0030.00719.27
8.1.230.0040.00822.75
8.1.220.0050.00318.59
8.1.210.0000.00818.77
8.1.200.0030.00617.23
8.1.190.0040.00417.23
8.1.180.0060.00318.10
8.1.170.0040.00417.62
8.1.160.0000.00818.76
8.1.150.0000.00818.70
8.1.140.0050.00317.57
8.1.130.0000.00717.70
8.1.120.0040.00417.43
8.1.110.0000.00717.52
8.1.100.0000.00717.52
8.1.90.0000.00817.55
8.1.80.0030.00517.43
8.1.70.0000.00717.43
8.1.60.0040.00417.57
8.1.50.0050.00317.62
8.1.40.0030.00517.63
8.1.30.0080.00017.75
8.1.20.0040.00417.73
8.1.10.0000.00717.57
8.1.00.0000.00717.41
8.0.300.0000.00718.77
8.0.290.0070.00016.75
8.0.280.0040.00418.27
8.0.270.0030.00317.31
8.0.260.0000.00618.36
8.0.250.0070.00016.93
8.0.240.0000.00717.02
8.0.230.0070.00017.01
8.0.220.0030.00316.98
8.0.210.0050.00216.86
8.0.200.0030.00717.01
8.0.190.0000.00717.04
8.0.180.0040.00417.01
8.0.170.0070.00016.96
8.0.160.0000.00717.02
8.0.150.0030.00516.81
8.0.140.0040.00416.88
8.0.130.0000.00513.38
8.0.120.0000.00816.92
8.0.110.0040.00416.86
8.0.100.0050.00216.87
8.0.90.0040.00416.82
8.0.80.0080.00716.93
8.0.70.0000.00816.96
8.0.60.0000.00816.86
8.0.50.0040.00416.99
8.0.30.0100.00717.12
8.0.20.0190.00217.40
8.0.10.0050.00216.88
8.0.00.0080.00816.94
7.4.330.0030.00315.05
7.4.320.0060.00016.63
7.4.300.0000.00616.71
7.4.290.0000.00716.66
7.4.280.0050.00316.70
7.4.270.0070.00016.65
7.4.260.0070.00016.67
7.4.250.0040.00416.70
7.4.240.0000.00716.76
7.4.230.0030.00316.55
7.4.220.0070.01016.55
7.4.210.0060.00916.61
7.4.200.0030.00516.72
7.4.160.0060.00916.65
7.4.150.0130.00717.40
7.4.140.0070.01017.86
7.4.130.0120.00616.74
7.4.120.0080.01016.61
7.4.110.0090.01216.50
7.4.100.0240.00016.61
7.4.90.0060.01216.45
7.4.80.0040.01419.39
7.4.70.0110.00516.70
7.4.60.0030.01416.63
7.4.50.0040.00416.45
7.4.40.0070.01016.57
7.4.30.0130.00316.59
7.3.330.0000.00713.02
7.3.320.0050.00013.04
7.3.310.0060.00316.21
7.3.300.0030.00316.23
7.3.290.0070.00716.23
7.3.280.0090.00816.30
7.3.270.0070.01417.40
7.3.260.0130.00316.62
7.3.240.0100.00716.66
7.3.230.0100.00716.39
7.3.210.0110.00616.48
7.3.200.0140.00319.39
7.3.190.0060.01416.75
7.3.180.0130.01016.70
7.3.170.0090.00616.27
7.3.160.0040.01216.68
7.2.330.0120.01116.52
7.2.320.0100.00716.63
7.2.310.0140.00916.65
7.2.300.0100.00716.63
7.2.290.0110.01116.68
7.2.110.0230.00916.55
7.2.100.0170.01316.49
7.2.90.0240.00416.81
7.2.80.0260.00316.78
7.2.70.0260.00716.80
7.2.60.0150.00816.94
7.2.50.0170.01417.07
7.2.40.0220.01117.04
7.2.30.0240.00316.88
7.2.20.0200.00516.89
7.2.10.0200.00816.94
7.2.00.0050.01618.28
7.1.230.0150.01515.86
7.1.220.0280.00915.89
7.1.210.0140.01415.60
7.1.200.0070.01315.74
7.1.190.0140.01415.78
7.1.180.0230.00415.86
7.1.170.0100.01515.57
7.1.160.0160.01015.86
7.1.150.0190.00715.80
7.1.140.0110.01515.70
7.1.130.0120.01015.65
7.1.120.0120.01215.90
7.1.110.0180.00815.88
7.1.100.0050.01116.96
7.1.90.0120.01415.88
7.1.80.0110.01515.84
7.1.70.0100.00216.55
7.1.60.0110.01117.73
7.1.50.0110.01216.50
7.1.40.0150.01816.20
7.1.30.0160.01115.84
7.1.20.0170.01616.08
7.1.10.0200.00915.97
7.1.00.0110.04019.11
7.0.310.0150.01215.41
7.0.300.0190.00515.19
7.0.290.0170.00815.32
7.0.280.0190.00515.35
7.0.270.0100.01315.54
7.0.260.0110.01415.46
7.0.250.0170.00815.57
7.0.240.0140.01015.65
7.0.230.0180.00715.43
7.0.220.0180.00715.57
7.0.210.0160.00015.43
7.0.200.0040.00816.10
7.0.190.0210.00515.30
7.0.180.0170.01015.41
7.0.170.0170.00815.19
7.0.160.0220.00415.23
7.0.150.0140.01215.27
7.0.140.0140.03718.83
7.0.130.0260.00015.67
7.0.120.0200.00615.38
7.0.110.0170.01015.57
7.0.100.0100.01015.50
7.0.90.0150.01015.32
7.0.80.0200.00415.34
7.0.70.0180.00615.47
7.0.60.0080.05017.67
7.0.50.0180.02816.72
7.0.40.0220.03516.78
7.0.30.0280.02416.79
7.0.20.0360.03816.67
7.0.10.0230.04416.80
7.0.00.0270.03416.89
5.6.380.0130.00614.09
5.6.370.0140.01114.11
5.6.360.0110.00714.30
5.6.350.0170.00813.75
5.6.340.0190.00714.32
5.6.330.0220.00413.72
5.6.320.0130.01314.12
5.6.310.0140.00314.48
5.6.300.0100.01614.30
5.6.290.0170.00714.31
5.6.280.0170.03517.66
5.6.270.0160.00914.12
5.6.260.0160.01014.31
5.6.250.0150.01114.15
5.6.240.0190.00614.15
5.6.230.0150.01014.50
5.6.220.0130.01113.95
5.6.210.0090.02317.48
5.6.200.0160.04416.29
5.6.190.0190.02217.32
5.6.180.0300.03317.22
5.6.170.0370.02317.39
5.6.160.0230.03817.31
5.6.150.0350.03616.14
5.6.140.0250.02416.06
5.6.130.0290.04416.10
5.6.120.0170.02317.59
5.6.110.0130.02317.70
5.6.100.0070.04217.68
5.6.90.0140.04417.67
5.6.80.0150.03117.24
5.6.70.0150.00914.32
5.6.60.0190.00713.93
5.6.50.0160.00614.09
5.6.40.0220.00414.20
5.6.30.0230.00313.99
5.6.20.0070.01514.11
5.6.10.0160.00814.26
5.6.00.0220.00413.98
5.5.380.0140.00410.77
5.5.370.0100.00710.79
5.5.360.0090.00910.92
5.5.350.0110.04115.67
5.5.340.0120.03714.32
5.5.330.0130.02515.77
5.5.320.0270.04615.52
5.5.310.0270.04015.56
5.5.300.0100.02414.54
5.5.290.0120.03914.46
5.5.280.0050.02515.83
5.5.270.0070.02715.82
5.5.260.0180.03715.64
5.5.250.0070.04715.68
5.5.240.0150.04315.50
5.5.230.0000.01611.04
5.5.220.0130.00610.94
5.5.210.0090.00610.96
5.5.200.0150.00310.74
5.5.190.0150.00311.00
5.5.180.0110.00710.96
5.5.170.0190.00514.02
5.5.160.0160.00010.77
5.5.150.0150.00310.77
5.5.140.0100.00310.69
5.5.130.0090.00310.92
5.5.120.0120.00611.04
5.5.110.0090.00910.71
5.5.100.0040.01111.12
5.5.90.0090.00710.94
5.5.80.0120.00611.11
5.5.70.0070.00910.96
5.5.60.0070.00711.02
5.5.50.0080.00810.80
5.5.40.0130.00310.98
5.5.30.0080.00810.79
5.5.20.0110.00810.77
5.5.10.0060.00911.08
5.5.00.0140.00010.71
5.4.450.0210.02315.15
5.4.440.0270.03315.17
5.4.430.0200.02614.99
5.4.420.0190.04015.26
5.4.410.0170.03514.94
5.4.400.0210.02714.88
5.4.390.0200.03815.06
5.4.380.0240.03114.97
5.4.370.0210.02215.00
5.4.360.0210.03015.03
5.4.350.0150.02714.87
5.4.340.0230.03415.04
5.4.330.0110.00411.00
5.4.320.0230.03714.89
5.4.310.0180.02614.94
5.4.300.0180.04014.97
5.4.290.0170.02715.03
5.4.280.0180.03214.71
5.4.270.0200.02815.04
5.4.260.0190.02814.85
5.4.250.0210.01614.87
5.4.240.0180.02415.11
5.4.230.0180.02014.89
5.4.220.0190.02014.96
5.4.210.0160.02015.00
5.4.200.0150.02014.71
5.4.190.0140.02014.85
5.4.180.0180.01914.79
5.4.170.0150.02414.83
5.4.160.0180.02015.00
5.4.150.0200.02015.06
5.4.140.0150.02113.74
5.4.130.0140.02013.70
5.4.120.0130.02413.49
5.4.110.0140.02213.71
5.4.100.0140.01913.64
5.4.90.0160.01913.53
5.4.80.0140.02013.49
5.4.70.0180.02213.53
5.4.60.0180.01713.65
5.4.50.0130.02213.72
5.4.40.0130.02013.73
5.4.30.0140.02013.63
5.4.20.0180.01613.67
5.4.10.0130.02013.68
5.4.00.0190.02113.28
5.3.290.0200.04012.57
5.3.280.0180.01812.45
5.3.270.0160.02312.45
5.3.260.0180.01812.50
5.3.250.0170.01812.52
5.3.240.0160.01812.54
5.3.230.0120.02312.46
5.3.220.0110.02412.53
5.3.210.0160.02012.52
5.3.200.0130.02212.48
5.3.190.0140.02012.49
5.3.180.0110.02312.44
5.3.170.0170.01812.48
5.3.160.0200.02212.43
5.3.150.0120.02412.46
5.3.140.0120.02112.40
5.3.130.0160.02012.39
5.3.120.0150.02012.43
5.3.110.0180.01912.41
5.3.100.0110.02112.14
5.3.90.0200.03312.18
5.3.80.0170.02312.13
5.3.70.0160.03812.21
5.3.60.0220.02912.20
5.3.50.0160.03712.09
5.3.40.0170.02812.08
5.3.30.0200.02512.07
5.3.20.0170.02911.95
5.3.10.0260.01711.97
5.3.00.0220.03711.92
5.2.170.0180.03011.61
5.2.160.0120.02111.61
5.2.150.0200.03211.61
5.2.140.0210.02611.61
5.2.130.0140.01911.61
5.2.120.0140.02111.61
5.2.110.0200.02811.61
5.2.100.0130.01711.61
5.2.90.0200.01211.61
5.2.80.0140.01711.61
5.2.70.0150.03211.61
5.2.60.0100.03011.61
5.2.50.0130.02311.61
5.2.40.0160.01811.61
5.2.30.0100.01811.61
5.2.20.0170.02511.61
5.2.10.0130.01811.61
5.2.00.0140.01311.61
5.1.60.0100.01411.61
5.1.50.0160.01811.61
5.1.40.0130.02411.61
5.1.30.0130.02611.61
5.1.20.0160.02011.61
5.1.10.0120.01711.61
5.1.00.0100.01711.61
5.0.50.0070.02511.61
5.0.40.0070.01511.61
5.0.30.0110.02011.61
5.0.20.0080.02111.61
5.0.10.0150.01711.61
5.0.00.0110.02811.61
4.4.90.0030.02011.61
4.4.80.0050.01611.61
4.4.70.0090.01011.61
4.4.60.0100.01011.61
4.4.50.0050.01311.61
4.4.40.0080.02611.61
4.4.30.0110.01711.61
4.4.20.0050.02311.61
4.4.10.0110.01311.61
4.4.00.0050.01511.61
4.3.110.0090.01911.61
4.3.100.0050.01911.61
4.3.90.0090.01911.61
4.3.80.0070.02211.61
4.3.70.0060.01111.61
4.3.60.0050.02011.61
4.3.50.0100.01611.61
4.3.40.0050.02611.61
4.3.30.0040.01911.61
4.3.20.0050.01611.61
4.3.10.0040.01411.61
4.3.00.0050.01111.61

preferences:
51.69 ms | 400 KiB | 5 Q