OSDN Git Service

nv50/ir: use round toward 0 when converting doubles to integers
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Mon, 6 Jun 2016 19:12:15 +0000 (21:12 +0200)
committerEmil Velikov <emil.l.velikov@gmail.com>
Tue, 14 Jun 2016 14:48:38 +0000 (15:48 +0100)
commit4306e01ecedd8174560e5fd7f3706ebfb5227bb8
tree615aad7ec22fae4ee05eb8562502e68a82e1de2e
parentb9920d2bba863b6b1abdf584c30032402a36f944
nv50/ir: use round toward 0 when converting doubles to integers

Like floats, we should use the round toward 0 mode instead of the
nearest one (which is the default) for doubles to integers.

This fixes all arb_gpu_shader_fp64 piglits which convert doubles to
integers (16 tests).

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: "11.2 12.0" <mesa-stable@lists.freedesktop.org>
(cherry picked from commit 08ddfe7b2fa9f577ba00c8c05c5604460942f5a8)
src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp