3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = '{"head":[{"FormId": "FR100400061","CatchDate": "2016-01-25T12:17:57","TravelerId": "80222557","TravelerName": "El gio gonzales","Status": 1,"CustAccount": "1004","CustName":"Court de Tennis","Middleman":"1008","MiddlemanName":"Wide World Importers","DataAreaId":"frrt","CreatedBy": "123","CreatedDateTime": "2016-01-25T12:17:57"}],"lines": [{"ItemId": "IVA21","FamilyId": "","FamilyDescription": "Zapatitos","TotalVal": 123.0,"TaxVal": 21.35,"BaseVal": 101.65,"FormId":"FR100400061","RefundVal": 13.0,"DataAreaId": "frrt"}],"traveler":[{"TravelerId":"80222557","Email":"garanda21@gmail.com","Name":"El gio gonzales","Country": "PE","CountryName": "Peru","Address":"Calle de abaja bien abajo","Gender": 1,"Birthdate":"23/12/1982"}]}'; /* $str = "sample data"; $bzstr = bzcompress($string, 9); echo $bzstr;*/ //$string = str_repeat('1234567890'.implode('',range('a','z')),48800); $sJSON = json_decode($string); echo $sJSON; echo strlen($sJSON);//1756800 bytes $compressed = gzdeflate($string, 9); //$compressed = gzdeflate($compressed, 9); echo '<br/>'.strlen($compressed).'<br/>';//99 bytes /*echo $string*/ //echo gzinflate(gzinflate($compressed)); ?>

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.60.0070.00718.68
8.3.50.0280.00221.99
8.3.40.0140.00418.88
8.3.30.0030.01218.80
8.3.20.0060.00320.39
8.3.10.0060.00320.70
8.3.00.0000.01021.73
8.2.180.0110.00425.92
8.2.170.0070.00718.97
8.2.160.0030.01022.96
8.2.150.0110.00425.66
8.2.140.0120.00624.66
8.2.130.0040.00421.00
8.2.120.0040.00426.35
8.2.110.0030.00620.55
8.2.100.0090.00317.72
8.2.90.0040.00419.22
8.2.80.0040.00417.97
8.2.70.0000.00917.50
8.2.60.0050.00317.80
8.2.50.0040.00418.09
8.2.40.0050.00520.60
8.2.30.0050.00219.54
8.2.20.0060.00317.63
8.2.10.0070.00018.23
8.2.00.0040.00418.09
8.1.280.0070.01025.92
8.1.270.0070.00024.66
8.1.260.0080.00028.09
8.1.250.0000.00828.09
8.1.240.0110.00023.91
8.1.230.0110.00022.68
8.1.220.0040.00417.79
8.1.210.0040.00418.77
8.1.200.0030.00917.35
8.1.190.0060.00317.25
8.1.180.0040.00418.10
8.1.170.0000.01018.48
8.1.160.0040.00420.61
8.1.150.0030.00618.81
8.1.140.0040.00419.57
8.1.130.0050.00317.68
8.1.120.0030.00517.38
8.1.110.0000.00817.42
8.1.100.0040.00417.39
8.1.90.0040.00417.36
8.1.80.0000.00817.40
8.1.70.0030.00317.45
8.1.60.0040.00417.58
8.1.50.0040.00417.57
8.1.40.0030.00517.58
8.1.30.0060.00317.60
8.1.20.0000.00817.43
8.1.10.0050.00217.47
8.1.00.0080.00017.52
8.0.300.0000.00718.77
8.0.290.0050.00316.75
8.0.280.0030.00318.36
8.0.270.0030.00317.16
8.0.260.0000.00717.16
8.0.250.0000.00716.91
8.0.240.0060.00016.89
8.0.230.0040.00416.84
8.0.220.0030.00316.84
8.0.210.0040.00416.82
8.0.200.0000.00616.95
8.0.190.0040.00416.93
8.0.180.0030.00516.92
8.0.170.0050.00316.78
8.0.160.0050.00316.96
8.0.150.0070.00016.71
8.0.140.0000.00716.80
8.0.130.0000.00513.34
8.0.120.0060.00316.81
8.0.110.0040.00416.94
8.0.100.0020.00516.71
8.0.90.0000.00816.69
8.0.80.0040.01116.94
8.0.70.0040.00416.82
8.0.60.0000.00816.96
8.0.50.0000.00816.91
8.0.30.0080.00916.88
8.0.20.0080.01017.40
8.0.10.0000.00716.89
8.0.00.0060.01216.85
7.4.330.0020.00216.67
7.4.320.0000.00716.45
7.4.300.0030.00316.60
7.4.290.0000.00716.52
7.4.280.0000.00716.61
7.4.270.0030.00616.63
7.4.260.0080.00016.48
7.4.250.0000.00716.42
7.4.240.0080.00016.54
7.4.230.0000.00716.34
7.4.220.0060.01216.67
7.4.210.0050.01016.62
7.4.200.0000.00716.68
7.4.160.0120.00316.44
7.4.150.0120.00617.40
7.4.140.0100.00817.86
7.4.130.0130.00716.54
7.4.120.0120.00516.36
7.4.110.0100.00616.48
7.4.100.0070.01116.61
7.4.90.0060.01016.48
7.4.80.0170.00019.39
7.4.70.0100.00716.42
7.4.60.0150.00316.49
7.4.50.0030.01416.42
7.4.40.0140.00316.25
7.4.30.0130.00316.45
7.4.00.0090.00614.96
7.3.330.0060.00013.00
7.3.320.0030.00312.96
7.3.310.0070.00016.40
7.3.300.0000.00616.22
7.3.290.0030.00316.30
7.3.280.0100.00416.24
7.3.270.0120.00617.40
7.3.260.0060.01116.25
7.3.250.0120.00616.34
7.3.240.0080.01116.30
7.3.230.0110.00616.39
7.3.210.0130.00316.31
7.3.200.0150.00416.50
7.3.190.0060.01216.41
7.3.180.0120.00616.33
7.3.170.0150.00616.57
7.3.160.0070.01016.29
7.2.330.0070.01716.48
7.2.320.0130.00316.71
7.2.310.0180.00016.56
7.2.300.0110.00616.37
7.2.290.0130.00316.48
7.2.60.0090.00316.91
7.2.00.0040.01118.98
7.1.200.0070.00715.91
7.1.100.0030.01318.12
7.1.70.0000.00917.27
7.1.60.0140.01019.27
7.1.50.0000.01316.78
7.1.00.0070.09022.43
7.0.200.0350.00614.66
7.0.60.0370.08019.96
7.0.50.0030.04317.79
7.0.40.0170.04320.27
7.0.30.0470.05320.34
7.0.20.0300.08020.09
7.0.10.0130.06020.33
7.0.00.0100.08320.12
5.6.280.0100.05721.04
5.6.210.0170.06020.67
5.6.200.0070.03718.19
5.6.190.0100.06020.47
5.6.180.0270.03720.64
5.6.170.0230.08320.40
5.6.160.0070.07320.37
5.6.150.0170.04318.18
5.6.140.0070.05718.20
5.6.130.0070.06318.21
5.6.120.0130.08020.99
5.6.110.0170.07721.11
5.6.100.0070.05021.07
5.6.90.0030.09020.98
5.6.80.0070.08320.41
5.5.350.0270.06320.43
5.5.340.0070.07718.00
5.5.330.0130.07720.23
5.5.320.0530.05320.30
5.5.310.0130.04320.29
5.5.300.0130.08017.98
5.5.290.0130.03717.91
5.5.280.0130.08320.77
5.5.270.0070.07020.75
5.5.260.0100.06720.75
5.5.250.0100.08020.70
5.5.240.0100.07020.03

preferences:
70.69 ms | 401 KiB | 5 Q