POV-Ray : Newsgroups : povray.advanced-users : Object Oriented POV code : Re: Object Oriented POV code Server Time
29 Jul 2024 16:27:05 EDT (-0400)
  Re: Object Oriented POV code  
From: Thorsten Froehlich
Date: 22 Feb 2004 07:21:57
Message: <40389ee5$1@news.povray.org>
In article <403897c7$1@news.povray.org> , "Tek" <tek### [at] evilsuperbraincom> 
wrote:

> Couldn't compilers inline functions 10 years ago?

Not as well, no.

> Anyway, my point isn't just the function call overhead, it's the fact that
> it's not an operator internally supported by the compiler with a bunch of
> rules, it's a series of instructions of unspecified length elsewhere.

There is no such difference.

> Well, it can lose the function call overhead, but not the overhead of it being
> a function (i.e. several instructions) rather than a simple instruction (which
> is really my point).

No, there won't be additional instructions if a function is inlined.  For
any (not ten year old) compiler the overhead of inlining a function will be
exactly zero compared to direct insertion of the code.

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

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