Re: [Gems-users] Cache Warming for Benchmarks


Date: Tue, 8 May 2007 23:27:29 -0400 (EDT)
From: Daniel Nussbaum - Sun Microsystems - Burlington United States <dan.nussbaum@xxxxxxx>
Subject: Re: [Gems-users] Cache Warming for Benchmarks
>
> Date: Tue, 08 May 2007 20:11:35 -0400
> From: Greg Byrd <gbyrd@xxxxxxxx>
>
> Without Ruby, there are no caches to warm up.
>

That's not quite true.  There's more context to this discussion that
James didn't mention.

Here's what I told him:

  The issue here is not the data cache.  It's Solaris' virtual memory
  system, which Simics models quite well, with or without Ruby.

Solaris maintains something called a TSB, which is a software cache
that enables fast reloading of evicted TLB translations.  Simics
models the virtual memory hardware and the TSB completely
independently of whether ruby is loaded or not.

James tells me that he is seeing the following:

>
> >
> >     The scenario we got is that the system had some hardware
> >     attempts that failed then it goes into software mode. And
> >     right after it gets to software mode, the system takes a data
> >     tlb miss, then the processor start to take other exceptions
> >     and never come back again.
> >
>

My point was that a tlb miss can occasionally take a *very* long time
to service, depending on how much of the underlying structure solaris
needs to build.

(In fact, taking a tlb miss when a LogTM transaction is open can cause
chaos, since it behaves like a system call, which, in conjunction with
a LogTM transaction, can cause wedges, simulated solaris crashes, or
worse.  But I digress -- that's not what's going on here, since a
LogTM transaction is not open at the time that the system goes into
hyperspace.)

So the answer is: touch all the pages you need *before* loading ruby
(so that the TSB gets completely preloaded while things are fast)
then do whatever you need to do to warm up the data caches *after*
loading ruby.

dann

>
> ...Greg
>
>
> James Wang wrote:
>
> > Hi All:
> >
> > 	I would like to warm my cache for my benchmarks. Should I do
> > this before or after I loaded Ruby? If I do it before I load Ruby,
> > what data structure is touched by the Solaris system in Simics?
> > Any idea?
> >
> > 	Thanks in advance for any reply!
> >
> > Regards
> > James Wang
> >
>
[← Prev in Thread] Current Thread [Next in Thread→]