3v4l.org

run code in 300+ PHP versions simultaneously
<?php $pass = str_repeat('a', 1024 * 512); $pass . 'x'; echo memory_get_peak_usage(), "\n", memory_get_peak_usage()/(1024*1024) . 'MB';
Output for 8.2.0 - 8.2.17, 8.3.0 - 8.3.4
1443248 1.3763885498047MB
Output for 8.1.0 - 8.1.27
1443560 1.3766860961914MB
Output for 8.0.0 - 8.0.30
1443096 1.3762435913086MB
Output for 7.4.0 - 7.4.33
1443400 1.3765335083008MB
Output for 7.3.0 - 7.3.33
1443320 1.3764572143555MB
Output for 7.2.0 - 7.2.33
1439472 1.3727874755859MB
Output for 7.0.0 - 7.0.33, 7.1.0 - 7.1.33
1402864 1.3378753662109MB
Output for 5.5.0 - 5.5.38, 5.6.0 - 5.6.38
1266376 1.2077102661133MB
Output for 5.4.10 - 5.4.45
1266840 1.2081527709961MB
Output for 5.4.0 - 5.4.9
1266312 1.207649230957MB
Output for 5.3.11 - 5.3.29
1669360 1.5920257568359MB
Output for 5.3.0 - 5.3.10
1669056 1.5917358398438MB
Output for 5.2.10 - 5.2.17
1126432 1.0742492675781MB
Output for 5.2.7 - 5.2.9
1126464 1.0742797851562MB
Output for 5.2.3 - 5.2.6
1126784 1.0745849609375MB
Output for 5.2.1 - 5.2.2
1124840 1.0727310180664MB
Output for 5.0.0 - 5.0.5, 5.1.0 - 5.1.6, 5.2.0
Fatal error: Call to undefined function memory_get_peak_usage() in /in/8mkd4 on line 6
Process exited with code 255.
Output for 4.4.5 - 4.4.9
Fatal error: Call to undefined function: memory_get_peak_usage() in /in/8mkd4 on line 6
Process exited with code 255.
Output for 4.3.2 - 4.3.11, 4.4.0 - 4.4.4
Fatal error: Call to undefined function: memory_get_peak_usage() in /in/8mkd4 on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Call to undefined function: memory_get_peak_usage() in /in/8mkd4 on line 6

preferences:
237.69 ms | 401 KiB | 448 Q