diff --git a/.pick_status.json b/.pick_status.json index 8c4dacb31f1..248b47759ce 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -3684,7 +3684,7 @@ "description": "llvmpipe: clamp 32bit query results to low 32 bits rather than MIN", "nominated": true, "nomination_type": 0, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": null, "notes": null diff --git a/src/gallium/drivers/llvmpipe/lp_query.c b/src/gallium/drivers/llvmpipe/lp_query.c index d63c6aae0a3..4de16e9b657 100644 --- a/src/gallium/drivers/llvmpipe/lp_query.c +++ b/src/gallium/drivers/llvmpipe/lp_query.c @@ -372,12 +372,12 @@ llvmpipe_get_query_result_resource(struct pipe_context *pipe, switch (result_type) { case PIPE_QUERY_TYPE_I32: { int32_t *iptr = (int32_t *)dst; - *iptr = (int32_t) MIN2(value, INT32_MAX); + *iptr = (int32_t) (value & INT32_MAX); break; } case PIPE_QUERY_TYPE_U32: { uint32_t *uptr = (uint32_t *)dst; - *uptr = (uint32_t) MIN2(value, UINT32_MAX); + *uptr = (uint32_t) (value & UINT32_MAX); break; } case PIPE_QUERY_TYPE_I64: {