microsoft/compiler: Fix make_double and split_double to respect swizzles

Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Reviewed-By: Sil Vilerino <sivileri@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14837>
This commit is contained in:
Jesse Natalie 2022-02-01 11:39:43 -08:00 committed by Marge Bot
parent 92191349e9
commit c8bd830dfb

View file

@ -2224,8 +2224,8 @@ emit_make_double(struct ntd_context *ctx, nir_alu_instr *alu)
const struct dxil_value *args[3] = {
opcode,
get_src(ctx, &alu->src[0].src, 0, nir_type_uint32),
get_src(ctx, &alu->src[0].src, 1, nir_type_uint32),
get_src(ctx, &alu->src[0].src, alu->src[0].swizzle[0], nir_type_uint32),
get_src(ctx, &alu->src[0].src, alu->src[0].swizzle[1], nir_type_uint32),
};
if (!args[1] || !args[2])
return false;
@ -2250,7 +2250,7 @@ emit_split_double(struct ntd_context *ctx, nir_alu_instr *alu)
const struct dxil_value *args[] = {
opcode,
get_src(ctx, &alu->src[0].src, 0, nir_type_float64)
get_src(ctx, &alu->src[0].src, alu->src[0].swizzle[0], nir_type_float64)
};
if (!args[1])
return false;