3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait AssignHandler { public function __call($name, $args) { if(preg_match("#^set([A-Z][a-zA-Z0-9_]+?)$#", $name, $matches)) { $property = strtolower($matches[1]); if(property_exists($this, $property)) { $this->{$property} = $args[0] ?? null; } } return $this; } } class Post { use AssignHandler; public $title; public $content; } $post = new Post; $post->setTitle("Value") ->setContent("example content"); print_r($post);

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.00.0140.01020.04
8.4.150.0020.00014.05
8.4.140.0120.00917.69
8.4.130.0120.00917.84
8.4.120.0100.01022.50
8.4.110.0110.01018.00
8.4.100.0140.00717.97
8.4.90.0120.00520.64
8.4.80.0130.00618.88
8.4.70.0150.00518.05
8.4.60.0130.00720.37
8.4.50.0110.00920.38
8.4.40.0160.00317.82
8.4.30.0030.00617.84
8.4.20.0120.00919.71
8.4.10.0070.01419.86
8.3.280.0020.00014.05
8.3.270.0090.01216.75
8.3.260.0080.00416.71
8.3.250.0130.00517.13
8.3.240.0120.00716.87
8.3.230.0100.00916.67
8.3.220.0040.00318.88
8.3.210.0030.00416.55
8.3.200.0060.00216.64
8.3.190.0040.00418.82
8.3.180.0120.00816.47
8.3.170.0130.00619.06
8.3.160.0070.01117.31
8.3.150.0100.01019.09
8.3.140.0110.01116.83
8.3.130.0190.00316.87
8.3.120.0000.01020.91
8.3.110.0090.00020.94
8.3.100.0080.00816.38
8.3.90.0000.00818.32
8.3.80.0080.00419.36
8.3.70.0150.00316.63
8.3.60.0100.01018.30
8.3.50.0130.00517.42
8.3.40.0110.00718.85
8.3.30.0070.00718.98
8.3.20.0040.00420.34
8.3.10.0000.00822.04
8.3.00.0000.00721.90
8.2.290.0130.00616.95
8.2.280.0100.00918.65
8.2.270.0040.01517.34
8.2.260.0090.00616.50
8.2.250.0090.00017.11
8.2.240.0060.00316.72
8.2.230.0040.00422.58
8.2.220.0000.00824.06
8.2.210.0140.00326.77
8.2.200.0000.00916.75
8.2.190.0090.00917.00
8.2.180.0170.00316.88
8.2.170.0110.00722.96
8.2.160.0110.00422.04
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0090.00021.05
8.2.120.0080.00026.35
8.2.110.0030.00722.24
8.2.100.0090.00319.38
8.2.90.0000.00818.03
8.2.80.0080.00017.97
8.2.70.0040.00418.04
8.2.60.0040.00418.16
8.2.50.0040.00418.10
8.2.40.0030.00620.65
8.2.30.0060.00321.18
8.2.20.0000.00718.18
8.2.10.0040.00418.07
8.2.00.0040.00418.02
8.1.330.0130.00616.17
8.1.320.0090.01116.23
8.1.310.0170.00018.48
8.1.300.0110.00416.88
8.1.290.0060.00318.88
8.1.280.0110.01125.92
8.1.270.0110.00420.60
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0110.00020.59
8.1.230.0060.00622.75
8.1.220.0000.00719.22
8.1.210.0030.00618.77
8.1.200.0030.00717.48
8.1.190.0030.00617.35
8.1.180.0030.00518.10
8.1.170.0030.00518.77
8.1.160.0040.00418.96
8.1.150.0070.00020.16
8.1.140.0040.00417.69
8.1.130.0000.00720.75
8.1.120.0080.00017.50
8.1.110.0000.00717.57
8.1.100.0070.00317.60
8.1.90.0050.00317.54
8.1.80.0000.00817.50
8.1.70.0000.00717.52
8.1.60.0000.00817.58
8.1.50.0030.00517.64
8.1.40.0050.00317.55
8.1.30.0030.00617.70
8.1.20.0000.00717.70
8.1.10.0040.00417.64
8.1.00.0060.00617.61
8.0.300.0000.00721.66
8.0.290.0050.00316.75
8.0.280.0040.00418.40
8.0.270.0000.00717.28
8.0.260.0030.00318.50
8.0.250.0000.00717.15
8.0.240.0080.00017.09
8.0.230.0070.00017.14
8.0.220.0030.00317.07
8.0.210.0040.00416.93
8.0.200.0000.00717.09
8.0.190.0080.00017.16
8.0.180.0040.00416.95
8.0.170.0030.00316.96
8.0.160.0000.00917.10
8.0.150.0040.00417.05
8.0.140.0000.00716.96
8.0.130.0000.00613.42
8.0.120.0040.00417.05
8.0.110.0040.00417.13
8.0.100.0040.00417.03
8.0.90.0040.00417.02
8.0.80.0060.00917.02
8.0.70.0040.00416.92
8.0.60.0050.00217.02
8.0.50.0040.00417.08
8.0.30.0080.01117.43
8.0.20.0130.00817.41
8.0.10.0070.00017.23
8.0.00.0070.01116.76
7.4.330.0000.00415.55
7.4.320.0030.00316.74
7.4.300.0060.00016.72
7.4.290.0030.00316.81
7.4.280.0030.00616.70
7.4.270.0000.00816.81
7.4.260.0000.01116.69
7.4.250.0040.00416.82
7.4.240.0070.00016.73
7.4.230.0070.00016.93
7.4.220.0120.01516.73
7.4.210.0120.00316.76
7.4.200.0070.00016.84
7.4.160.0080.00816.88
7.4.150.0090.00917.40
7.4.140.0100.00817.86
7.4.130.0090.01016.50
7.4.120.0110.00916.74
7.4.110.0100.00716.67
7.4.100.0070.01016.46
7.4.90.0100.00616.78
7.4.80.0120.00919.39
7.4.70.0160.00316.77
7.4.60.0070.01416.43
7.4.50.0050.00516.51
7.4.40.0040.01616.72
7.4.30.0040.01416.65
7.4.00.0090.00615.05
7.3.330.0050.00013.48
7.3.320.0050.00013.32
7.3.310.0040.00416.37
7.3.300.0030.00316.47
7.3.290.0070.00916.45
7.3.280.0070.01116.50
7.3.270.0100.00717.40
7.3.260.0150.00616.80
7.3.250.0110.00816.74
7.3.240.0100.00916.56
7.3.230.0070.01116.56
7.3.210.0090.00916.52
7.3.200.0140.00316.57
7.3.190.0060.00916.65
7.3.180.0100.00616.77
7.3.170.0130.00316.80
7.3.160.0120.00616.79
7.3.10.0040.00716.72
7.3.00.0070.00716.58
7.2.330.0040.01316.71
7.2.320.0030.01316.66
7.2.310.0070.01016.99
7.2.300.0100.01016.90
7.2.290.0090.00916.62
7.2.130.0110.00517.24
7.2.120.0090.00317.00
7.2.110.0090.00317.18
7.2.100.0040.01217.28
7.2.90.0030.01017.10
7.2.80.0140.00317.02
7.2.70.0100.00317.14
7.2.60.0050.00817.01
7.2.50.0030.01317.15
7.2.40.0130.00317.35
7.2.30.0060.00617.18
7.2.20.0030.01017.22
7.2.10.0000.01417.35
7.2.00.0040.00717.17
7.1.250.0070.00716.16
7.1.200.0000.01215.97
7.1.100.0000.01218.45
7.1.90.0070.00718.60
7.1.80.0080.00418.74
7.1.70.0040.00717.28
7.1.60.0180.00735.10
7.1.50.0180.01135.09
7.1.40.0130.01334.93
7.1.30.0140.01134.91
7.1.20.0180.00634.72
7.1.10.0060.00616.97
7.1.00.0000.01217.20
7.0.240.0080.00418.22
7.0.230.0070.00717.73
7.0.220.0040.00817.69
7.0.210.0040.00816.84
7.0.200.0000.01117.03
7.0.190.0080.00416.76
7.0.180.0060.00616.42
7.0.170.0060.00616.54
7.0.160.0030.00916.42
7.0.150.0030.00916.44
7.0.140.0030.01016.66
7.0.130.0060.00916.77
7.0.120.0060.00816.89
7.0.110.0000.01216.46
7.0.100.0070.01016.55
7.0.90.0030.00916.64
7.0.80.0060.00616.50
7.0.70.0080.00416.55
7.0.60.0040.00816.44
7.0.50.0030.01516.31
7.0.40.0000.01316.64
7.0.30.0090.00316.61
7.0.20.0030.00916.62
7.0.10.0040.00816.82
7.0.00.0030.00916.66

preferences:
164.22 ms | 403 KiB | 5 Q