POV-Ray : Newsgroups : povray.general : POV and 3DNow! instruction set Server Time
13 Aug 2024 13:23:35 EDT (-0400)
  POV and 3DNow! instruction set (Message 1 to 9 of 9)  
From: Rik Ling
Subject: POV and 3DNow! instruction set
Date: 2 Sep 1998 20:22:40
Message: <35edd340.0@news.povray.org>
Would POV benefit at all from the new SIMD floating point instructions
available in the 3DNow! instruction set on the newest AMD K6 processors?

Has any thought been given to altering POV to take advantage of these
functions?

Just wondering...

Rik Ling
Graphihcs Lurker
rli### [at] pipcomcom


Post a reply to this message

From: Nieminen Mika
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 05:07:13
Message: <35ee4e31.0@news.povray.org>
Rik Ling <rli### [at] pipcomcom> wrote:
: Would POV benefit at all from the new SIMD floating point instructions
: available in the 3DNow! instruction set on the newest AMD K6 processors?

  Do you think that 32-bit floats have enough precision for raytracing?
(although I don't know if povray uses floats or doubles...)

-- 
                                                           - Warp. -


Post a reply to this message

From: Ron Parker
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 10:13:06
Message: <35ee95e2.0@news.povray.org>
On 3 Sep 1998 04:07:13 -0500, Nieminen Mika <war### [at] assaricctutfi> wrote:
>  Do you think that 32-bit floats have enough precision for raytracing?
>(although I don't know if povray uses floats or doubles...)

POV has a bad habit of switching between floats and doubles all over the place.
Just run it through a compiler that warns about loss of precision and you'll
see that.  But I think that a sacrifice of a (small) amount of quality might be
worth the speedup if it could be done.  Personally, I only have a K6 and not a 
K6-2, so it's not worth the trouble to me.


Post a reply to this message

From: Peter Popov
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 10:13:30
Message: <35ee95fa.0@news.povray.org>
Since there's no compiler that can do this for you (there isn't one for MMX
yet)  you'll have to hard code in assembler. Aside from being a heluva lot
of work this will benefit just a small percentage of users (PC, K6-2 users).
Also, 3DNow instructions are 32-bit float (though they use 64-bit registers)
and that can  cause to a) losing precision and b) differences in the image
produced on a non-K6-2, like it was with the pseudo-random bug in POV 2.0 .

