3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'Foo'; $hex16 = substr( hash( 'sha256', $string ), 0, 16 ); $hexhi = substr( $hex16, 0, 8 ); $hexlo = substr( $hex16, 8, 8 ); $int = hexdec( $hexlo ) | ( hexdec( $hexhi ) << 32 ); var_dump($int);

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.130.0000.00818.36
8.3.120.0030.00620.82
8.3.110.0040.00420.94
8.3.100.0070.00324.06
8.3.90.0000.00726.77
8.3.80.0080.00319.36
8.3.70.0000.01418.30
8.3.60.0060.01216.50
8.3.50.0110.00716.44
8.3.40.0090.00618.59
8.3.30.0140.00018.63
8.3.20.0040.00420.31
8.3.10.0000.00820.92
8.3.00.0040.00420.29
8.2.250.0090.00618.40
8.2.240.0060.00318.69
8.2.230.0040.00422.58
8.2.220.0030.00737.54
8.2.210.0040.00426.77
8.2.200.0040.00418.88
8.2.190.0090.00616.75
8.2.180.0150.00616.63
8.2.170.0210.00022.96
8.2.160.0140.00720.57
8.2.150.0000.00924.18
8.2.140.0050.00924.66
8.2.130.0040.00426.16
8.2.120.0000.00821.00
8.2.110.0100.00021.00
8.2.100.0000.01217.72
8.2.90.0030.00518.22
8.2.80.0040.00418.03
8.2.70.0080.00317.38
8.2.60.0080.00017.63
8.2.50.0050.00317.63
8.2.40.0000.00820.45
8.2.30.0030.00719.30
8.2.20.0040.00417.93
8.2.10.0040.00418.13
8.2.00.0000.00718.16
8.1.300.0030.01317.75
8.1.290.0060.00330.84
8.1.280.0160.00325.92
8.1.270.0000.00722.20
8.1.260.0000.00826.35
8.1.250.0110.00328.09
8.1.240.0060.00922.48
8.1.230.0110.00420.88
8.1.220.0040.00417.74
8.1.210.0040.00418.77
8.1.200.0080.00017.22
8.1.190.0030.00617.23
8.1.180.0000.00818.10
8.1.170.0040.00418.41
8.1.160.0000.00718.78
8.1.150.0080.00022.06
8.1.140.0000.00819.51
8.1.130.0030.00318.81
8.1.120.0000.00817.43
8.1.110.0030.00517.32
8.1.100.0040.00417.45
8.1.90.0070.00017.38
8.1.80.0030.00417.39
8.1.70.0040.00417.42
8.1.60.0080.00017.57
8.1.50.0000.00917.55
8.1.40.0070.00017.41
8.1.30.0040.00417.54
8.1.20.0050.00317.54
8.1.10.0040.00417.45
8.1.00.0040.00417.29
8.0.300.0070.00019.95
8.0.290.0080.00016.63
8.0.280.0070.00018.37
8.0.270.0030.00317.13
8.0.260.0030.00318.73
8.0.250.0030.00316.80
8.0.240.0040.00416.93
8.0.230.0000.00916.91
8.0.220.0090.00016.73
8.0.210.0000.00716.74
8.0.200.0030.00316.96
8.0.190.0030.00516.91
8.0.180.0040.00816.91
8.0.170.0070.00016.82
8.0.160.0040.00416.80
8.0.150.0000.00716.72
8.0.140.0070.00416.85
8.0.130.0050.00013.32
8.0.120.0040.00416.70
8.0.110.0000.00716.65
8.0.100.0070.00016.84
8.0.90.0000.00816.86
8.0.80.0090.01216.88
8.0.70.0040.00416.80
8.0.60.0040.00416.89
8.0.50.0020.00516.62
8.0.30.0090.00816.97
8.0.20.0080.01217.40
8.0.10.0030.00316.77
8.0.00.0050.01116.55
7.4.330.0030.00315.55
7.4.320.0000.00616.59
7.4.300.0000.00616.53
7.4.290.0030.00616.44
7.4.280.0030.00616.44
7.4.270.0070.00016.46
7.4.260.0030.00316.53
7.4.250.0080.00016.39
7.4.240.0050.00316.55
7.4.230.0060.00316.36
7.4.220.0090.00916.55
7.4.210.0100.00316.57
7.4.200.0000.00816.62
7.4.160.0060.01116.39
7.4.150.0070.01017.40
7.4.140.0100.00917.86
7.4.130.0100.00916.54
7.4.120.0100.01016.48
7.4.110.0130.00416.59
7.4.100.0060.01116.49
7.4.90.0090.01516.40
7.4.80.0100.00719.39
7.4.70.0130.00316.54
7.4.60.0060.00916.57
7.4.50.0030.01316.45
7.4.40.0130.00316.51
7.4.30.0130.00316.53
7.4.00.0060.00915.16
7.3.330.0020.00213.15
7.3.320.0020.00212.96
7.3.310.0030.00316.09
7.3.300.0040.00416.25
7.3.290.0070.00716.20
7.3.280.0110.00816.22
7.3.270.0130.00917.40
7.3.260.0080.00816.39
7.3.250.0100.00816.41
7.3.240.0090.00916.37
7.3.230.0190.00616.49
7.3.210.0060.00916.23
7.3.200.0150.00616.45
7.3.190.0070.01016.50
7.3.180.0040.01216.55
7.3.170.0040.01116.26
7.3.160.0060.01116.53
7.3.10.0080.00816.68
7.3.00.0090.00616.44
7.2.330.0030.01316.61
7.2.320.0180.00616.57
7.2.310.0060.01216.68
7.2.300.0110.00816.20
7.2.290.0040.01416.53
7.2.130.0070.00716.84
7.2.120.0080.00416.82
7.2.110.0000.01416.87
7.2.100.0080.00316.90
7.2.90.0040.00416.84
7.2.80.0040.00416.87
7.2.70.0030.00916.55
7.2.60.0080.00616.78
7.2.50.0080.00416.90
7.2.40.0090.00316.82
7.2.30.0030.00716.93
7.2.20.0080.00616.90
7.2.10.0030.01316.88
7.2.00.0040.00416.96
7.1.250.0080.00615.68
7.1.200.0190.00315.71
7.1.80.0300.00716.22
7.1.70.0240.00915.22
7.1.60.0360.01233.21
7.1.50.0400.00832.87
7.1.40.0420.00632.48
7.1.30.0570.00932.56
7.1.20.0400.01132.78
7.1.10.0230.01214.68
7.1.00.0510.01114.75
7.0.200.0220.00814.90
7.0.190.0230.01014.84
7.0.180.0270.01014.35
7.0.170.0180.00914.39
7.0.160.0300.00614.38
7.0.150.0240.01114.36
7.0.140.0290.00714.49
7.0.130.0210.00914.73
7.0.120.0220.00814.61
7.0.110.0240.00914.48
7.0.100.0260.00914.57
7.0.90.0210.01214.35
7.0.80.0250.00914.61
7.0.70.0220.01214.38
7.0.60.0190.00914.17
7.0.50.0250.00414.50
7.0.40.0250.01314.70
7.0.30.0280.00514.64
7.0.20.0280.01014.49
7.0.10.0260.00814.52
7.0.00.0260.00914.63
5.6.300.0060.06620.73
5.6.290.0150.06120.63
5.6.280.0150.05620.81
5.6.270.0130.05620.90
5.6.260.0060.05920.82
5.6.250.0120.06620.83
5.6.240.0100.06120.92
5.6.230.0100.06920.89
5.6.220.0130.05620.78
5.6.210.0070.06121.01
5.6.200.0110.05720.83
5.6.190.0120.05720.81
5.6.180.0100.06420.98
5.6.170.0140.05620.92
5.6.160.0130.06620.84
5.6.150.0140.06220.77
5.6.140.0180.05020.82
5.6.130.0080.05920.91
5.6.120.0150.05420.83
5.6.110.0110.05720.94
5.6.100.0130.05620.90
5.6.90.0090.06420.83
5.6.80.0080.05820.26
5.6.70.0120.05120.27
5.6.60.0120.06120.31
5.6.50.0060.06220.17
5.6.40.0120.05820.13
5.6.30.0140.05220.17
5.6.20.0150.05820.12
5.6.10.0120.04920.27
5.6.00.0150.05020.17
5.5.380.0070.06217.41
5.5.370.0140.05317.41
5.5.360.0120.05217.47
5.5.350.0070.05417.41
5.5.340.0090.05317.86
5.5.330.0060.06117.96
5.5.320.0140.05817.98
5.5.310.0120.05417.80
5.5.300.0090.05517.91
5.5.290.0100.06417.96
5.5.280.0130.05217.97
5.5.270.0070.06017.85
5.5.260.0080.05917.96
5.5.250.0150.06217.75
5.5.240.0100.05317.28
5.5.230.0120.05117.32
5.5.220.0080.06017.19
5.5.210.0120.05617.35
5.5.200.0110.05217.33
5.5.190.0120.05217.24
5.5.180.0110.05617.18
5.5.160.0150.04617.25
5.5.150.0130.04817.38
5.5.140.0110.04817.17
5.5.130.0110.05617.30
5.5.120.0160.04617.23
5.5.110.0070.05717.21
5.5.100.0090.05517.20
5.5.90.0110.05317.09
5.5.80.0080.05717.21
5.5.70.0110.05317.22
5.5.60.0100.05017.13
5.5.50.0120.05417.14
5.5.40.0160.05617.17
5.5.30.0080.05817.02
5.5.20.0070.06217.24
5.5.10.0100.05917.15
5.5.00.0080.05517.16
5.4.450.0140.05219.29
5.4.440.0160.05119.17
5.4.430.0170.04619.17
5.4.420.0100.06419.21
5.4.410.0120.05719.04
5.4.400.0080.05418.94
5.4.390.0090.05618.85
5.4.380.0120.05118.88
5.4.370.0140.05918.92
5.4.360.0020.05919.00
5.4.350.0100.05118.82
5.4.340.0040.05718.88
5.4.320.0120.04918.93
5.4.310.0090.05018.82
5.4.300.0190.05218.89
5.4.290.0120.05518.84
5.4.280.0120.05918.93
5.4.270.0100.05318.89
5.4.260.0160.05218.89
5.4.250.0110.05118.82
5.4.240.0090.05718.94
5.4.230.0100.05218.81
5.4.220.0200.04418.86
5.4.210.0090.05518.89
5.4.200.0060.06218.91
5.4.190.0160.05418.86
5.4.180.0160.05618.80
5.4.170.0170.05418.77
5.4.160.0070.05318.90
5.4.150.0060.05518.88
5.4.140.0070.05416.48
5.4.130.0110.04416.45
5.4.120.0120.05116.39
5.4.110.0110.05416.53
5.4.100.0080.04916.33
5.4.90.0080.04816.31
5.4.80.0090.05316.48
5.4.70.0110.04516.45
5.4.60.0090.05216.31
5.4.50.0080.05116.43
5.4.40.0080.04916.50
5.4.30.0100.04916.28
5.4.20.0100.04816.35
5.4.10.0160.04716.46
5.4.00.0130.04515.76
5.3.290.0060.05414.70
5.3.280.0100.05214.66
5.3.270.0120.05014.69
5.3.260.0110.05714.67
5.3.250.0180.03914.69
5.3.240.0070.05214.59
5.3.230.0080.05514.64
5.3.220.0100.06214.65
5.3.210.0090.05214.68
5.3.200.0080.05114.63
5.3.190.0060.05514.67
5.3.180.0100.05414.72
5.3.170.0120.04914.54
5.3.160.0080.05014.60
5.3.150.0090.05314.62
5.3.140.0100.05414.57
5.3.130.0100.05614.64
5.3.120.0070.05414.69
5.3.110.0080.05614.57
5.3.100.0100.05214.13
5.3.90.0130.04914.07
5.3.80.0100.04614.07
5.3.70.0110.04514.11
5.3.60.0090.04914.06
5.3.50.0090.05414.09
5.3.40.0070.05914.07
5.3.30.0170.05213.90
5.3.20.0150.05313.73
5.3.10.0090.05313.69
5.3.00.0110.04713.68
5.2.170.0080.04511.28
5.2.160.0060.04711.22
5.2.150.0090.05211.25
5.2.140.0120.04311.30
5.2.130.0060.04911.24
5.2.120.0120.04011.06
5.2.110.0090.03711.10
5.2.100.0100.03511.26
5.2.90.0080.04011.28
5.2.80.0100.03711.19
5.2.70.0070.04311.25
5.2.60.0070.04411.17
5.2.50.0070.04011.13
5.2.40.0100.04011.03
5.2.30.0070.04011.11
5.2.20.0080.04011.01
5.2.10.0080.04011.06
5.2.00.0110.03511.00
5.1.60.0040.04110.16
5.1.50.0090.03410.17
5.1.40.0090.04010.18
5.1.30.0090.04010.45
5.1.20.0060.04110.34
5.1.10.0060.03410.11
5.1.00.0090.03210.20
5.0.50.0030.0328.68
5.0.40.0110.0288.56
5.0.30.0020.0478.34
5.0.20.0070.0238.33
5.0.10.0080.0268.25
5.0.00.0030.0448.28
4.4.90.0060.0226.29
4.4.80.0030.0236.29
4.4.70.0040.0216.29
4.4.60.0050.0226.29
4.4.50.0070.0226.29
4.4.40.0020.0386.29
4.4.30.0060.0206.29
4.4.20.0040.0206.29
4.4.10.0030.0246.29
4.4.00.0050.0336.29
4.3.110.0050.0266.29
4.3.100.0050.0226.29
4.3.90.0030.0206.29
4.3.80.0020.0376.29
4.3.70.0030.0216.29
4.3.60.0000.0246.29
4.3.50.0000.0246.29
4.3.40.0030.0326.29
4.3.30.0010.0266.29
4.3.20.0020.0226.29
4.3.10.0030.0216.29
4.3.00.0020.0216.29

preferences:
28.34 ms | 403 KiB | 5 Q