Date: Thu, 7 May 1998 17:04:24 +0300 (IDT) From: Eli Zaretskii To: Johan Van Ooijen cc: djgpp AT delorie DOT com Subject: Re: large variation in run-time In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Thu, 7 May 1998, Johan Van Ooijen wrote: > >Another possibility might be the size of your innermost loop: if it > >sometimes overflows the CPU caches, you will see a factor of 2-4 in > >performance without any apparent explanation. > > How does this happen? If your inner loop has conditionals (if (foo) etc.) which only sometimes fire, then the size of the code executed on each iteration will vary. If that size becomes more than the CPU cache, runtime will suffer.