Nikolai Zhubr schrieb:
Originally MS spread info it wouldn't work at all under Windows, but
that proved to be false,
the FPU works technically. Now MS just states it is unsupported.
And deprecated:
http://msdn.microsoft.com/en-us/library/ee418798(VS.85).aspx#Porting_to_64bit
Thanks. I always knew that Windows is not an OS for serious work, but I
never heard that from Microsoft so clearly :-(
Not being an ms fan whatsoever, but you all seem to have missed the
technical point here.
Because x87 (and also MMX in some sense) is a coprocessor (and has its
own register space) its full state has to be saved/restored (by an OS)
between different running processes in case any process might use
fpu/mmx.
The same applies to the XMM/YMM registers. While dropping MMX support is
acceptable, in favor of the new vector arithmetic instruction set, I see
no point in dropping 80 bit reals before a new 128 bit arithmetic
becomes available.
Clearly this may become rather inefficient performance-wise
(because, well, an application might just want to use 2 fpu registers at
a time, and OS will still have to store the whole bunch all the time...)
Now, with the introduction of 64-bit processors IIRC AMD took care of
this problem by providing some means to execute floating-point
operations without the need for traditional FPU register space, thus
allowing to avoid the need to save/restore FPU state. IIRC these are
some _new_ opcodes, unavailable on earlier CPUs.
When AMD aliased the FPU and MMX registers, I don't understand why they
*added* new XMM registers, instead of extending the already existing MMX
registers - just for fast switching. But it is as it is...
So, for performance reasons, and because 64-bit applications (are now
supposed to be) able to do all floating-point without touching the
traditional FPU, ms (supposedly) decided to just not preserve FPU/MMX
state between 64-bit processes. Thats all. IMHO is makes some sense
actually, though it would be much nicer if there was some option to
select this deliberately (say at boot time or whatever).
At least an application should have a chance to specify, which register
sets have to be saved on an task switch. Unless stated otherwise by MS,
the entire state should be saved, as long as x87/MMX is only deprecated,
not dropped. Any official information on this issue?
DoDi
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel