3v4l.org

run code in 200+ PHP versions simultaneously
<?php class test { public function __construct(array $values) { print_r($values); } public static function getInstance($db) { $result = $db->query("SELECT * from test"); var_dump($result); return new test($result->fetchArray(SQLITE3_ASSOC)); } } $db = new SQLite3(":memory:", SQLITE3_OPEN_READWRITE | SQLITE3_OPEN_CREATE); $db->query("CREATE TABLE test (foo, bar)"); test::getInstance($db); print "done"; ?>

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)
7.4.10.0110.00715.84
7.4.00.0070.01015.54
7.3.130.0130.00715.49
7.3.120.0050.00915.62
7.3.110.0050.01215.45
7.3.100.0030.01015.53
7.3.90.0050.00815.46
7.3.80.0050.00915.54
7.3.70.0090.00815.45
7.3.60.0090.00515.49
7.3.50.0110.00515.65
7.3.40.0060.00715.34
7.3.30.0040.01115.47
7.3.20.0080.00517.42
7.3.10.0090.00617.38
7.3.00.0060.00617.29
7.2.260.0040.01515.91
7.2.250.0070.01115.94
7.2.240.0130.00515.81
7.2.230.0100.00815.75
7.2.220.0060.01215.64
7.2.210.0050.01015.61
7.2.200.0070.00815.75
7.2.190.0100.00515.65
7.2.180.0070.00715.69
7.2.170.0050.00815.75
7.2.160.0070.00815.67
7.2.150.0100.00217.43
7.2.140.0050.00717.55
7.2.130.0080.00717.36
7.2.120.0050.00917.66
7.2.110.0050.01017.54
7.2.100.0040.01117.61
7.2.90.0050.01017.49
7.2.80.0050.00917.46
7.2.70.0080.00617.67
7.2.60.0050.01017.46
7.2.50.0060.00817.61
7.2.40.0050.01117.37
7.2.30.0090.00817.65
7.2.20.0060.00617.75
7.2.10.0030.01017.47
7.2.00.0050.00818.44
7.1.330.0060.01116.45
7.1.320.0080.00716.50
7.1.310.0070.01016.46
7.1.300.0080.00816.37
7.1.290.0050.00816.25
7.1.280.0030.01116.35
7.1.270.0060.00616.42
7.1.260.0040.00916.11
7.1.250.0080.00616.41
7.1.240.0030.00916.39
7.1.230.0070.01116.52
7.1.220.0060.00616.13
7.1.210.0030.01216.30
7.1.200.0070.00616.27
7.1.190.0090.00616.31
7.1.180.0000.01516.30
7.1.170.0030.00616.50
7.1.160.0070.00716.39
7.1.150.0030.00816.44
7.1.140.0030.01416.50
7.1.130.0030.00616.46
7.1.120.0080.00816.45
7.1.110.0000.01416.16
7.1.100.0050.00617.75
7.1.90.0030.00916.41
7.1.80.0030.00916.44
7.1.70.0030.01017.13
7.1.60.0090.01017.87
7.1.50.0050.01117.12
7.1.40.0060.00616.45
7.1.30.0030.00616.49
7.1.20.0090.00416.38
7.1.10.0150.00016.62
7.1.00.0030.03719.51
7.0.330.0030.01015.70
7.0.320.0040.01115.90
7.0.310.0050.00616.19
7.0.300.0070.00716.06
7.0.290.0030.01215.80
7.0.280.0030.00616.23
7.0.270.0030.00916.06
7.0.260.0070.00716.16
7.0.250.0100.00316.05
7.0.240.0030.01016.18
7.0.230.0090.00316.09
7.0.220.0000.01216.15
7.0.210.0040.00715.86
7.0.200.0020.01016.85
7.0.190.0060.00615.85
7.0.180.0070.00715.88
7.0.170.0060.00616.08
7.0.160.0100.00316.12
7.0.150.0090.00616.09
7.0.140.0100.03719.21
7.0.130.0030.01015.71
7.0.120.0070.03119.12
7.0.110.0100.00316.09
7.0.100.0030.01516.11
7.0.90.0060.00616.11
7.0.80.0030.00916.11
7.0.70.0070.00715.75
7.0.60.0030.05018.94
7.0.50.0080.04017.00
7.0.40.0100.03815.83
7.0.30.0060.02415.94
7.0.20.0100.02516.00
7.0.10.0070.04515.94
7.0.00.0070.02715.96
5.6.400.0070.00315.16
5.6.390.0060.00914.98
5.6.380.0000.01414.87
5.6.370.0040.01115.08
5.6.360.0110.00414.75
5.6.350.0070.01014.99
5.6.340.0030.00715.14
5.6.330.0070.00715.07
5.6.320.0110.00314.70
5.6.310.0030.01214.84
5.6.300.0000.01214.63
5.6.290.0080.00515.17
5.6.280.0070.04018.09
5.6.270.0030.01314.61
5.6.260.0050.01114.83
5.6.250.0090.00514.80
5.6.240.0000.01714.96
5.6.230.0060.01014.93
5.6.220.0040.01114.88
5.6.210.0040.04717.82
5.6.200.0000.04116.51
5.6.190.0050.02916.61
5.6.180.0040.03416.49
5.6.170.0060.02516.75
5.6.160.0100.04416.56
5.6.150.0050.04816.58
5.6.140.0060.03316.45
5.6.130.0090.04116.62
5.6.120.0080.02816.61
5.6.110.0080.04016.65
5.6.100.0080.02316.57
5.6.90.0080.02816.45
5.6.80.0030.04416.15
5.6.70.0140.03316.27
5.6.60.0100.04216.24
5.6.50.0100.02216.23
5.6.40.0050.02216.10
5.6.30.0090.03916.18
5.6.20.0050.03216.15
5.6.10.0000.04216.26
5.6.00.0050.02516.15
5.5.380.0070.00714.84
5.5.370.0060.00914.93
5.5.360.0030.01014.98
5.5.350.0060.02517.73
5.5.340.0070.04116.38
5.5.330.0060.04116.52
5.5.320.0090.04416.47
5.5.310.0020.03816.46
5.5.300.0040.05016.57
5.5.290.0100.04516.54
5.5.280.0050.04516.49
5.5.270.0100.04216.43
5.5.260.0050.03116.64
5.5.250.0050.02616.32
5.5.240.0070.02516.25
5.5.230.0050.02215.99
5.5.220.0020.04115.97
5.5.210.0070.03816.10
5.5.200.0050.04116.12
5.5.190.0050.04216.14
5.5.180.0070.04416.17
5.5.170.0080.00914.84
5.5.160.0000.02916.22
5.5.150.0140.03516.13
5.5.140.0070.04415.97
5.5.130.0050.02615.85
5.5.120.0020.02415.97
5.5.110.0000.02816.01
5.5.100.0100.01815.91
5.5.90.0050.02315.98
5.5.80.0050.02216.02
5.5.70.0090.02115.99
5.5.60.0070.02315.74
5.5.50.0130.01515.90
5.5.40.0000.02716.12
5.5.30.0070.03516.00
5.5.20.0030.02515.96
5.5.10.0050.02515.96
5.5.00.0030.02315.97
5.4.450.0050.03515.65
5.4.440.0070.04015.48
5.4.430.0050.04015.64
5.4.420.0070.02315.52
5.4.410.0070.02215.42
5.4.400.0070.04015.08
5.4.390.0000.02515.24
5.4.380.0020.03515.22
5.4.370.0090.02315.24
5.4.360.0120.03215.31
5.4.350.0050.02715.17
5.4.340.0050.04415.24
5.4.330.0040.00411.26
5.4.320.0030.04315.21
5.4.310.0080.04115.38
5.4.300.0080.01815.35
5.4.290.0020.02715.05
5.4.280.0020.02215.32
5.4.270.0050.02215.36
5.4.260.0020.02515.30
5.4.250.0070.02015.09
5.4.240.0050.02215.22
5.4.230.0100.02215.14
5.4.220.0050.02315.29
5.4.210.0020.02515.29
5.4.200.0060.01815.11
5.4.190.0020.02315.34
5.4.180.0030.02415.18
5.4.170.0100.01715.38
5.4.160.0080.01715.25
5.4.150.0030.02315.28
5.4.140.0020.02413.78
5.4.130.0020.02313.88
5.4.120.0080.01814.15
5.4.110.0050.02014.09
5.4.100.0020.02413.94
5.4.90.0030.02214.09
5.4.80.0050.01814.03
5.4.70.0000.02413.86
5.4.60.0050.01913.95
5.4.50.0060.02313.98
5.4.40.0060.01913.83
5.4.30.0030.02014.09
5.4.20.0110.03714.07
5.4.10.0070.03314.03
5.4.00.0050.04413.66
5.3.290.0040.04312.94
5.3.280.0040.02012.64
5.3.270.0050.02012.89
5.3.260.0090.01512.92
5.3.250.0070.01712.78
5.3.240.0020.02412.86
5.3.230.0030.02312.91
5.3.220.0000.02412.84
5.3.210.0030.02112.82
5.3.200.0050.02012.82
5.3.190.0050.02112.83
5.3.180.0030.02312.79
5.3.170.0000.02312.89
5.3.160.0010.02312.69
5.3.150.0020.02312.89
5.3.140.0050.02212.83
5.3.130.0030.02312.86
5.3.120.0050.02512.73
5.3.110.0050.03412.71
5.3.100.0100.03012.47
5.3.90.0120.03712.47
5.3.80.0050.04112.62
5.3.70.0040.02812.56
5.3.60.0060.03612.39
5.3.50.0010.02512.60
5.3.40.0030.04212.45
5.3.30.0030.02612.48
5.3.20.0050.03912.39
5.3.10.0050.04012.29
5.3.00.0060.03812.27
5.2.170.0100.06011.05
5.2.160.0070.02711.04
5.2.150.0030.04011.05
5.2.140.0000.04311.07
5.2.130.0070.05311.13
5.2.120.0100.05011.12
5.2.110.0070.04011.09
5.2.100.0070.04311.09
5.2.90.0030.06011.07
5.2.80.0100.03311.09
5.2.70.0070.06011.12
5.2.60.0070.05711.06
5.2.50.0000.04011.06
5.2.40.0000.06310.90
5.2.30.0030.06711.04
5.2.20.0030.05711.01
5.2.10.0000.04710.94
5.2.00.0030.04310.74
5.1.60.0000.04010.07
5.1.50.0030.0609.93
5.1.40.0000.0279.95
5.1.30.0000.03010.55
5.1.20.0000.03310.41
5.1.10.0100.04010.11
5.1.00.0000.03710.19
5.0.50.0030.0309.00
5.0.40.0030.0439.00
5.0.30.0000.0679.00
5.0.20.0100.0209.00
5.0.10.0000.0509.00
5.0.00.0100.0609.00
4.4.90.0030.0379.00
4.4.80.0070.0179.00
4.4.70.0000.0279.00
4.4.60.0000.0379.00
4.4.50.0030.0239.00
4.4.40.0000.0579.00
4.4.30.0070.0109.00
4.4.20.0000.0379.00
4.4.10.0000.0439.00
4.4.00.0030.0539.00
4.3.110.0000.0279.00
4.3.100.0070.0279.00
4.3.90.0030.0209.00
4.3.80.0030.0279.00
4.3.70.0030.0179.00
4.3.60.0000.0279.00
4.3.50.0100.0279.00
4.3.40.0030.0539.00
4.3.30.0000.0279.00
4.3.20.0000.0239.00
4.3.10.0000.0379.00
4.3.00.0070.0309.00