3v4l.org

run code in 300+ PHP versions simultaneously
<?php $y = '<extData> <Airpoints> <APCurrency>NZD</APCurrency> </Airpoints> <orderData> <order><orderId>3</orderId><orderTime>2014-10-23T02:51:48</orderTime><item><sku>130</sku><title>Chicken Sandwich</title><quantity>1</quantity><price>10.00</price><amount>10.00</amount></item><subtotal>10.00</subtotal><fee>0.00</fee><total>10.00</total><orderStatus>COMP</orderStatus></order><schema_version>2</schema_version> </orderData> </extData>>2014-A'; $x = '<extData> <orderData> <order><orderId>6</orderId><orderTime>2014-10-23T02:53:38</orderTime><item><sku>138</sku><title>Beef Pie</title><quantity>1</quantity><price>8.00</price><amount>8.00</amount></item><item><sku>138</sku><title>Beef Pie</title><quantity>-1</quantity><price>8.00</price><amount>-8.00</amount></item><subtotal>0.00</subtotal><fee>0.00</fee><total>0.00</total><orderStatus>COMP</orderStatus></order><schema_version>2</schema_version> </orderData> </extData><price>±'; if(preg_match('/<extData>(.*)<\/extData>/s',$y, $matches)) { $xml = new SimpleXMLElement($matches[0]); $code = $xml->xpath('//APCurrency'); echo (string)$code[0]; }

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.70.0110.00717.00
8.3.60.0120.00618.93
8.3.50.0100.01022.44
8.3.40.0120.00619.34
8.3.30.0110.00319.54
8.3.20.0000.00720.50
8.3.10.0040.00423.89
8.3.00.0090.00019.75
8.2.180.0000.01417.25
8.2.170.0140.00022.96
8.2.160.0130.00720.72
8.2.150.0040.00424.18
8.2.140.0030.00524.66
8.2.130.0070.00026.16
8.2.120.0070.00022.59
8.2.110.0000.01022.52
8.2.100.0090.00318.00
8.2.90.0050.00319.51
8.2.80.0050.00318.00
8.2.70.0050.00518.12
8.2.60.0060.00618.40
8.2.50.0030.00518.07
8.2.40.0080.00018.72
8.2.30.0000.00718.44
8.2.20.0000.00918.18
8.2.10.0000.00818.61
8.2.00.0030.00618.13
8.1.280.0100.01025.92
8.1.270.0000.00924.10
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0040.01824.22
8.1.230.0090.00319.48
8.1.220.0040.00418.03
8.1.210.0040.00718.77
8.1.200.0070.00317.60
8.1.190.0000.00817.72
8.1.180.0040.00418.10
8.1.170.0040.00718.93
8.1.160.0040.00422.36
8.1.150.0050.00319.13
8.1.140.0000.00717.82
8.1.130.0000.00718.19
8.1.120.0040.00417.95
8.1.110.0070.00018.00
8.1.100.0050.00218.04
8.1.90.0030.00717.82
8.1.80.0040.00417.97
8.1.70.0000.00817.91
8.1.60.0060.00318.13
8.1.50.0040.00418.03
8.1.40.0000.00718.10
8.1.30.0000.00818.18
8.1.20.0030.00518.25
8.1.10.0070.00018.13
8.1.00.0000.00818.01
8.0.300.0040.00418.77
8.0.290.0050.00317.13
8.0.280.0040.00418.78
8.0.270.0040.00417.57
8.0.260.0070.00017.68
8.0.250.0000.00717.36
8.0.240.0060.00017.29
8.0.230.0030.00317.40
8.0.220.0070.00017.19
8.0.210.0070.00017.16
8.0.200.0040.00417.39
8.0.190.0000.00817.43
8.0.180.0080.00017.23
8.0.170.0040.00417.38
8.0.160.0060.00317.39
8.0.150.0000.00717.26
8.0.140.0040.00417.37
8.0.130.0000.00613.82
8.0.120.0060.00317.36
8.0.110.0050.00317.34
8.0.100.0050.00317.16
8.0.90.0040.00417.27
8.0.80.0100.00617.27
8.0.70.0050.00317.27
8.0.60.0000.00817.25
8.0.50.0050.00317.24
8.0.30.0120.00917.69
8.0.20.0090.01417.40
8.0.10.0000.00717.38
8.0.00.0080.00917.15
7.4.330.0000.00615.02
7.4.320.0000.00717.05
7.4.300.0000.00717.13
7.4.290.0070.00017.13
7.4.280.0000.00817.20
7.4.270.0070.00017.12
7.4.260.0070.00317.05
7.4.250.0000.00817.17
7.4.240.0020.00517.15
7.4.230.0030.00317.07
7.4.220.0030.01516.99
7.4.210.0110.00917.29
7.4.200.0040.00417.14
7.4.160.0150.00317.06
7.4.150.0060.01317.40
7.4.140.0110.00717.86
7.4.130.0110.01117.12
7.4.120.0100.01017.15
7.4.110.0060.01216.86
7.4.100.0130.00917.26
7.4.90.0130.01017.05
7.4.80.0090.01019.39
7.4.70.0040.01317.02
7.4.60.0100.00616.89
7.4.50.0030.00317.15
7.4.40.0100.01317.14
7.4.30.0150.00617.12
7.4.00.0060.00915.12
7.3.330.0030.00313.70
7.3.320.0030.00313.45
7.3.310.0040.00416.87
7.3.300.0030.00316.79
7.3.290.0110.00416.84
7.3.280.0090.00816.80
7.3.270.0090.00917.40
7.3.260.0130.00417.04
7.3.250.0130.00616.91
7.3.240.0070.01116.80
7.3.230.0070.01017.02
7.3.210.0100.01017.11
7.3.200.0150.00619.39
7.3.190.0090.00916.91
7.3.180.0100.00716.95
7.3.170.0080.00917.16
7.3.160.0080.00816.91
7.3.120.0050.01215.26
7.3.110.0080.00815.18
7.3.100.0050.01114.90
7.3.90.0040.01114.94
7.3.80.0060.00715.22
7.3.70.0050.00815.16
7.3.60.0060.00815.08
7.3.50.0050.01115.17
7.3.40.0070.00315.07
7.3.30.0080.00615.02
7.3.20.0050.00816.94
7.3.10.0040.00816.94
7.3.00.0080.00316.91
7.2.330.0030.01417.17
7.2.320.0100.00717.04
7.2.310.0060.01217.21
7.2.300.0190.00316.98
7.2.290.0110.01217.14
7.2.240.0060.00315.39
7.2.230.0040.00915.32
7.2.220.0060.00515.28
7.2.210.0080.00715.29
7.2.200.0020.01315.28
7.2.190.0050.00815.34
7.2.180.0020.01215.50
7.2.170.0050.00815.23
7.2.160.0050.01015.23
7.2.150.0040.01117.13
7.2.140.0020.00817.34
7.2.130.0060.00617.38
7.2.120.0000.01317.21
7.2.110.0070.00917.19
7.2.100.0090.00517.32
7.2.90.0050.00817.37
7.2.80.0100.00617.33
7.2.70.0070.00817.21
7.2.60.0100.00617.04
7.2.50.0050.00717.11
7.2.40.0020.01117.28
7.2.30.0090.00417.30
7.2.20.0070.00617.20
7.2.10.0060.01117.25
7.2.00.0040.01018.16
7.1.330.0080.00716.15
7.1.320.0100.00516.07
7.1.310.0050.01016.26
7.1.300.0030.00915.93
7.1.290.0030.01016.11
7.1.280.0080.00516.17
7.1.270.0080.00516.10
7.1.260.0070.00416.15
7.1.250.0080.00515.99
7.1.200.0110.00016.14
7.1.100.0200.00016.73
7.1.70.0030.01617.37
7.1.60.0100.01319.32
7.1.50.0060.00917.30
7.1.00.0030.07722.62
7.0.200.0000.00817.16
7.0.140.0030.07322.23
7.0.60.0030.04020.15
7.0.50.0100.04318.11
7.0.40.0030.07020.21
7.0.30.0330.04720.23
7.0.20.0270.03320.37
7.0.10.0100.08320.23
7.0.00.0030.04320.26
5.6.280.0070.07021.10
5.6.210.0130.06720.75
5.6.200.0100.06018.42
5.6.190.0070.04320.83
5.6.180.4300.05020.55
5.6.170.0300.06320.75
5.6.160.0170.08020.70
5.6.150.0130.08018.37
5.6.140.0030.07718.36
5.6.130.0070.08718.41
5.6.120.0030.04021.27
5.6.110.0100.07321.20
5.6.100.0170.07321.23
5.6.90.0070.04321.21
5.6.80.0000.05020.54
5.6.70.4530.03320.64
5.5.350.0200.03720.56
5.5.340.0030.04318.20
5.5.330.0070.08320.65
5.5.320.3370.04020.43
5.5.310.0370.04720.55
5.5.300.0100.08018.19
5.5.290.0070.07018.09
5.5.280.0070.08020.98
5.5.270.0100.06321.07
5.5.260.0000.04320.98
5.5.250.0130.07320.87
5.5.240.0330.06320.38
5.4.450.0900.05319.84
5.4.440.0770.06719.73
5.4.430.0770.06019.76
5.4.420.0130.05019.76
5.4.410.0870.05719.47
5.4.400.0770.05719.25
5.4.390.0170.05319.38
5.4.380.0970.04319.44
5.4.370.0130.04719.34
5.4.360.0870.05719.30
5.4.350.0900.05019.28
5.4.340.0060.03512.20
5.4.320.0040.03812.69
5.4.310.0060.03812.68
5.4.300.0070.03512.69
5.4.290.0080.03812.69
5.4.280.0070.05012.59
5.4.270.0100.04812.59
5.4.260.0060.03712.59
5.4.250.0060.03812.59
5.4.240.0050.04112.59
5.4.230.0080.04312.57
5.4.220.0060.03512.57
5.4.210.0070.03312.57
5.4.200.0080.03612.57
5.4.190.0050.03612.57
5.4.180.0070.03512.57
5.4.170.0060.03612.59
5.4.160.0050.03612.58
5.4.150.0030.03812.58
5.4.140.0040.03812.26
5.4.130.0080.03312.25
5.4.120.0100.03212.21
5.4.110.0060.03512.20
5.4.100.0070.03412.21
5.4.90.0050.03812.21
5.4.80.0070.03512.21
5.4.70.0080.03312.20
5.4.60.0050.03912.20
5.4.50.0070.03512.20
5.4.40.0140.04212.19
5.4.30.0090.04712.19
5.4.20.0070.04912.19
5.4.10.0110.04512.19
5.4.00.0100.03911.67
5.3.290.0030.05612.95
5.3.280.0140.03912.88
5.3.270.0110.04212.89
5.3.260.0110.03912.90
5.3.250.0050.03912.90
5.3.240.0090.03412.89
5.3.230.0100.03712.89
5.3.220.0060.03712.86
5.3.210.0070.03812.86
5.3.200.0050.03712.86
5.3.190.0120.04012.86
5.3.180.0060.03712.86
5.3.170.0030.03912.85
5.3.160.0050.03712.86
5.3.150.0050.03712.85
5.3.140.0120.03512.84
5.3.130.0070.03812.84
5.3.120.0060.04612.84
5.3.110.0120.04112.84
5.3.100.0080.03612.32
5.3.90.0100.03312.30
5.3.80.0050.03812.29
5.3.70.0060.03712.29
5.3.60.0050.03712.28
5.3.50.0050.04312.23
5.3.40.0080.03912.23
5.3.30.0060.03512.19
5.3.20.0060.03711.96
5.3.10.0090.04711.94
5.3.00.0090.05211.92
5.2.170.0050.0309.42
5.2.160.0050.0309.42
5.2.150.0080.0289.42
5.2.140.0070.0299.42
5.2.130.0060.0329.38
5.2.120.0030.0309.38
5.2.110.0070.0269.39
5.2.100.0060.0279.38
5.2.90.0070.0279.38
5.2.80.0010.0369.38
5.2.70.0050.0309.38
5.2.60.0060.0289.32
5.2.50.0060.0319.30
5.2.40.0050.0329.27
5.2.30.0020.0369.26
5.2.20.0030.0309.24
5.2.10.0050.0279.16
5.2.00.0050.0289.02
5.1.60.0080.0248.30
5.1.50.0060.0258.30
5.1.40.0050.0248.29
5.1.30.0040.0278.64
5.1.20.0040.0318.65
5.1.10.0060.0288.37
5.1.00.0050.0268.36
5.0.50.0050.0266.85
5.0.40.0080.0226.70
5.0.30.0080.0376.53
5.0.20.0080.0246.50
5.0.10.0060.0236.47
5.0.00.0040.0356.46
4.4.90.0030.0164.78
4.4.80.0020.0174.75
4.4.70.0040.0144.75
4.4.60.0020.0174.76
4.4.50.0020.0244.77
4.4.40.0010.0364.71
4.4.30.0040.0154.76
4.4.20.0020.0174.84
4.4.10.0070.0124.85
4.4.00.0010.0274.76
4.3.110.0050.0194.67
4.3.100.0040.0234.66
4.3.90.0050.0294.63
4.3.80.0090.0544.59
4.3.70.0050.0304.63
4.3.60.0080.0354.63
4.3.50.0070.0194.63
4.3.40.0040.0264.53
4.3.30.0030.0213.29
4.3.20.0030.0213.26
4.3.10.0050.0173.22
4.3.00.0130.0237.21

preferences:
57.91 ms | 401 KiB | 5 Q