* Michal Mertl <[EMAIL PROTECTED]> [020203 08:17] wrote:
> I wrote a simple program which does this:
> 
> gettimeofday
> something (takes several seconds)
> gettimeofday
> print time elapsed
> 
> Several runs of the program take about the same time but the time
> changes wildly when the executable is called differently.
> 
> -------
> ./xx/xxx
> 5 s
> xx/xxx
> 9 s
> 
> and similar. It holds true on vastly different machines with current and
> stable.
> 
> The only thing which I can think of that can be causing this is some
> memory alignment issue.

It sure looks like an alignment issue.  If you print the address
of 'i' and 'j' in the attached program you can see for the fast
case they are aligned to 8 byte boundries, but when it's slow they
are at an address that is a multiple of 4 but not 8.

Not really sure what to make of this, anyone else know how we ought
to fix this?

-Alfred


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to