[Mesa-dev] [PATCH] glsl: add ir_unop_b2d

Ilia Mirkin imirkin at alum.mit.edu
Tue Jan 12 09:41:29 PST 2016


On Tue, Jan 12, 2016 at 12:33 PM, Ian Romanick <idr at freedesktop.org> wrote:
> On 01/12/2016 07:29 AM, Ilia Mirkin wrote:
>> IIRC this should come out as b2i + i2d. You should be able to test this
>> with llvmpipe/softpipe, which support fp64.
>
> Either that or b2f + f2d.  I remember there being discussion about this
> topic when Dave first sent out the fp64 patches.  I thought we decided
> against a b2d opcode.

Yeah, I didn't actually check. I hope it's b2i + i2d though since that
could be done in one op on NVIDIA :) Oh, and to pre-empt the question,
the reason why there's a d2b is that doubles can represent numbers
smaller than float, so d2f might come out as 0 even though the double
!= 0. However no such problem exists in the reverse direction.

  -ilia


More information about the mesa-dev mailing list