A.D.A. Amiga Demoscene Archive

        Welcome guest!

  

  

  

log in with SceneID

  

Demos Amiga Demoscene Archive Forum / Emulation / UAE and FPU

 

Author Message
xeron
Member
#1 - Posted: 11 Apr 2007 12:43
Reply Quote
I was talking about the FPU with Doom, and he has made me aware of some issues with UAE's (shitty) FPU emulation and I thought i'd share this information here so that more people can be aware of it when coding in UAE.

First, the 68k FPUs all work in 80bit extended precision (.x) internally, although you can specify 32bit single precision (.s) and 64bit double precision (.d). However, the x86 architecture doesn't have extended precision, so UAE's emulated FPU works in 64bit all the time.

Also, UAE's FPU *always* rounds down, whereas by default the 68k FPU rounds to nearest (you can change this, though). This can cause a problem with for example:

fmove #65536,fp0
fmove.w fp0,d0

on Amiga this would put 32767 into d0 since its the highest integer word value. On UAE it puts zero.

So.. BEWARE!
z5_
Member
#2 - Posted: 11 Apr 2007 12:51
Reply Quote
@xeron:

Actually, i think you are referring to the problems Blueberry mentioned in this thread, which he started just for that.
xeron
Member
#3 - Posted: 11 Apr 2007 13:58
Reply Quote
Oh right i missed that thread. Sorry.

 

  Please log in to comment

  

  

  

 

A.D.A. Amiga Demoscene Archive, Version 3.0