3v4l.org

run code in 500+ PHP versions simultaneously
<?php function uuid_to_bin($uuid){ $bin_uuid = pack("H*", str_replace('-', '', $uuid)); return $bin_uuid; } function bin_to_uuid($binid) { $arr= unpack("H*", $binid); $string = $arr['1']; $string = preg_replace("/([0-9a-f]{8})([0-9a-f]{4})([0-9a-f]{4})([0-9a-f]{4})([0-9a-f]{12})/", "$1-$2-$3-$4-$5", $string); return $string; } $uuids = [ '9c4ddfc6-6f31-486b-b07e-17cecc493a94', '00000000-0000-0000-0000-000000000000', ]; foreach ($uuids as $uuid) { var_dump($uuid === bin_to_uuid(uuid_to_bin($uuid))); }

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.0110.00619.00
8.5.20.0090.00819.55
8.5.10.0090.00816.91
8.5.00.0100.01320.29
8.4.180.0160.00619.81
8.4.170.0150.00623.87
8.4.160.0120.00923.85
8.4.150.0080.00616.90
8.4.140.0120.01017.68
8.4.130.0140.00818.20
8.4.120.0070.00320.63
8.4.110.0100.01020.27
8.4.100.0110.01018.67
8.4.90.0130.00819.04
8.4.80.0130.00618.84
8.4.70.0070.00918.20
8.4.60.0120.00820.82
8.4.50.0110.00818.72
8.4.40.0080.00019.59
8.4.30.0150.00417.67
8.4.20.0160.00319.57
8.4.10.0050.00520.65
8.3.300.0150.00520.85
8.3.290.0150.00720.95
8.3.280.0150.00818.45
8.3.270.0110.00816.62
8.3.260.0100.01016.77
8.3.250.0100.00918.71
8.3.240.0140.00516.79
8.3.230.0110.01016.75
8.3.220.0090.00819.11
8.3.210.0090.00616.53
8.3.200.0050.00416.93
8.3.190.0100.00817.30
8.3.180.0090.01116.39
8.3.170.0080.00920.96
8.3.160.0120.00617.05
8.3.150.0080.01117.05
8.3.140.0090.00916.88
8.3.130.0070.01418.59
8.3.120.0040.00420.58
8.3.110.0000.00816.90
8.3.100.0060.00324.06
8.3.90.0050.00326.77
8.3.80.0050.00518.43
8.3.70.0100.01016.75
8.3.60.0040.01118.41
8.3.50.0060.00818.40
8.3.40.0060.00918.95
8.3.30.0140.00018.90
8.3.20.0000.00819.15
8.3.10.0030.00621.67
8.3.00.0040.00422.31
8.2.300.0140.00618.69
8.2.290.0100.00920.44
8.2.280.0120.00818.55
8.2.270.0140.00717.24
8.2.260.0150.00316.96
8.2.250.0030.00616.86
8.2.240.0120.00617.22
8.2.230.0050.00520.94
8.2.220.0050.00537.54
8.2.210.0000.00826.77
8.2.200.0090.00017.00
8.2.190.0070.00716.88
8.2.180.0090.00625.92
8.2.170.0120.00919.21
8.2.160.0070.00722.96
8.2.150.0070.00025.66
8.2.140.0040.00424.66
8.2.130.0050.00321.05
8.2.120.0080.00026.35
8.2.110.0060.00321.24
8.2.100.0030.00818.03
8.2.90.0080.00018.22
8.2.80.0030.00518.15
8.2.70.0000.00818.05
8.2.60.0040.00418.16
8.2.50.0000.00818.10
8.2.40.0000.00819.20
8.2.30.0030.00621.31
8.2.20.0040.00418.14
8.2.10.0030.00618.19
8.2.00.0000.00719.43
8.1.340.0130.00820.02
8.1.330.0100.00921.84
8.1.320.0140.00716.29
8.1.310.0080.00016.54
8.1.300.0130.00618.50
8.1.290.0060.00330.84
8.1.280.0160.00625.92
8.1.270.0060.00323.77
8.1.260.0070.00026.35
8.1.250.0080.00028.09
8.1.240.0090.00022.61
8.1.230.0030.01220.95
8.1.220.0000.00917.74
8.1.210.0080.00418.77
8.1.200.0100.00017.34
8.1.190.0050.00317.25
8.1.180.0000.00718.10
8.1.170.0030.00518.79
8.1.160.0040.00418.88
8.1.150.0060.00319.03
8.1.140.0040.00417.64
8.1.130.0000.00817.53
8.1.120.0040.00417.57
8.1.110.0040.00417.49
8.1.100.0040.00417.50
8.1.90.0030.00517.50
8.1.80.0040.00417.57
8.1.70.0030.00317.52
8.1.60.0080.00017.76
8.1.50.0070.00317.67
8.1.40.0060.00317.66
8.1.30.0000.00817.66
8.1.20.0000.00717.75
8.1.10.0040.00417.75
8.1.00.0030.00517.63
8.0.300.0070.00020.04
8.0.290.0050.00216.88
8.0.280.0030.00318.34
8.0.270.0000.00716.97
8.0.260.0000.00716.98
8.0.250.0030.00316.99
8.0.240.0040.00417.02
8.0.230.0080.00017.08
8.0.220.0030.00317.03
8.0.210.0050.00216.94
8.0.200.0050.00317.01
8.0.190.0030.00617.08
8.0.180.0000.00717.02
8.0.170.0030.00516.91
8.0.160.0070.00017.05
8.0.150.0000.00716.86
8.0.140.0040.00417.00
8.0.130.0000.00613.46
8.0.120.0070.00016.95
8.0.110.0000.00817.02
8.0.100.0000.00816.84
8.0.90.0000.00717.09
8.0.80.0070.01017.06
8.0.70.0000.00817.15
8.0.60.0050.00216.96
8.0.50.0000.00816.88
8.0.30.0060.01217.12
8.0.20.0110.01617.40
8.0.10.0000.00717.14
8.0.00.0120.00616.84
7.4.330.0050.00016.85
7.4.320.0040.00416.79
7.4.300.0000.00616.78
7.4.290.0000.00716.75
7.4.280.0020.00516.79
7.4.270.0030.00316.71
7.4.260.0080.00016.79
7.4.250.0070.00016.77
7.4.240.0030.00316.73
7.4.230.0080.00016.64
7.4.220.0000.00816.79
7.4.210.0090.01016.72
7.4.200.0040.00416.70
7.4.160.0100.00816.77
7.4.140.0080.01117.86
7.4.130.0170.00716.88
7.4.120.0090.00916.79
7.4.110.0090.00916.73
7.4.100.0140.00716.77
7.4.90.0130.00716.85
7.4.80.0170.00019.39
7.4.70.0130.00316.62
7.4.60.0100.00716.79
7.4.50.0030.01316.55
7.4.40.0130.01016.70
7.4.00.0070.01215.24
7.3.330.0000.00713.36
7.3.320.0050.00013.53
7.3.310.0030.00316.49
7.3.300.0070.00016.48
7.3.290.0030.00316.42
7.3.280.0070.00916.49
7.3.260.0090.00816.65
7.3.240.0110.00716.67
7.3.230.0110.01316.86
7.3.210.0100.00716.65
7.3.200.0090.00916.60
7.3.190.0130.00316.45
7.3.180.0030.01216.36
7.3.170.0130.00316.65
7.3.160.0090.01216.91
7.3.120.0080.00814.74
7.3.110.0060.01214.82
7.3.100.0110.00415.18
7.3.90.0160.00315.29
7.3.80.0060.00915.15
7.3.70.0120.00014.85
7.3.60.0000.01615.02
7.3.50.0000.00915.05
7.3.40.0090.00015.02
7.3.30.0000.01415.08
7.3.20.0040.01216.70
7.3.10.0030.00816.79
7.3.00.0000.01216.82
7.2.330.0070.01017.08
7.2.320.0040.01316.70
7.2.310.0060.01216.75
7.2.300.0080.00816.96
7.2.290.0070.01416.74
7.2.250.0000.01815.38
7.2.240.0100.00615.45
7.2.230.0100.01015.26
7.2.220.0110.00815.15
7.2.210.0040.00715.32
7.2.200.0090.00615.01
7.2.190.0130.00315.37
7.2.180.0060.01215.31
7.2.170.0060.00615.23
7.2.60.0220.00716.86
7.2.50.0130.00716.90
7.2.40.5020.01218.22
7.2.30.6280.01318.21
7.2.20.4860.01418.14
7.2.10.3940.01018.24
7.2.00.5570.01218.37
7.1.330.0060.00916.05
7.1.320.0040.01216.06
7.1.310.0050.00516.09
7.1.300.0030.01015.76
7.1.290.0090.00916.12
7.1.280.0030.00715.71
7.1.270.0070.00715.99
7.1.260.0060.00315.88
7.1.200.0050.00515.97
7.1.160.3590.01017.05
7.1.150.4260.01117.11
7.1.140.4660.00916.86
7.1.130.3020.01017.18
7.1.120.4510.01016.98
7.1.110.5050.01216.37
7.1.100.4790.01316.52
7.1.90.5510.01216.56
7.1.80.5830.00916.26
7.1.70.4820.01015.32
7.1.60.5690.01133.47
7.1.50.5030.01433.19
7.1.40.0480.01532.90
7.1.30.0470.01633.13
7.1.20.0490.01432.98
7.1.10.0300.01214.84
7.1.00.3870.00815.05
5.6.400.0180.00916.52

preferences:
113.75 ms | 1513 KiB | 5 Q