3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace NS { class A { function test() { echo 'test'; } } } namespace NS2 { class_alias( 'NS\A', 'B' ); } namespace NS3 { class MyClass extends \B { function test() { echo 'test under MyClass'; } } } function foo (B $f) { $f->test(); } foo (new MyClass);

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)
5.4.320.0070.07718.89
5.4.310.0070.04319.15
5.4.300.0100.06719.13
5.4.290.0030.04319.19
5.4.280.0070.04718.98
5.4.270.0100.07019.08
5.4.260.0030.07319.23
5.4.250.0000.05318.94
5.4.240.0100.07018.94
5.4.230.0000.08319.19
5.4.220.0000.05018.98
5.4.210.0000.07319.05
5.4.200.0030.08019.05
5.4.190.0070.04319.30
5.4.180.0030.07319.17
5.4.170.0070.07318.94
5.4.160.0000.07319.15
5.4.150.0030.04718.96
5.4.140.0000.07316.43
5.4.130.0030.06016.39
5.4.120.0070.06716.37
5.4.110.0030.07316.60
5.4.100.0070.05716.46
5.4.90.0030.07016.59
5.4.80.0100.05016.51
5.4.70.0030.07016.30
5.4.60.0000.07316.35
5.4.50.0030.05316.42
5.4.40.0000.07316.53
5.4.30.0000.06716.30
5.4.20.0070.04316.53
5.4.10.0030.05716.52
5.4.00.0030.04715.83
5.3.290.0070.04314.66
5.3.280.0030.07014.59
5.3.270.0170.03714.61
5.3.260.0030.07714.79
5.3.250.0000.07314.82
5.3.240.0070.07714.62
5.3.230.0070.06314.59
5.3.220.0030.07714.57
5.3.210.0000.08014.69
5.3.200.0030.06714.49
5.3.190.0070.04314.73
5.3.180.0030.07714.56
5.3.170.0070.05014.56
5.3.160.0000.07714.57
5.3.150.0030.06314.54
5.3.140.0030.07014.63
5.3.130.0000.07314.64
5.3.120.0000.07314.71
5.3.110.0100.07314.67
5.3.100.0000.04314.12
5.3.90.0000.04313.95
5.3.80.0000.03713.95
5.3.70.0030.03314.09
5.3.60.0000.03714.05
5.3.50.0030.03714.00
5.3.40.0030.03313.87
5.3.30.0000.04013.88
5.3.20.0030.03013.73
5.3.10.0000.03713.74
5.3.00.0070.03013.73
5.2.170.0030.03712.01
5.2.160.0070.02312.01
5.2.150.0030.02712.01
5.2.140.0030.03012.01
5.2.130.0000.03012.01
5.2.120.0000.02712.01
5.2.110.0000.02712.01
5.2.100.0000.03012.01
5.2.90.0000.02712.01
5.2.80.0030.02712.01
5.2.70.0070.02312.01
5.2.60.0030.02712.01
5.2.50.0000.03012.01
5.2.40.0030.02712.01
5.2.30.0000.03312.01
5.2.20.0000.02712.01
5.2.10.0000.02712.01
5.2.00.0000.03012.01
5.1.60.0000.02312.01
5.1.50.0000.02712.01
5.1.40.0000.02312.01
5.1.30.0000.02712.01
5.1.20.0000.02712.01
5.1.10.0030.02312.01
5.1.00.0000.02312.01
5.0.50.0000.02012.01
5.0.40.0000.02012.01
5.0.30.0000.03312.01
5.0.20.0000.01712.01
5.0.10.0000.02012.01
5.0.00.0000.03012.01
4.4.90.0000.03312.01
4.4.80.0000.01312.01
4.4.70.0000.01312.01
4.4.60.0030.01312.01
4.4.50.0000.01712.01
4.4.40.0030.02012.01
4.4.30.0000.01312.01
4.4.20.0000.01312.01
4.4.10.0000.01712.01
4.4.00.0000.02312.01
4.3.110.0000.01312.01
4.3.100.0000.01312.01
4.3.90.0030.01312.01
4.3.80.0000.02312.01
4.3.70.0030.01312.01
4.3.60.0030.01312.01
4.3.50.0030.01312.01
4.3.40.0000.02312.01
4.3.30.0000.01712.01
4.3.20.0000.01712.01
4.3.10.0000.01312.01
4.3.00.0000.01312.01

preferences:
140.54 ms | 1394 KiB | 7 Q