3v4l.org

run code in 300+ PHP versions simultaneously
<?php class FooBar { public function __destruct() { var_dump('I\'m Dead!!!'); } } $foo = new FooBar(); $closure = (new ReflectionFunction('strlen'))->getClosure()->bindTo($foo); var_dump($closure('foo'), (new ReflectionFunction($closure))->getClosureScopeClass(), (new ReflectionFunction($closure))->getClosureThis());

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.0140.00418.17
8.3.50.0100.00822.07
8.3.40.0120.00318.75
8.3.30.0070.01018.95
8.3.20.0080.00020.38
8.3.10.0050.00323.56
8.3.00.0080.00019.05
8.2.180.0110.00716.35
8.2.170.0070.00722.96
8.2.160.0100.00320.32
8.2.150.0040.00424.18
8.2.140.0070.00024.66
8.2.130.0040.00426.16
8.2.120.0030.00620.79
8.2.110.0070.00322.11
8.2.100.0040.00817.66
8.2.90.0040.00419.17
8.2.80.0030.00617.97
8.2.70.0060.00617.38
8.2.60.0070.00317.80
8.2.50.0040.00418.07
8.2.40.0000.00820.97
8.2.30.0040.00418.08
8.2.20.0040.00417.54
8.2.10.0020.00517.99
8.2.00.0040.00417.63
8.1.280.0100.01025.92
8.1.270.0060.00323.92
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0060.00323.84
8.1.230.0070.00318.98
8.1.220.0000.00817.74
8.1.210.0080.00018.77
8.1.200.0080.00017.35
8.1.190.0040.00417.25
8.1.180.0000.00918.10
8.1.170.0060.00318.46
8.1.160.0040.00421.95
8.1.150.0070.00018.59
8.1.140.0030.00617.42
8.1.130.0000.00717.84
8.1.120.0050.00217.35
8.1.110.0050.00317.38
8.1.100.0050.00317.28
8.1.90.0040.00417.46
8.1.80.0000.00717.48
8.1.70.0030.00617.41
8.1.60.0040.00417.60
8.1.50.0030.00617.53
8.1.40.0040.00717.49
8.1.30.0000.00817.73
8.1.20.0000.00817.63
8.1.10.0040.00417.49
8.1.00.0050.00317.48
8.0.300.0050.00318.77
8.0.290.0040.00417.05
8.0.280.0030.00318.36
8.0.270.0000.00717.20
8.0.260.0060.00017.11
8.0.250.0040.00416.81
8.0.240.0040.00416.77
8.0.230.0040.00416.91
8.0.220.0030.00516.91
8.0.210.0000.00716.76
8.0.200.0040.00416.91
8.0.190.0000.00716.88
8.0.180.0040.00416.91
8.0.170.0040.00416.90
8.0.160.0040.00316.74
8.0.150.0000.00716.77
8.0.140.0070.00016.85
8.0.130.0000.00613.25
8.0.120.0050.00216.86
8.0.110.0000.00716.73
8.0.100.0070.00016.71
8.0.90.0000.00816.67
8.0.80.0060.00916.88
8.0.70.0040.00416.68
8.0.60.0040.00416.71
8.0.50.0000.00716.71
8.0.30.0150.00517.21
8.0.20.0110.00817.40
8.0.10.0070.00016.91
8.0.00.0030.01416.62
7.4.330.0030.00315.00
7.4.320.0030.00316.38
7.4.300.0060.00016.57
7.4.290.0040.00416.66
7.4.280.0060.00216.60
7.4.270.0030.00316.45
7.4.260.0040.00316.48
7.4.250.0040.00416.53
7.4.240.0060.00216.54
7.4.230.0000.00716.64
7.4.220.0030.01416.72
7.4.210.0030.01216.59
7.4.200.0000.00716.55
7.4.190.0030.00316.47
7.4.160.0130.00316.70
7.4.150.0100.01017.40
7.4.140.0080.01017.86
7.4.130.0060.01016.52
7.4.120.0120.00716.46
7.4.110.0150.00716.30
7.4.100.0080.01216.50
7.4.90.0070.01016.55
7.4.80.0070.01119.39
7.4.70.0130.00316.41
7.4.60.0120.00416.23
7.4.50.0030.00316.54
7.4.40.0080.00816.73
7.4.30.0080.01216.67
7.4.00.0140.00414.99
7.3.330.0020.00213.25
7.3.320.0050.00013.09
7.3.310.0040.00416.27
7.3.300.0030.00316.24
7.3.290.0100.00316.26
7.3.280.0090.00716.24
7.3.270.0100.01217.40
7.3.260.0150.00916.21
7.3.250.0120.00616.31
7.3.240.0100.00716.45
7.3.230.0080.01216.39
7.3.210.0100.00716.13
7.3.200.0130.00419.39
7.3.190.0130.00616.19
7.3.180.0080.00816.41
7.3.170.0100.00716.27
7.3.160.0100.01016.32
7.3.120.0100.00614.68
7.2.330.0110.01116.23
7.2.320.0120.00916.64
7.2.310.0120.00616.36
7.2.300.0000.01816.43
7.2.290.0090.00916.71
7.2.60.0050.00816.96
7.1.200.0070.00715.56
7.1.70.0030.00516.80
7.1.60.0150.00619.70
7.1.50.0090.00416.47
7.1.00.0030.07722.33
7.0.200.0130.00816.10
7.0.140.0030.07321.93
7.0.60.0070.08319.93
7.0.50.0000.05317.84
7.0.40.0070.08720.30
7.0.30.0330.07020.16
7.0.20.0300.04720.11
7.0.10.0070.08320.22
7.0.00.0030.09320.33
5.6.280.0030.07321.13
5.6.210.0070.08320.65
5.6.200.0130.08018.27
5.6.190.0070.06320.54
5.6.180.0230.07720.39
5.6.170.0370.07720.61
5.6.160.0100.07720.39
5.6.150.0100.08018.16
5.6.140.0070.06018.17
5.6.130.0030.08718.21
5.6.120.0130.04721.05
5.6.110.0130.08020.97
5.6.100.0030.08021.00
5.6.90.0100.08020.97
5.6.80.0070.08020.39
5.5.350.0070.07320.43
5.5.340.0170.07017.95
5.5.330.0070.05020.40
5.5.320.0330.07720.46
5.5.310.0170.04320.35
5.5.300.0030.08017.98
5.5.290.0100.08317.98
5.5.280.0070.04020.88
5.5.270.0100.07020.73
5.5.260.0070.07720.80
5.5.250.0100.04720.46
5.5.240.4300.03720.27
5.4.450.0400.04719.31
5.4.440.0300.04319.16
5.4.430.0230.04319.20
5.4.420.0170.04719.38
5.4.410.0070.05019.35
5.4.400.0200.03319.25
5.4.390.0130.05319.22
5.4.380.0200.04718.53
5.4.370.0230.04318.55
5.4.360.0200.04718.84
5.4.350.0000.07018.79
5.4.340.0170.07018.79
5.4.320.0070.03512.50
5.4.310.0100.03812.49
5.4.300.0100.07812.50
5.4.290.0220.09112.50
5.4.280.0180.06612.39
5.4.270.0190.05912.39
5.4.260.0160.11012.39
5.4.250.0070.05612.40
5.4.240.0160.10412.39
5.4.230.0100.09612.39
5.4.220.0130.06512.39
5.4.210.0070.05912.39
5.4.200.0120.04312.38
5.4.190.0090.04812.38
5.4.180.0110.04312.38
5.4.170.0150.04612.39
5.4.160.0070.04112.39
5.4.150.0110.04012.39
5.4.140.0090.04012.07
5.4.130.0110.03512.06
5.4.120.0190.07812.02
5.4.110.0080.05412.01
5.4.100.0080.04412.01
5.4.90.0140.06812.01
5.4.80.0130.04912.01
5.4.70.0040.05812.00
5.4.60.0140.06012.01
5.4.50.0180.07112.01
5.4.40.0160.06212.00
5.4.30.0130.08112.00
5.4.20.0200.05112.00
5.4.10.0160.08011.99
5.4.00.0150.06711.48
5.3.290.0050.04012.80
5.3.280.0170.07612.71
5.3.270.0110.07012.73
5.3.260.0150.12212.72
5.3.250.0140.07012.72
5.3.240.0130.07312.72
5.3.230.0160.07012.71
5.3.220.0090.04812.68
5.3.210.0090.05112.68
5.3.200.0070.05012.68
5.3.190.0220.07012.68
5.3.180.0040.04612.68
5.3.170.0170.05712.66
5.3.160.0100.03912.67
5.3.150.0170.08312.68
5.3.140.0120.08312.66
5.3.130.0250.10912.66
5.3.120.0120.04412.66
5.3.110.0130.08512.66
5.3.100.0190.07912.13
5.3.90.0410.16712.10
5.3.80.0070.06712.09
5.3.70.0060.04512.09
5.3.60.0090.04712.08
5.3.50.0090.04712.03
5.3.40.0060.06112.02
5.3.30.0040.04011.98
5.3.20.0070.04011.76
5.3.10.0100.03611.73
5.3.00.0060.04211.72
5.2.170.0060.0329.22
5.2.160.0060.0309.22
5.2.150.0040.0349.22
5.2.140.0050.0329.21
5.2.130.0070.0289.18
5.2.120.0030.0329.18
5.2.110.0040.0339.18
5.2.100.0080.0339.18
5.2.90.0060.0339.18
5.2.80.0080.0309.17
5.2.70.0080.0449.17
5.2.60.0080.0429.13
5.2.50.0080.0369.10
5.2.40.0060.0329.07
5.2.30.0090.0359.05
5.2.20.0140.0589.04
5.2.10.0100.0268.94
5.2.00.0080.0298.80
5.1.60.0060.0258.09
5.1.50.0040.0278.09
5.1.40.0030.0278.07
5.1.30.0080.0248.42
5.1.20.0050.0298.44
5.1.10.0060.0278.17
5.1.00.0080.0268.17
5.0.50.0070.0226.64
5.0.40.0050.0206.51
5.0.30.0020.0396.31
5.0.20.0060.0286.28
5.0.10.0080.0216.26
5.0.00.0040.0356.25
4.4.90.0050.0204.78
4.4.80.0040.0204.75
4.4.70.0040.0174.76
4.4.60.0020.0174.75
4.4.50.0030.0164.77
4.4.40.0030.0264.71
4.4.30.0040.0154.76
4.4.20.0070.0124.84
4.4.10.0030.0164.85
4.4.00.0020.0264.76
4.3.110.0040.0144.67
4.3.100.0030.0154.66
4.3.90.0050.0134.63
4.3.80.0040.0254.58
4.3.70.0040.0144.63
4.3.60.0040.0144.63
4.3.50.0060.0134.63
4.3.40.0030.0334.54
4.3.30.0000.0183.30
4.3.20.0020.0173.28
4.3.10.0010.0203.23
4.3.00.0030.01716.92

preferences:
47.87 ms | 401 KiB | 5 Q