Eric Sandeen 089ceecc1e ext4: mark several more functions in mballoc.c as noinline
Ted noticed a stack-deep callchain through
writepages->ext4_mb_regular_allocator->ext4_mb_init_cache->submit_bh ...

With all the static functions in mballoc.c, gcc helpfully
inlines for us, and we get something like this:

ext4_mb_regular_allocator	(232 bytes stack)
	ext4_mb_init_cache	(232 bytes stack)
		submit_bh	(starts 464 deeper)

the 2 ext4 functions here get several others inlined; by telling
gcc not to inline them, we can save stack space for when we
head off into submit_bh land and associated block layer callchains.
The following noinlined functions are only called once, so this
won't impact any other callchains:

ext4_mb_regular_allocator 			(104) (was 232)
	ext4_mb_find_by_goal			 (56) (noinlined)
	ext4_mb_init_group			 (24) (noinlined)
		ext4_mb_init_cache		(136) (was 232)
			ext4_mb_generate_buddy	 (88) (noinlined)
			ext4_mb_generate_from_pa (40) (noinlined)
			submit_bh
	ext4_mb_simple_scan_group		 (24) (noinlined)
	ext4_mb_scan_aligned			 (56) (noinlined)
	ext4_mb_complex_scan_group		 (40) (noinlined)
	ext4_mb_try_best_found			 (24) (noinlined)

now when we head off into submit_bh() we're only 264 bytes deeper
in stack than when we entered ext4_mb_regular_allocator()
(vs. 464 bytes before).  Every 200 bytes helps.  :)

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2009-07-05 22:17:31 -04:00
..
2009-06-17 00:36:36 -04:00
2009-06-11 21:36:14 -04:00
2009-06-30 13:30:44 -07:00
2009-06-11 21:36:01 -04:00
2009-06-11 21:36:01 -04:00
2009-06-11 21:36:14 -04:00
2009-06-24 08:15:24 -04:00
2009-05-15 11:24:59 -05:00
2009-06-11 21:36:07 -04:00
2009-06-17 00:36:36 -04:00
2009-06-12 10:02:03 -05:00
2009-06-11 21:36:07 -04:00
2009-06-30 20:12:24 +02:00
2009-06-11 21:36:15 -04:00
2009-06-11 21:36:16 -04:00
2009-06-11 21:36:11 -04:00
2009-05-22 18:40:59 +10:00
2009-06-24 17:02:42 -04:00
2009-06-15 21:44:43 -07:00
2009-06-24 08:17:05 -04:00
2009-06-15 21:44:43 -07:00
2009-06-11 21:36:13 -04:00
2009-06-11 21:36:12 -04:00
2009-06-14 17:58:25 -07:00
2009-06-11 21:36:07 -04:00
2009-06-11 21:36:07 -04:00
2009-06-17 00:36:37 -04:00
2009-06-18 13:03:46 -07:00
2009-06-30 18:55:58 -07:00
2008-12-31 18:07:43 -05:00
2009-01-03 11:45:54 -08:00
2009-07-01 11:14:28 -07:00
2009-06-11 21:36:06 -04:00
2009-06-18 13:03:41 -07:00
2009-03-31 23:00:26 -04:00
2009-06-11 21:36:07 -04:00
2009-06-11 21:36:11 -04:00
2009-04-07 08:31:16 -07:00
2009-04-20 23:02:52 -04:00
2009-02-18 15:37:53 -08:00
2009-06-11 21:36:02 -04:00