Messages in this thread | | | Date | Wed, 28 May 2003 19:23:30 -0700 | From | Andrew Morton <> | Subject | Re: [patch] Inline vm_acct_memory |
| |
Hugh Dickins <hugh@veritas.com> wrote: > > On Wed, 28 May 2003, Ravikiran G Thirumalai wrote: > > I found that inlining vm_acct_memory speeds up vm_enough_memory. > > Since vm_acct_memory is only called by vm_enough_memory, > > No, linux/mman.h declares > > static inline void vm_unacct_memory(long pages) > { > vm_acct_memory(-pages); > } > > and I count 18 callsites for vm_unacct_memory. > > I'm no judge of what's worth inlining, but Andrew is widely known > and feared as The Scourge of Inliners, so I'd advise you to hide...
Maybe I'm wrong. kernbench is not some silly tight-loop microbenchmark. It is a "real" workload: gcc.
The thing about pagetable setup and teardown is that it tends to be called in big lumps: for a while the process is establishing thousands of pages and then later it is tearing down thousands. So the cache-thrashing impact of having those eighteen instances sprinkled around the place is less than it would be if they were all being called randomly. If you can believe such waffle.
Kiran, do you still have the raw data available? profiles and runtimes? - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |