Re: 64bit/64bit fixed point division?
- From: "Maarten Kronenburg" <spamtrap@xxxxxxxxxx>
- Date: Fri, 25 Aug 2006 19:23:42 +0200
But there is no need to use FIST/FILD.
You can also write/read an extended precision
floating point (10 bytes) in memory with a value,
and use fld tword [edx] where edx is the address.
(for Turbo Assembler it's fld [tbyte edx]),
and vice versa with fst.
Only then you must also write/read the exponent,
which will be a little slower.
"Phil Carmody" <thefatphil_demunged@xxxxxxxxxxx> wrote in message
news:87lkpdfouz.fsf@xxxxxxxxxxxxxxxxxxxxxxx
"Maarten Kronenburg" <spamtrap@xxxxxxxxxx> writes:
Phil,
The mantissa for extended precision 80-bit floating point
is the full 64-bit, only bit number 63 is always 1.
The sign bit is bit number 79, see for example
http://babbage.cs.qc.edu/courses/cs341/IEEE-754references.html
and the book The Intel Microprocessors by Barry Brey.
So you can put a 64-bit integer into an extended precision
80-bit floating point without loss of precision.
I know. The FPU's fine, it's the interface from FP to integer
that's the problem. You can't (just) use a FISTP though.
(Unless you know that the answer is unique modulo 2^64.)
Phil
--
"Home taping is killing big business profits. We left this side blank
so you can help." -- Dead Kennedys, written upon the B-side of tapes of
/In God We Trust, Inc./.
.
- Follow-Ups:
- Re: 64bit/64bit fixed point division?
- From: Terje Mathisen
- Re: 64bit/64bit fixed point division?
- References:
- 64bit/64bit fixed point division?
- From: spamtrap
- Re: 64bit/64bit fixed point division?
- From: Robert Redelmeier
- Re: 64bit/64bit fixed point division?
- From: Terje Mathisen
- Re: 64bit/64bit fixed point division?
- From: Phil Carmody
- Re: 64bit/64bit fixed point division?
- From: Maarten Kronenburg
- Re: 64bit/64bit fixed point division?
- From: Phil Carmody
- 64bit/64bit fixed point division?
- Prev by Date: Re: enabling x87 interrupts
- Next by Date: Re: Suggestion for some good ASM books?
- Previous by thread: Re: 64bit/64bit fixed point division?
- Next by thread: Re: 64bit/64bit fixed point division?
- Index(es):
Relevant Pages
|