#7 menu.png107.92 KBandypost
#6 n1.png30.4 KBandypost
#6 n21.png84.73 KBandypost
#6 n23.png86.6 KBandypost
#6 n24.png84.67 KBandypost
#6 n22.png49.08 KBandypost
#6 n3.png113.95 KBandypost
#5 p1.png31.14 KBandypost
#5 p2.png92.63 KBandypost
#5 p3.png55.53 KBandypost
#5 p4.png130.6 KBandypost
#4 pm1.png30.97 KBandypost
#4 pm2.png51.14 KBandypost
#4 pm3.png116.01 KBandypost


OK debugged the really, really high memory usage in #drupal with Damz and Berdir. Query logging and having xdebug enabled accounts for some of it.

However, with both of those disabled, and no APC, the menu rebuild still takes around 7MB of memory on my system just for itself (out of a total of 32MB).

my stats for D7 + all modules enables + devel (admin/build/modules) windows box (php 5.2.9-2 + apache 2.0.63)

eaccelerator enabled:
Memory used at: devel_boot()=0.27 MB, devel_shutdown()=6.67 MB, PHP peak usage=7.25 MB.

eaccelerator disabled:
Memory used at: devel_boot()=1.82 MB, devel_shutdown()=21.63 MB, PHP peak usage=22.25 MB.

with return; at menu_rebuild

eaccelerator enabled:
first run Memory used at: devel_boot()=1.64 MB, devel_shutdown()=18.57 MB, PHP peak usage=19.25 MB.
next run and others Memory used at: devel_boot()=0.26 MB, devel_shutdown()=2.86 MB, PHP peak usage=3.5 MB.

eaccelerator disabled:
Memory used at: devel_boot()=1.83 MB, devel_shutdown()=17.78 MB, PHP peak usage=18.25 MB.

As I see menu_rebuild() eats near 3-4M for own data

Here the screens of zend profiler (all core enabled + eaccelerator)

pm(*).png - normal d7 core

p(*).png - menu_rebuild() excluded

new130.6 KB
new55.53 KB
new92.63 KB
new31.14 KB

This with menu_rebuild() skip

new113.95 KB
new49.08 KB
new84.67 KB
new86.6 KB
new84.73 KB
new30.4 KB

Another series but without eaccelerator

new107.92 KB

The most expensive menu_rebuild() because _menu_navigation_links_rebuild()

Status:Active» Fixed

We also changed menu_rebuild to do many smaller INSERT instead of one gigantic INSERT. Please reopen if there is a real outstanding issue.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.