3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test{ function __construct(){ $this->page="Test<br/>Test hého"; } function text(){ echo "\n START\n"; var_dump(mb_detect_encoding($this->page)); var_dump($this->page); echo "\n 1: "; var_dump(mb_detect_encoding($this->page)); var_dump(strlen($this->page)); $temp=htmlentities($this->page, ENT_IGNORE, 'UTF-8'); echo "\n 2: "; var_dump(mb_detect_encoding($temp)); var_dump(strlen($this->page)); echo "\n 3: "; var_dump(mb_detect_encoding($this->page)); var_dump($this->page); } } $a=new Test(); $a->text(); ?>

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.0110.00418.79
8.3.30.0110.00818.60
8.3.20.0050.00320.16
8.3.10.0040.00423.48
8.3.00.0070.00023.52
8.2.170.0030.01322.96
8.2.160.0070.00720.26
8.2.150.0000.00825.66
8.2.140.0080.00024.66
8.2.130.0080.00022.04
8.2.120.0000.00726.35
8.2.110.0090.00022.27
8.2.100.0030.00917.74
8.2.90.0040.00419.89
8.2.80.0040.00417.97
8.2.70.0040.00418.05
8.2.60.0050.00318.16
8.2.50.0000.00718.10
8.2.40.0050.00220.47
8.2.30.0030.00819.12
8.2.20.0070.00018.05
8.2.10.0030.00718.10
8.2.00.0070.00018.04
8.1.270.0050.00323.95
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0060.00322.14
8.1.230.0110.00018.95
8.1.220.0000.00817.74
8.1.210.0090.00018.77
8.1.200.0040.00417.23
8.1.190.0030.00517.35
8.1.180.0000.00918.10
8.1.170.0000.00818.60
8.1.160.0040.00418.72
8.1.150.0070.00020.70
8.1.140.0050.00217.74
8.1.130.0030.00320.68
8.1.120.0000.00717.51
8.1.110.0000.00717.47
8.1.100.0090.00017.46
8.1.90.0080.00017.37
8.1.80.0000.00817.50
8.1.70.0030.00317.35
8.1.60.0050.00317.64
8.1.50.0000.00817.57
8.1.40.0050.00517.53
8.1.30.0050.00317.64
8.1.20.0060.00617.71
8.1.10.0000.00717.63
8.1.00.0050.00217.54
8.0.300.0050.00319.77
8.0.290.0060.00316.88
8.0.280.0000.00718.51
8.0.270.0030.00317.31
8.0.260.0030.00316.79
8.0.250.0040.00416.90
8.0.240.0070.00016.84
8.0.230.0000.00716.84
8.0.220.0000.00716.95
8.0.210.0030.00316.84
8.0.200.0000.00716.82
8.0.190.0030.00616.98
8.0.180.0050.00316.88
8.0.170.0000.00716.73
8.0.160.0070.00016.92
8.0.150.0050.00516.95
8.0.140.0070.00416.89
8.0.130.0080.00013.27
8.0.120.0040.00416.87
8.0.110.0000.00716.71
8.0.100.0050.00216.88
8.0.90.0030.00516.91
8.0.80.0120.00316.95
8.0.70.0070.00016.75
8.0.60.0040.00416.87
8.0.50.0000.00716.68
8.0.30.0100.00617.07
8.0.20.0110.00917.40
8.0.10.0070.00016.94
8.0.00.0060.01216.63
7.4.330.0050.00016.77
7.4.320.0000.00616.45
7.4.300.0000.00616.52
7.4.290.0030.00316.50
7.4.280.0070.00016.57
7.4.270.0040.00416.59
7.4.260.0070.00016.55
7.4.250.0000.00816.53
7.4.240.0030.00516.57
7.4.230.0000.00716.46
7.4.220.0070.01016.51
7.4.210.0050.00916.55
7.4.200.0000.00716.54
7.4.160.0100.01016.48
7.4.150.0180.00417.40
7.4.140.0130.00817.86
7.4.130.0100.00716.64
7.4.120.0100.01116.55
7.4.110.0080.00816.49
7.4.100.0110.00816.58
7.4.90.0100.00716.48
7.4.80.0030.01519.39
7.4.70.0150.00316.72
7.4.60.0100.00716.54
7.4.50.0080.00316.52
7.4.40.0090.01316.40
7.4.30.0060.00916.57
7.4.00.0090.00315.22
7.3.330.0040.00413.34
7.3.320.0030.00313.35
7.3.310.0000.00716.35
7.3.300.0060.00016.28
7.3.290.0090.00616.37
7.3.280.0080.01016.36
7.3.270.0190.00717.40
7.3.260.0050.01416.40
7.3.250.0140.00816.35
7.3.240.0120.00716.56
7.3.230.0130.00616.57
7.3.210.0100.00716.58
7.3.200.0140.00716.41
7.3.190.0110.00416.36
7.3.180.0110.01116.48
7.3.170.0160.00016.37
7.3.160.0040.01716.17
7.2.330.0170.00016.67
7.2.320.0080.00916.48
7.2.310.0120.00716.73
7.2.300.0100.00716.90
7.2.290.0090.00816.57
7.2.60.0060.00916.86
7.1.200.0100.00315.99
7.1.110.0090.01217.88
7.1.100.0100.00618.24
7.1.90.0040.01017.93
7.1.80.0050.01418.07
7.1.70.0150.00417.16
7.1.60.0130.01635.12
7.1.50.0200.01035.07
7.1.40.0180.01534.46
7.1.30.0260.01334.61
7.1.20.0190.01934.39
7.1.10.0120.00316.57
7.1.00.0070.00716.69
7.0.250.0150.00617.68
7.0.240.0060.01118.01
7.0.230.0050.00917.72
7.0.220.0070.01017.73
7.0.210.0090.00916.77
7.0.200.0030.01116.70
7.0.190.0070.01016.90
7.0.180.0030.01116.23
7.0.170.0030.01516.49
7.0.160.0070.01016.39
7.0.150.0040.01116.27
7.0.140.0040.00816.32
7.0.130.0030.01216.41
7.0.120.0030.00916.57
7.0.110.0100.00316.42
7.0.100.0100.00316.45
7.0.90.0090.00316.25
7.0.80.0060.01316.28
7.0.70.0040.01016.22
7.0.60.0080.00716.23
7.0.50.0030.01316.43
7.0.40.0120.00316.41
7.0.30.0040.01016.49
7.0.20.0110.00716.42
7.0.10.0090.00916.34
7.0.00.0030.01616.36

preferences:
52.65 ms | 400 KiB | 5 Q