3v4l.org

run code in 500+ PHP versions simultaneously
<?php $text = '--ACT-- active --INA-- inactive --ACT-- active --INA-- inactive --INA-- inactive'; Echo preg_replace("/--INA-- (\w+)/" , '<div class="wp"><b>2</b>$1</div>',preg_replace("/--ACT-- (\w+)/" , '<div class="wp"><b>1</b>$1</div>',$text)) . "\n"; Echo preg_replace("/.*--INA-- (\w+).*/" , '<div class="wp"><b>2</b>$1</div>',preg_replace("/.*--ACT-- (\w+).*/" , '<div class="wp"><b>1</b>$1</div>',$text)) . "\n";

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.30.0100.00721.25
8.5.20.0120.00619.61
8.5.10.0100.00916.82
8.5.00.0130.00820.14
8.4.180.0090.01321.84
8.4.170.0130.01020.42
8.4.160.0120.01023.84
8.4.150.0050.00616.99
8.4.140.0140.00817.57
8.4.130.0070.00318.96
8.4.120.0080.00124.22
8.4.110.0040.00620.65
8.4.100.0140.00717.70
8.4.90.0110.00918.45
8.4.80.0100.00917.88
8.4.70.0040.00418.14
8.4.60.0150.00518.74
8.4.50.0130.00822.34
8.4.40.0040.00418.12
8.4.30.0160.00317.95
8.4.20.0130.00619.58
8.4.10.0030.00617.88
8.3.300.0080.01121.00
8.3.290.0100.01120.79
8.3.280.0130.01318.47
8.3.270.0110.00816.32
8.3.260.0130.00616.72
8.3.250.0110.00918.95
8.3.240.0050.00416.97
8.3.230.0130.00616.64
8.3.220.0040.00417.25
8.3.210.0050.00316.86
8.3.200.0040.00516.85
8.3.190.0130.01017.12
8.3.180.0090.00518.56
8.3.170.0130.00716.90
8.3.160.0130.00617.33
8.3.150.0110.00716.97
8.3.140.0070.01117.01
8.3.130.0130.00718.41
8.3.120.0030.00718.90
8.3.110.0000.00820.94
8.3.100.0040.00424.06
8.3.90.0040.00426.77
8.3.80.0030.00617.97
8.3.70.0130.00718.68
8.3.60.0070.01418.68
8.3.50.0100.00318.10
8.3.40.0040.01118.79
8.3.30.0060.00918.58
8.3.20.0080.00019.02
8.3.10.0030.00523.30
8.3.00.0040.00423.53
8.2.300.0130.01024.06
8.2.290.0070.00520.36
8.2.280.0090.01018.62
8.2.270.0190.00016.89
8.2.260.0070.00316.89
8.2.250.0110.00716.74
8.2.240.0080.00018.73
8.2.230.0110.00422.58
8.2.220.0000.00937.54
8.2.210.0040.00426.77
8.2.200.0030.00618.66
8.2.190.0090.00616.63
8.2.180.0070.01116.63
8.2.170.0110.00422.96
8.2.160.0060.00819.15
8.2.150.0060.00324.18
8.2.140.0000.00824.66
8.2.130.0050.00320.52
8.2.120.0080.00026.35
8.2.110.0060.00321.12
8.2.100.0060.00617.97
8.2.90.0000.00818.09
8.2.80.0040.00418.16
8.2.70.0050.00317.75
8.2.60.0050.00317.88
8.2.50.0040.00417.55
8.2.40.0000.00919.85
8.2.30.0080.00018.14
8.2.20.0080.00018.08
8.2.10.0040.00418.07
8.2.00.0000.00719.39
8.1.340.0100.01017.80
8.1.330.0120.00621.66
8.1.320.0050.00516.25
8.1.310.0030.00618.05
8.1.300.0050.00318.38
8.1.290.0070.00418.88
8.1.280.0060.01025.92
8.1.270.0040.00423.99
8.1.260.0120.00326.35
8.1.250.0080.00028.09
8.1.240.0060.00323.83
8.1.230.0030.00920.96
8.1.220.0040.00417.74
8.1.210.0040.00418.77
8.1.200.0050.00317.35
8.1.190.0030.00617.35
8.1.180.0000.00918.10
8.1.170.0000.00817.62
8.1.160.0000.00718.97
8.1.150.0040.00418.82
8.1.140.0040.00419.05
8.1.130.0040.00417.61
8.1.120.0050.00317.59
8.1.110.0030.00717.46
8.1.100.0000.00717.60
8.1.90.0040.00417.52
8.1.80.0040.00417.58
8.1.70.0040.00417.45
8.1.60.0000.00917.63
8.1.50.0000.00817.73
8.1.40.0030.00517.68
8.1.30.0030.00617.67
8.1.20.0040.00417.74
8.1.10.0040.00417.64
8.1.00.0060.00317.53
8.0.300.0040.00420.11
8.0.290.0080.00016.88
8.0.280.0050.00218.38
8.0.270.0000.00717.32
8.0.260.0030.00317.09
8.0.250.0000.00717.12
8.0.240.0000.00717.15
8.0.230.0070.00017.16
8.0.220.0030.00517.03
8.0.210.0040.00416.94
8.0.200.0030.00317.10
8.0.190.0070.00016.99
8.0.180.0000.00716.95
8.0.170.0040.00416.97
8.0.160.0030.00717.04
8.0.150.0080.00016.95
8.0.140.0050.00217.03
8.0.130.0030.00313.43
8.0.120.0040.00416.93
8.0.110.0040.00416.94
8.0.100.0040.00316.88
8.0.90.0040.00417.04
8.0.80.0070.01217.06
8.0.70.0080.00017.03
8.0.60.0000.00716.95
8.0.50.0030.00516.85
8.0.30.0080.00917.16
8.0.20.0110.00617.40
8.0.10.0070.00016.96
8.0.00.0110.00816.73
7.4.330.0050.00015.55
7.4.320.0030.00316.58
7.4.300.0000.00616.66
7.4.290.0000.00716.70
7.4.280.0020.00516.74
7.4.270.0060.00316.62
7.4.260.0040.00416.75
7.4.250.0030.00316.77
7.4.240.0000.00716.67
7.4.230.0030.00316.82
7.4.220.0030.00616.84
7.4.210.0060.00916.65
7.4.200.0030.00316.69
7.4.160.0110.00716.64
7.4.140.0110.00717.86
7.4.130.0100.01316.41
7.4.120.0080.01116.68
7.4.110.0140.00316.60
7.4.100.0030.01416.73
7.4.90.0090.01016.63
7.4.80.0130.00519.39
7.4.70.0140.00316.61
7.4.60.0060.00916.63
7.4.50.0090.00616.70
7.4.40.0130.00916.80
7.4.10.0090.00914.99
7.4.00.0060.01015.08
7.3.330.0000.00513.15
7.3.320.0070.00013.16
7.3.310.0030.00316.32
7.3.300.0040.00416.38
7.3.290.0000.00716.28
7.3.280.0030.01316.31
7.3.260.0120.00716.47
7.3.240.0150.00416.44
7.3.230.0030.01616.30
7.3.210.0210.02116.40
7.3.200.0030.01416.64
7.3.190.0030.01616.62
7.3.180.0000.01616.74
7.3.170.0140.00316.31
7.3.160.0110.00816.88
7.3.130.0060.01014.80
7.3.120.0110.00814.89
7.3.110.0100.00714.94
7.3.100.0040.01214.69
7.3.90.0030.01214.85
7.3.80.0040.00914.93
7.3.70.0080.00514.78
7.3.60.0070.00614.95
7.3.50.0060.00614.89
7.3.40.0030.00914.84
7.3.30.0000.01314.84
7.3.20.0080.00716.74
7.3.10.0080.00516.63
7.3.00.0060.00816.56
7.2.330.0120.00616.72
7.2.320.0120.00916.77
7.2.310.0100.01416.44
7.2.300.0030.01516.58
7.2.290.0130.01016.59
7.2.260.0100.01015.00
7.2.250.0100.00915.06
7.2.240.0070.01015.11
7.2.230.0080.00815.24
7.2.220.0030.01314.77
7.2.210.0020.01015.23
7.2.200.0050.01015.04
7.2.190.0080.00615.02
7.2.180.0110.00515.11
7.2.170.0020.01115.19
7.2.160.0060.00715.03
7.2.150.0060.00617.06
7.2.140.0050.01216.91
7.2.130.0050.00916.96
7.2.120.0060.00817.11
7.2.110.0070.00917.07
7.2.100.0090.00716.98
7.2.90.0030.01216.99
7.2.80.0130.00616.40
7.2.70.0140.01116.41
7.2.60.0130.01116.28
7.2.50.0190.00516.41
7.2.40.0080.00816.45
7.2.30.0120.01216.98
7.2.20.0090.00616.37
7.2.10.0040.01116.24
7.2.00.0090.00616.98
7.1.330.0020.01115.85
7.1.320.0030.01015.96
7.1.310.0100.00215.93
7.1.300.0080.00615.88
7.1.290.0080.00515.95
7.1.280.0050.00615.91
7.1.270.0030.00916.05
7.1.260.0090.00715.90
7.1.250.0080.00515.83
7.1.240.0050.00815.73
7.1.230.0050.00915.95
7.1.220.0080.00815.58
7.1.210.0050.01015.92
7.1.200.0050.00715.82
7.1.190.0130.00715.22
7.1.180.0150.00815.29
7.1.170.0150.00715.33
7.1.160.0080.00515.92
7.1.150.0180.00515.87
7.1.140.0080.01015.27
7.1.130.0080.00615.18
7.1.120.0130.00515.14
7.1.110.0100.01015.37
7.1.100.0040.01115.31
7.1.90.0040.00915.95
7.1.80.0060.00515.73
7.1.70.0080.00415.73
7.1.60.0130.00621.81
7.1.50.0120.00721.87
7.1.40.0110.00921.68
7.1.30.0110.01121.77
7.1.20.0130.00821.77
7.1.10.0070.00715.82
7.1.00.0050.00815.83
7.0.330.0050.00915.63
7.0.320.0020.01115.32
7.0.310.0020.01015.63
7.0.300.0070.00515.45
7.0.290.0060.00815.57
7.0.280.0080.00615.23
7.0.270.0050.00815.39
7.0.260.0060.00515.57
7.0.250.0040.00915.45
7.0.240.0100.00115.70
7.0.230.0050.00415.42
7.0.220.0010.00815.52
7.0.210.0050.01015.55
7.0.200.0030.01015.59
7.0.190.0070.00815.46
7.0.180.0000.01015.52
7.0.170.0010.01115.48
7.0.160.0060.00415.57
7.0.150.0050.01115.53
7.0.140.0030.01215.52
7.0.130.0050.00815.46
7.0.120.0060.00915.44
7.0.110.0020.01015.66
7.0.100.0060.00415.58
7.0.90.0040.01015.43
7.0.80.0040.01115.62
7.0.70.0030.01115.64
7.0.60.0050.01015.21
7.0.50.0080.00515.47
7.0.40.0050.00613.64
7.0.30.0050.01013.65
7.0.20.0050.00713.66
7.0.10.0040.01113.57
7.0.00.0060.00713.48
5.6.400.0060.00614.18
5.6.390.0110.00514.32
5.6.380.0060.00714.39
5.6.370.0050.00914.11
5.6.360.0060.00614.55
5.6.350.0090.00614.15
5.6.340.0060.01114.31
5.6.330.0060.00814.29
5.6.320.0020.01114.30
5.6.310.0020.01214.19
5.6.300.0070.00714.49
5.6.290.0030.01114.44
5.6.280.0050.01014.06
5.6.270.0060.00814.47
5.6.260.0020.01214.26
5.6.250.0050.01114.57
5.6.240.0040.00914.34
5.6.230.0030.01214.28
5.6.220.0130.00214.32
5.6.210.0030.01014.37
5.6.200.0040.01014.33
5.6.190.0120.00114.11
5.6.180.0000.01514.50
5.6.170.0050.01014.40
5.6.160.0060.01014.51
5.6.150.0040.00714.39
5.6.140.0040.01214.36
5.6.130.0040.00414.55
5.6.120.0030.01214.25
5.6.110.0080.00914.32
5.6.100.0070.00914.42
5.6.90.0070.00414.34
5.6.80.0050.00614.23
5.6.70.0060.00814.40
5.6.60.0020.00814.50
5.6.50.0070.00414.24
5.6.40.0060.00614.27
5.6.30.0100.00314.40
5.6.20.0070.00514.40
5.6.10.0050.01114.22
5.6.00.0120.00314.34

preferences:
49.21 ms | 1993 KiB | 5 Q