So the answer to your question is, imho, "no". Well, it will run faster on a
K6-2/300 than on a K6/300 due to the former's better architecture, but will
run even faster on a PII/300 and afaik it costs roughly as much as a K6-2
(but you'll need a new mb).

Peter


Post a reply to this message

From: Ron Parker
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 12:16:28
Message: <35eeb2cc.0@news.povray.org>
On Thu, 3 Sep 1998 16:00:27 +0300, Peter Popov <pet### [at] usanet> wrote:
>So the answer to your question is, imho, "no". Well, it will run faster on a
>K6-2/300 than on a K6/300 due to the former's better architecture, but will
>run even faster on a PII/300 and afaik it costs roughly as much as a K6-2
>(but you'll need a new mb).

Chances are you'd need a new mb for a K6-2, too, unless you just happen to have
a 100 MHz FSB and 2.2V core voltage option on your old board (mine has the 2.2V 
option, but only a 75MHz FSB).  On the question of price, pricewatch.com 
shows the cheapest PII/350 at $362, and the cheapest K6-2/350 at $237.  A 
PII/300 is going for $230, while a K6-2/300 is going for $115.  This assumes, 
of course, that you're comfortable with buying the OEM version of the K6-2.  
Motherboard prices are not included.


Post a reply to this message

From: Rik Ling
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 15:21:55
Message: <35eede43.0@news.povray.org>
A few more observations:

Regarding the "small percentage" of users who stand to benefit from any
3DNow! optimizations, let me remind people that intel will be rolling out
their MMX2 instruction set as of Q1 1999, and it too will have the same
kinds of SIMD FP instructions as the 3DNow! set has today.  Also, CPUs with
3DNow! will also be produced by Cyrix and IDT/Centaur.  Eight to twelve
months from now, every new x86 compatible processor sold will have these
capabilities.

It seems prudent to start optimizing for the K6-2 platform now, so that when
MMX2 becomes available the majority of the "grunt-work" will already have
been completed, leaving only the fine tuning to be done.  Lets face it,
regardless of whether it's 3DNow! or MMX2 or some sort of extended MVI for
Alpha, the basic mechanics of the interface will probably remain consistent.

Besides, I own a K6-2-300, and the potential to realize a two to four times
increase in FP performance just makes me foam at the mouth... :)  I'll start
looking into what might be required to do this (although my programming
skills are a little rusty - this'll be a good refresher)  Anyone who wishes
to help can contact me at rli### [at] pipcomcom

Also, you don't actually need a 100MHz FSB mainboard to run a K6-2-300.  It
will run quite happily with a 66MHz FSB and a 4.5 multiplier.  Certainly
your overall system performance will suffer but programs like POV, which
have a very tight execution loop that has been (hopefully) optimized to stay
within the 16 to 32KB of on-chip cache, won't care about that.  66x4.5 (or
75x4) should yield 95% of the performance of 100x3 in this case.  POV is
nice that way...

The 2.2volt requirement is a little more tricky, but most newer boards (even
the low cost ones) will go as low as 2.1 volts now.  On the whole
(especially if the 3DNow! instruction set can be utilized for a perfomance
gain in POV) the K6-2 would probably give the best bang for your buck.
Also, wouldn't you like that new 500MHz intel katmai processor to REALLY
scream by using MMX2 in addition to its raw horsepower?

Rik Ling
Graphics Lurker (and K6 defender)
rli### [at] pipcomcom


Post a reply to this message

From: Peter Popov
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 16:04:47
Message: <35eee84f.0@news.povray.org>
Rik Ling wrote in message <35eede43.0@news.povray.org>...
>A few more observations:
>
>Regarding the "small percentage" of users who stand to benefit from any
>3DNow! optimizations, let me remind people that intel will be rolling out
>their MMX2 instruction set as of Q1 1999, and it too will have the same
>kinds of SIMD FP instructions as the 3DNow! set has today.  Also, CPUs with
>3DNow! will also be produced by Cyrix and IDT/Centaur.  Eight to twelve
>months from now, every new x86 compatible processor sold will have these
>capabilities.


I apologize, it seems I haven't been watching the news lately :) Anyway I
still
think that nerve-breaking assembler hardcoding for a single platform is
something we just could't demand from the POV-Team. My point of view is
also affected by the fact that it isn't likely I'll be able to afford and
upgrade
in the next two or three years.

>It seems prudent to start optimizing for the K6-2 platform now, so that
when
>MMX2 becomes available the majority of the "grunt-work" will already have
>been completed, leaving only the fine tuning to be done.  Lets face it,
>regardless of whether it's 3DNow! or MMX2 or some sort of extended MVI for
>Alpha, the basic mechanics of the interface will probably remain
consistent.

Well, I am not sure the MMX2, 3DNow! MVI etc. are identical. Well, maybe
they (will) offer similar functionality, but on the coding side of things
they
are, I guess, just different. Also, optimising is very processor-dependent
(things like conveyors, registers, etc.)

>Besides, I own a K6-2-300, and the potential to realize a two to four times
>increase in FP performance just makes me foam at the mouth... :)  I'll
start
>looking into what might be required to do this (although my programming
>skills are a little rusty - this'll be a good refresher)  Anyone who wishes
>to help can contact me at rli### [at] pipcomcom

Well, an unofficial compile made by a group of volunteers is a better idea
than
asking the POV-Team do it and/offer support for it.

>Also, you don't actually need a 100MHz FSB mainboard to run a K6-2-300.  It
>will run quite happily with a 66MHz FSB and a 4.5 multiplier.  Certainly
>your overall system performance will suffer but programs like POV, which
>have a very tight execution loop that has been (hopefully) optimized to
stay
>within the 16 to 32KB of on-chip cache, won't care about that.  66x4.5 (or
>75x4) should yield 95% of the performance of 100x3 in this case.  POV is
>nice that way...
>
>The 2.2volt requirement is a little more tricky, but most newer boards
(even
>the low cost ones) will go as low as 2.1 volts now.  On the whole
>(especially if the 3DNow! instruction set can be utilized for a perfomance
>gain in POV) the K6-2 would probably give the best bang for your buck.
>Also, wouldn't you like that new 500MHz intel katmai processor to REALLY
>scream by using MMX2 in addition to its raw horsepower?
>
>Rik Ling
>Graphics Lurker (and K6 defender)
>rli### [at] pipcomcom
>

Thanks for enlightening me.

Peter.


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 17:19:01
Message: <35eef9b5.0@news.povray.org>
In article <35eede43.0@news.povray.org> , "Rik Ling" <rli### [at] pipcomcom> wrote:
>  Certainly
>your overall system performance will suffer but programs like POV, which
>have a very tight execution loop that has been (hopefully) optimized to stay
>within the 16 to 32KB of on-chip cache, won't care about that.

Basically ray tracers could be this way (if you only use planes and spheres), but
there is *no* way to get the ray tracer code POV-Ray has into such a small cache!  And
don't forget the data (our scene) - so ray tracing *is* one of the few programs where
you will (or should) notice a fast memory interface (and 2nd level cache).


Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany


Post a reply to this message

From: Rik Ling
Subject: Re: POV and 3DNow! instruction set
Date: 3 Sep 1998 17:26:50
Message: <35eefb8a.0@news.povray.org>
Oops!  I have never actually looked at the POV source, so that comment of
mine was an educated guess.  Thank you for pointing out the error.

Nevertheless, I think I'll start researching what would be required to hack
up an unofficial 3DNow! aware version of POV.  At the very least it'll be a
learning experience...


Thorsten Froehlich wrote in message <35eef9b5.0@news.povray.org>...
>In article <35eede43.0@news.povray.org> , "Rik Ling" <rli### [at] pipcomcom>
wrote:
>>  Certainly
>>your overall system performance will suffer but programs like POV, which
>>have a very tight execution loop that has been (hopefully) optimized to
stay
>>within the 16 to 32KB of on-chip cache, won't care about that.
>
>Basically ray tracers could be this way (if you only use planes and
spheres), but there is *no* way to get the ray tracer code POV-Ray has into
such a small cache!  And don't forget the data (our scene) - so ray tracing
*is* one of the few programs where you will (or should) notice a fast memory
interface (and 2nd level cache).
>
>
>Thorsten
>
>____________________________________________________
>Thorsten Froehlich, Duisburg, Germany


Post a reply to this message

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