POV-Ray : Newsgroups : povray.advanced-users : function optimization question : Re: function optimization question Server Time
29 Jul 2024 18:18:44 EDT (-0400)
  Re: function optimization question  
From: Thorsten Froehlich
Date: 31 Mar 2002 17:35:40
Message: <3ca78f3c@news.povray.org>
In article <3ca78098@news.povray.org> , "Jan Walzer" <jan### [at] lzernet> wrote:

> I once had a chance, to speed up the Bresenham by a factor of 3 by a similar
> method. The thing is that you can decide at runtime, which opcodes get
> executed, depending on some runtime values As there are(were) different
> opcodes used for a near-jump (target-address, beein in the same codesegment)
> and a far-jump (jump to anywhere in memory) there was no easy chance, to work
> only with pointers, and only change these...

Not only is this a terrible idea to code anything, it also kills all modern
processor performance.  Well, all but x86 processors of course for which
designers actually have to interlock (or use common) the data and instruction
caches to support such nonsense.  Not that it won't cripple performance for
them as well these days, but on a good old Pentium it will still be fast...

On any reasonable architecture not supporting 25 years of eight bit legacy
backward compatibility and other junk self-modifying code will fortunately
break! :-)

    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.