Skip to content
Commit 9c2f6658 authored by Pierre Moreau's avatar Pierre Moreau Committed by Emil Velikov
Browse files

nvc0/ir: Properly lower 64-bit shifts when the shift value is >32



Fixes: 61d7676d "nvc0/ir: add support for 64-bit shift lowering on SM20/SM30"

Fixes fs-shift-scalar-by-scalar.shader_test from piglit for the current
set-up:

uniform int64_t ival -0x7dfcfefbdf6536ff # bit pattern: 0x82030104209ac901
uniform uint64_t uval 0x1400000085010203
uniform int shl 36
uniform int shr 36
uniform int64_t iexpected_shl 0x09ac901000000000
uniform int64_t iexpected_shr -0x7dfcff0 # bit pattern: 0xfffffffff8203010
uniform uint64_t uexpected_shl 0x5010203000000000
uniform uint64_t uexpected_shr 0x0000000001400000
draw rect ortho 12 0 4 4

Signed-off-by: default avatarPierre Moreau <pierre.morrow@free.fr>
Reviewed-by: default avatarIlia Mirkin <imirkin@alum.mit.edu>
(cherry picked from commit 9bee1216)
parent a5524802
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment