SQRT or RSQRT - that is the question

discussion of forwardcom instruction set and corresponding hardware and software

Moderator: agner

Post Reply
damianmoz
Posts: 9
Joined: 2023-11-26, 0:05:59

SQRT or RSQRT - that is the question

Post by damianmoz »

While sqrt is a basic IEEE 754 operation, I have always found rsqrt a more useful quantity (from which I can deduce sqrt anyway).

Are there any plans for a rsqrt primitive or an approximation to it?

Same question about reciprocal rather than a true division although there is potentially less justification for this.

Just curious.
agner
Site Admin
Posts: 192
Joined: 2017-10-15, 8:07:27
Contact:

Re: SQRT or RSQRT - that is the question

Post by agner »

Existing instruction sets have several different instructions for fast reciprocal and fast rsqrt with different precisions. It will be a mess if different hardware implementations have different precision for the same instruction. Therefore, I think these have to be optional implementation-specific instructions.
Post Reply