run code in 150+ php & hhvm versions
Bugs & Features
<?php class A { public $_field = "abcdefghijklmnopqrstuvwxyz"; public function __get($name) { echo 'method called' . PHP_EOL; die; } } class B { public $_field = "abcdefghijklmnopqrstuvwxyz"; } $a = new A; $start = microtime(true); for ($i = 0; $i < 100000; $i++) $field = $a->_field; $time_taken = microtime(true) - $start; echo 'With get: ' . $time_taken . 's' . PHP_EOL; $b = new B; $start = microtime(true); for ($i = 0; $i < 100000; $i++) $field = $b->_field; $time_taken = microtime(true) - $start; echo 'Without get: ' . $time_taken . 's' . PHP_EOL;
Output for 7.1.0RC3
With get: 0.0026130676269531s Without get: 0.0027179718017578s
Output for 7.1.0alpha1
With get: 0.0024809837341309s Without get: 0.0024468898773193s
Output for 7.0.12
With get: 0.0033028125762939s Without get: 0.0030908584594727s
Output for 7.0.6
With get: 0.0027890205383301s Without get: 0.0026161670684814s
Output for 7.0.5
With get: 0.0022039413452148s Without get: 0.0017061233520508s
Output for 7.0.4
With get: 0.0023469924926758s Without get: 0.0022330284118652s
Output for 7.0.3
With get: 0.0022430419921875s Without get: 0.0020170211791992s
Output for 7.0.2
With get: 0.0017101764678955s Without get: 0.0016908645629883s
Output for 7.0.1
With get: 0.0017869472503662s Without get: 0.0017490386962891s
Output for 7.0.0
With get: 0.0018720626831055s Without get: 0.0018539428710938s
Output for hhvm-3.12.0
With get: 0.0075211524963379s Without get: 0.007390022277832s
Output for hhvm-3.10.0
With get: 0.0078189373016357s Without get: 0.0078167915344238s
Output for 5.6.21
With get: 0.0057811737060547s Without get: 0.0055999755859375s
Output for 5.6.20
With get: 0.0046560764312744s Without get: 0.0045490264892578s
Output for 5.6.19
With get: 0.0059280395507812s Without get: 0.005781888961792s
Output for 5.6.18
With get: 0.0044219493865967s Without get: 0.0043330192565918s
Output for 5.6.17
With get: 0.0041499137878418s Without get: 0.0040478706359863s
Output for 5.6.16
With get: 0.0041141510009766s Without get: 0.0043690204620361s
Output for 5.6.15
With get: 0.0039739608764648s Without get: 0.0039741992950439s
Output for 5.6.14
With get: 0.0040960311889648s Without get: 0.0045628547668457s
Output for 5.6.13
With get: 0.0041921138763428s Without get: 0.0041511058807373s
Output for 5.6.12
With get: 0.0040628910064697s Without get: 0.0040209293365479s
Output for 5.6.11
With get: 0.0045819282531738s Without get: 0.0045490264892578s
Output for 5.6.10
With get: 0.0039510726928711s Without get: 0.0039288997650146s
Output for 5.6.9
With get: 0.006242036819458s Without get: 0.0062119960784912s
Output for 5.6.8
With get: 0.0043368339538574s Without get: 0.0043079853057861s
Output for 5.6.7
With get: 0.0063049793243408s Without get: 0.0061919689178467s
Output for 5.6.6
With get: 0.006742000579834s Without get: 0.0066750049591064s
Output for 5.6.5
With get: 0.0058870315551758s Without get: 0.0058319568634033s
Output for 5.6.4
With get: 0.0054161548614502s Without get: 0.0052628517150879s
Output for 5.6.3
With get: 0.0058820247650146s Without get: 0.0058250427246094s
Output for 5.6.2
With get: 0.0063719749450684s Without get: 0.0061888694763184s
Output for 5.6.1
With get: 0.0066630840301514s Without get: 0.0066080093383789s
Output for 5.6.0
With get: 0.0064167976379395s Without get: 0.0062651634216309s
Output for 5.5.35
With get: 0.0046939849853516s Without get: 0.0047011375427246s
Output for 5.5.34
With get: 0.0062429904937744s Without get: 0.006213903427124s
Output for 5.5.33
With get: 0.0040090084075928s Without get: 0.0040919780731201s
Output for 5.5.32
With get: 0.0041251182556152s Without get: 0.0044801235198975s
Output for 5.5.31
With get: 0.0047929286956787s Without get: 0.004655122756958s
Output for 5.5.30
With get: 0.0042879581451416s Without get: 0.0042939186096191s
Output for 5.5.29
With get: 0.0044140815734863s Without get: 0.0046341419219971s
Output for 5.5.28
With get: 0.0042359828948975s Without get: 0.0039999485015869s
Output for 5.5.27
With get: 0.0040018558502197s Without get: 0.0040621757507324s
Output for 5.5.26
With get: 0.0059549808502197s Without get: 0.0059051513671875s
Output for 5.5.25
With get: 0.0065250396728516s Without get: 0.0062751770019531s
Output for 5.5.24
With get: 0.0041580200195312s Without get: 0.004194974899292s
Output for 5.5.23
With get: 0.0061931610107422s Without get: 0.0061008930206299s
Output for 5.5.22
With get: 0.0052809715270996s Without get: 0.0053250789642334s
Output for 5.5.21
With get: 0.0055978298187256s Without get: 0.0054640769958496s
Output for 5.5.20
With get: 0.0065958499908447s Without get: 0.0066521167755127s
Output for 5.5.19
With get: 0.0050919055938721s Without get: 0.0049049854278564s
Output for 5.5.18
With get: 0.0065619945526123s Without get: 0.00661301612854s
Output for 5.5.16
With get: 0.0070681571960449s Without get: 0.0068409442901611s
Output for 5.5.15
With get: 0.0068039894104004s Without get: 0.0064451694488525s
Output for 5.5.14
With get: 0.0054428577423096s Without get: 0.005457878112793s
Output for 5.5.13
With get: 0.0057070255279541s Without get: 0.0046470165252686s
Output for 5.5.12
With get: 0.0048530101776123s Without get: 0.004741907119751s
Output for 5.5.11
With get: 0.0066320896148682s Without get: 0.0064308643341064s
Output for 5.5.10
With get: 0.0059759616851807s Without get: 0.0059101581573486s
Output for 5.5.9
With get: 0.0060369968414307s Without get: 0.0056688785552979s
Output for 5.5.8
With get: 0.0071201324462891s Without get: 0.0074870586395264s
Output for 5.5.7
With get: 0.0053031444549561s Without get: 0.0052320957183838s
Output for 5.5.6
With get: 0.0049610137939453s Without get: 0.0048491954803467s
Output for 5.5.5
With get: 0.0068159103393555s Without get: 0.0068731307983398s
Output for 5.5.4
With get: 0.0054080486297607s Without get: 0.0054900646209717s
Output for 5.5.3
With get: 0.0068230628967285s Without get: 0.0066330432891846s
Output for 5.5.2
With get: 0.0054290294647217s Without get: 0.0053861141204834s
Output for 5.5.1
With get: 0.0068471431732178s Without get: 0.0059928894042969s
Output for 5.5.0
With get: 0.0064117908477783s Without get: 0.0062339305877686s
Output for 5.4.45
With get: 0.0040750503540039s Without get: 0.0042450428009033s
Output for 5.4.44
With get: 0.0041549205780029s Without get: 0.0043361186981201s
Output for 5.4.43
With get: 0.0042879581451416s Without get: 0.0041320323944092s
Output for 5.4.42
With get: 0.0043370723724365s Without get: 0.0044338703155518s
Output for 5.4.41
With get: 0.0071830749511719s Without get: 0.0080521106719971s
Output for 5.4.40
With get: 0.0044808387756348s Without get: 0.0049910545349121s
Output for 5.4.39
With get: 0.006525993347168s Without get: 0.0063750743865967s
Output for 5.4.38
With get: 0.0053868293762207s Without get: 0.0054678916931152s
Output for 5.4.37
With get: 0.0067729949951172s Without get: 0.0068681240081787s
Output for 5.4.36
With get: 0.0063979625701904s Without get: 0.0062520503997803s
Output for 5.4.35
With get: 0.0068390369415283s Without get: 0.0068979263305664s
Output for 5.4.34
With get: 0.0069801807403564s Without get: 0.0070459842681885s
Output for 5.4.32
With get: 0.0067429542541504s Without get: 0.0067260265350342s
Output for 5.4.31
With get: 0.0073709487915039s Without get: 0.0074520111083984s
Output for 5.4.30
With get: 0.0055608749389648s Without get: 0.0056259632110596s
Output for 5.4.29
With get: 0.0064411163330078s Without get: 0.0064780712127686s
Output for 5.4.28
With get: 0.0044898986816406s Without get: 0.0047190189361572s
Output for 5.4.27
With get: 0.0068058967590332s Without get: 0.0069220066070557s
Output for 5.4.26
With get: 0.0070769786834717s Without get: 0.0071060657501221s
Output for 5.4.25
With get: 0.005403995513916s Without get: 0.0055279731750488s
Output for 5.4.24
With get: 0.0066318511962891s Without get: 0.0067169666290283s
Output for 5.4.23
With get: 0.0068819522857666s Without get: 0.0069420337677002s
Output for 5.4.22
With get: 0.0063180923461914s Without get: 0.0059909820556641s
Output for 5.4.21
With get: 0.0058920383453369s Without get: 0.0061089992523193s
Output for 5.4.20
With get: 0.0059080123901367s Without get: 0.005918025970459s
Output for 5.4.19
With get: 0.0056560039520264s Without get: 0.0058450698852539s
Output for 5.4.18
With get: 0.00679612159729s Without get: 0.0072250366210938s
Output for 5.4.17
With get: 0.006756067276001s Without get: 0.0068230628967285s
Output for 5.4.16
With get: 0.0083858966827393s Without get: 0.0075538158416748s
Output for 5.4.15
With get: 0.0073750019073486s Without get: 0.0067541599273682s
Output for 5.4.14
With get: 0.0082390308380127s Without get: 0.006756067276001s
Output for 5.4.13
With get: 0.0069940090179443s Without get: 0.0066640377044678s
Output for 5.4.12
With get: 0.0055649280548096s Without get: 0.0056359767913818s
Output for 5.4.11
With get: 0.0054829120635986s Without get: 0.0055570602416992s
Output for 5.4.10
With get: 0.0061509609222412s Without get: 0.0064198970794678s
Output for 5.4.9
With get: 0.0055041313171387s Without get: 0.0053689479827881s
Output for 5.4.8
With get: 0.0072698593139648s Without get: 0.0070691108703613s
Output for 5.4.7
With get: 0.0064082145690918s Without get: 0.0063340663909912s
Output for 5.4.6
With get: 0.0062210559844971s Without get: 0.0061960220336914s
Output for 5.4.5
With get: 0.0064079761505127s Without get: 0.0067319869995117s
Output for 5.4.4
With get: 0.0060989856719971s Without get: 0.0058751106262207s
Output for 5.4.3
With get: 0.0069119930267334s Without get: 0.0069811344146729s
Output for 5.4.2
With get: 0.0061089992523193s Without get: 0.0059800148010254s
Output for 5.4.1
With get: 0.0073180198669434s Without get: 0.0071780681610107s
Output for 5.4.0
With get: 0.0071990489959717s Without get: 0.0067131519317627s
Output for 5.3.29
With get: 0.010281801223755s Without get: 0.010073900222778s
Output for 5.3.28
With get: 0.011023998260498s Without get: 0.010506868362427s
Output for 5.3.27
With get: 0.011608123779297s Without get: 0.011860132217407s
Output for 5.3.26
With get: 0.0066919326782227s Without get: 0.0067059993743896s
Output for 5.3.25
With get: 0.011317014694214s Without get: 0.010613203048706s
Output for 5.3.24
With get: 0.0095319747924805s Without get: 0.0091578960418701s
Output for 5.3.23
With get: 0.01085090637207s Without get: 0.0094220638275146s
Output for 5.3.22
With get: 0.011239051818848s Without get: 0.010493993759155s
Output for 5.3.21
With get: 0.012062072753906s Without get: 0.01152491569519s
Output for 5.3.20
With get: 0.011531829833984s Without get: 0.011088132858276s
Output for 5.3.19
With get: 0.0097858905792236s Without get: 0.0093679428100586s
Output for 5.3.18
With get: 0.0079231262207031s Without get: 0.0072638988494873s
Output for 5.3.17
With get: 0.0068130493164062s Without get: 0.0067639350891113s
Output for 5.3.16
With get: 0.010178089141846s Without get: 0.010366916656494s
Output for 5.3.15
With get: 0.0085399150848389s Without get: 0.0081331729888916s
Output for 5.3.14
With get: 0.0096039772033691s Without get: 0.0093498229980469s
Output for 5.3.13
With get: 0.010115146636963s Without get: 0.0096991062164307s
Output for 5.3.12
With get: 0.010207891464233s Without get: 0.0083010196685791s
Output for 5.3.11
With get: 0.0088431835174561s Without get: 0.0086150169372559s
Output for 5.3.10
With get: 0.010751008987427s Without get: 0.010217905044556s
Output for 5.3.9
With get: 0.0076930522918701s Without get: 0.0082199573516846s
Output for 5.3.8
With get: 0.011192798614502s Without get: 0.010434865951538s
Output for 5.3.7
With get: 0.0088908672332764s Without get: 0.0084471702575684s
Output for 5.3.6
With get: 0.010993003845215s Without get: 0.010716915130615s
Output for 5.3.5
With get: 0.0092368125915527s Without get: 0.0088448524475098s
Output for 5.3.4
With get: 0.011459112167358s Without get: 0.010993003845215s
Output for 5.3.3
With get: 0.013584852218628s Without get: 0.012248992919922s
Output for 5.3.2
With get: 0.011171817779541s Without get: 0.010879039764404s
Output for 5.3.1
With get: 0.011274814605713s Without get: 0.011021137237549s
Output for 5.3.0
With get: 0.0093891620635986s Without get: 0.0090749263763428s
Output for 5.2.17
With get: 0.015410184860229s Without get: 0.014381170272827s
Output for 5.2.16
With get: 0.01468300819397s Without get: 0.014082908630371s
Output for 5.2.15
With get: 0.016241073608398s Without get: 0.011666059494019s
Output for 5.2.14
With get: 0.015800952911377s Without get: 0.013636112213135s
Output for 5.2.13
With get: 0.015634775161743s Without get: 0.014252901077271s
Output for 5.2.12
With get: 0.016433000564575s Without get: 0.014619112014771s
Output for 5.2.11
With get: 0.014930009841919s Without get: 0.013910055160522s
Output for 5.2.10
With get: 0.015784978866577s Without get: 0.014854907989502s
Output for 5.2.9
With get: 0.012032032012939s Without get: 0.010503053665161s
Output for 5.2.8
With get: 0.016710042953491s Without get: 0.015053987503052s
Output for 5.2.7
With get: 0.015605926513672s Without get: 0.014046907424927s
Output for 5.2.6
With get: 0.017467021942139s Without get: 0.015895128250122s
Output for 5.2.5
With get: 0.011842966079712s Without get: 0.011278867721558s
Output for 5.2.4
With get: 0.015829086303711s Without get: 0.014506816864014s
Output for 5.2.3
With get: 0.01475191116333s Without get: 0.013788938522339s
Output for 5.2.2
With get: 0.013470888137817s Without get: 0.012682914733887s
Output for 5.2.1
With get: 0.012428045272827s Without get: 0.012021064758301s
Output for 5.2.0
With get: 0.014235019683838s Without get: 0.013638019561768s
Output for 5.1.6
With get: 0.015516042709351s Without get: 0.014445066452026s
Output for 5.1.5
With get: 0.014142036437988s Without get: 0.013348817825317s
Output for 5.1.4
With get: 0.015269994735718s Without get: 0.01422905921936s
Output for 5.1.3
With get: 0.014279127120972s Without get: 0.013423919677734s
Output for 5.1.2
With get: 0.016803026199341s Without get: 0.015068054199219s
Output for 5.1.1
With get: 0.015701055526733s Without get: 0.014816045761108s
Output for 5.1.0
With get: 0.014998912811279s Without get: 0.014024019241333s
Output for 5.0.5
With get: 0.029711008071899s Without get: 0.026313066482544s
Output for 5.0.4
With get: 0.032866954803467s Without get: 0.027627944946289s
Output for 5.0.3
With get: 0.027443885803223s Without get: 0.024552822113037s
Output for 5.0.2
With get: 0.032860994338989s Without get: 0.027918100357056s
Output for 5.0.1
Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/FV3A3 on line 24 With get: 0.030140161514282sPHP_EOL Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/FV3A3 on line 32 Without get: 0.026129961013794sPHP_EOL
Output for 5.0.0
Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/FV3A3 on line 24 With get: 0.028006076812744sPHP_EOL Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/FV3A3 on line 32 Without get: 0.025506019592285sPHP_EOL
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/FV3A3 on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1
Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/FV3A3 on line 5
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `T_OLD_FUNCTION' or `T_FUNCTION' or `T_VAR' or `'}'' in /in/FV3A3 on line 5
Process exited with code 255.