mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2024-11-24 02:34:17 +08:00
glsl: allow 64-bit integer on RHS of shift
Fixes: 9ba9a7f854
("glsl: Add 64-bit integer support to some operations.")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6862
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21919>
This commit is contained in:
parent
39c828cb9f
commit
174d6e6a54
@ -747,7 +747,7 @@ shift_result_type(const struct glsl_type *type_a,
|
||||
return glsl_type::error_type;
|
||||
|
||||
}
|
||||
if (!type_b->is_integer_32()) {
|
||||
if (!type_b->is_integer_32_64()) {
|
||||
_mesa_glsl_error(loc, state, "RHS of operator %s must be an integer or "
|
||||
"integer vector", ast_expression::operator_string(op));
|
||||
return glsl_type::error_type;
|
||||
|
@ -805,7 +805,7 @@ ir_validate::visit_leave(ir_expression *ir)
|
||||
case ir_binop_lshift:
|
||||
case ir_binop_rshift:
|
||||
assert(ir->operands[0]->type->is_integer_16_32_64() &&
|
||||
ir->operands[1]->type->is_integer_16_32());
|
||||
ir->operands[1]->type->is_integer_16_32_64());
|
||||
if (ir->operands[0]->type->is_scalar()) {
|
||||
assert(ir->operands[1]->type->is_scalar());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user