POV-Ray : Newsgroups : povray.off-topic : Questionable entertainment : Re: Questionable entertainment Server Time
9 Oct 2024 09:58:11 EDT (-0400)
  Re: Questionable entertainment  
From: Invisible
Date: 12 Feb 2009 07:50:34
Message: <49941b1a@news.povray.org>
Hey, neat bug. Somebody posted a program that can be made 2.5 *times* 
slower by renaming some functions. (!!)

The glitch, it turns out, is because the compiler automatically inserts 
an error handler into the function, and it prints out the function's 
name. Having a sufficiently long function name tips the function's "cost 
estimate" over the maximum limit for being inlined. So the function 
doesn't get inlined, and consequently runs much slower.

Heh. Starting to understand why building a production compiler is so 
damned hard... ;-)


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.