3v4l.org

run code in 300+ PHP versions simultaneously
<?php assert_options(ASSERT_ACTIVE, 1); class foo { public $foo = 1; function as_string() { assert('$this->foo == 1'); } function as_expr() { assert($this->foo == 1); } } $foo = new foo(); $foo->as_expr(); $foo->as_string();

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.0100.01016.75
8.3.50.0080.01021.03
8.3.40.0120.00318.61
8.3.30.0040.01118.54
8.3.20.0040.00420.16
8.3.10.0050.00321.89
8.3.00.0070.00020.16
8.2.180.0130.00916.75
8.2.170.0120.00322.96
8.2.160.0000.01420.47
8.2.150.0050.00324.18
8.2.140.0050.00324.66
8.2.130.0030.00726.16
8.2.120.0090.00017.49
8.2.110.0030.00621.06
8.2.100.0090.00317.72
8.2.90.0040.00417.81
8.2.80.0040.00717.97
8.2.70.0050.00317.50
8.2.60.0000.00817.79
8.2.50.0000.00818.07
8.2.40.0060.00619.27
8.2.30.0000.00722.33
8.2.20.0040.00417.59
8.2.10.0000.00717.89
8.2.00.0040.00417.89
8.1.280.0090.00625.92
8.1.270.0060.00923.69
8.1.260.0000.00726.35
8.1.250.0050.00228.09
8.1.240.0100.00021.17
8.1.230.0110.00020.85
8.1.220.0060.00317.74
8.1.210.0000.00918.97
8.1.200.0000.01017.25
8.1.190.0080.00017.35
8.1.180.0060.00318.10
8.1.170.0000.00818.61
8.1.160.0050.00222.06
8.1.150.0040.00418.88
8.1.140.0050.00317.46
8.1.130.0030.00317.62
8.1.120.0000.00717.37
8.1.110.0040.00417.34
8.1.100.0040.00317.37
8.1.90.0000.00717.45
8.1.80.0040.00417.43
8.1.70.0050.00217.43
8.1.60.0040.00417.54
8.1.50.0030.00617.58
8.1.40.0040.00417.48
8.1.30.0050.00317.59
8.1.20.0030.00617.70
8.1.10.0000.00817.55
8.1.00.0040.00417.44
8.0.300.0000.00719.91
8.0.290.0000.00716.63
8.0.280.0000.00718.37
8.0.270.0080.00017.25
8.0.260.0030.00317.13
8.0.250.0000.00817.02
8.0.240.0030.00316.82
8.0.230.0030.00316.92
8.0.220.0030.00316.93
8.0.210.0000.00716.85
8.0.200.0000.00716.92
8.0.190.0060.00616.92
8.0.180.0050.00316.94
8.0.170.0040.00416.96
8.0.160.0000.00716.94
8.0.150.0040.00416.96
8.0.140.0040.00416.75
8.0.130.0000.00613.38
8.0.120.0030.00516.95
8.0.110.0070.00016.94
8.0.100.0030.00517.01
8.0.90.0000.00716.92
8.0.80.0100.01016.84
8.0.70.0000.00716.83
8.0.60.0040.00416.97
8.0.50.0050.00316.75
8.0.30.0090.01116.93
8.0.20.0090.01017.40
8.0.10.0000.00716.88
8.0.00.0110.00616.78
7.4.330.0050.00015.08
7.4.320.0070.00016.63
7.4.300.0000.00616.61
7.4.290.0030.00516.59
7.4.280.0030.00816.59
7.4.270.0030.00316.60
7.4.260.0000.00716.62
7.4.250.0000.00716.56
7.4.240.0030.00316.54
7.4.230.0000.00816.51
7.4.220.0090.00916.44
7.4.210.0070.01116.69
7.4.200.0050.00216.39
7.4.160.0090.00916.49
7.4.150.0100.00717.40
7.4.140.0090.01117.86
7.4.130.0130.00516.50
7.4.120.0060.01216.44
7.4.110.0100.01016.60
7.4.100.0060.01216.57
7.4.90.0160.00016.43
7.4.80.0110.00619.39
7.4.70.0090.00616.53
7.4.60.0140.01116.36
7.4.50.0030.00516.36
7.4.40.0120.00616.56
7.4.30.0100.01016.61
7.4.00.0140.00314.98
7.3.330.0060.00013.29
7.3.320.0030.00313.32
7.3.310.0040.00416.22
7.3.300.0000.00716.32
7.3.290.0070.00716.37
7.3.280.0110.00716.33
7.3.270.0150.00417.40
7.3.260.0090.00916.27
7.3.250.0080.00916.34
7.3.240.0090.00916.44
7.3.230.0150.00316.39
7.3.210.0130.00316.46
7.3.200.0100.00716.34
7.3.190.0080.00816.36
7.3.180.0170.00516.57
7.3.170.0130.01016.48
7.3.160.0060.01016.50
7.3.10.0060.00616.33
7.3.00.0030.01016.34
7.2.330.0090.00916.54
7.2.320.0060.01216.48
7.2.310.0130.01016.37
7.2.300.0090.00816.36
7.2.290.0070.01416.47
7.2.130.0070.00716.46
7.2.120.0060.01316.51
7.2.110.0110.00716.68
7.2.100.0070.00716.27
7.2.90.0200.00716.50
7.2.80.0110.00616.43
7.2.70.0140.00616.39
7.2.60.0020.01316.63
7.2.50.0070.01016.27
7.2.40.0090.00916.73
7.2.30.0000.01116.70
7.2.20.0030.01016.70
7.2.10.0060.00616.52
7.2.00.0090.00318.10
7.1.250.0120.00615.54
7.1.200.0040.00715.73
7.1.100.0000.01118.21
7.1.70.0030.00517.11
7.1.60.0160.00919.14
7.1.50.0160.01334.73
7.1.00.0030.07722.45
7.0.200.0000.00716.68
7.0.60.0100.08319.95
7.0.50.0070.10317.73
7.0.40.0030.04720.23
7.0.30.0230.04320.21
7.0.20.0370.06720.23
7.0.10.0070.08020.05
7.0.00.0000.06320.07
5.6.280.0070.05021.14
5.6.210.0200.06020.75
5.6.200.0070.08018.12
5.6.190.0000.07720.61
5.6.180.0300.05720.65
5.6.170.0230.04720.39
5.6.160.0070.08320.44
5.6.150.0070.08018.19
5.6.140.0130.04718.27
5.6.130.0070.08318.13
5.6.120.0070.07720.96
5.6.110.0100.08321.14
5.6.100.0070.08720.98
5.6.90.0070.09020.98
5.6.80.0030.08720.39
5.5.350.0070.08320.32
5.5.340.0100.07718.05
5.5.330.0030.07020.27
5.5.320.0030.08720.36
5.5.310.0230.08720.50
5.5.300.0030.04017.99
5.5.290.0070.03718.04
5.5.280.0030.04020.85
5.5.270.0030.04020.94
5.5.260.0030.04320.74
5.5.250.0070.07720.62
5.5.240.0200.07320.16
5.4.450.0900.06019.61
5.4.440.0970.05319.45
5.4.430.0900.06319.44
5.4.420.0870.05719.62
5.4.410.0830.05719.49
5.4.400.1000.04318.88
5.4.390.0870.05319.32
5.4.380.0800.05719.26
5.4.370.0970.06018.98
5.4.360.0830.05719.15
5.4.350.0830.05319.29
5.4.340.0800.06018.84
5.4.320.0830.05719.12
5.4.310.0830.05319.06
5.4.300.0970.04718.97
5.4.290.0800.05719.23
5.4.280.0930.04718.84
5.4.270.0870.05719.28
5.4.260.0900.05318.86
5.4.250.0830.05718.85
5.4.240.0870.05719.20
5.4.230.1000.04019.29
5.4.220.0930.04719.22
5.4.210.0830.05719.25
5.4.200.0930.04718.86
5.4.190.0870.05719.27
5.4.180.0900.04718.85
5.4.170.1030.05719.36
5.4.160.0900.05318.96
5.4.150.0930.05019.23
5.4.140.0870.05716.56
5.4.130.0900.05016.65
5.4.120.0930.04716.56
5.4.110.0830.05716.62
5.4.100.0900.04716.61
5.4.90.0930.04716.53
5.4.80.0900.04716.40
5.4.70.0000.05016.60
5.4.60.0030.07716.33
5.4.50.0000.03316.51
5.4.40.0200.07016.27
5.4.30.0230.07016.55
5.4.20.0230.06716.32

preferences:
58.23 ms | 401 KiB | 5 Q