Skip to content

Commit

Permalink
MSL: Use actual result type member as cast type for mulhi.
Browse files Browse the repository at this point in the history
There might be initializer errors if there's a mismatch knowing C++11
rules, so be defensive.
  • Loading branch information
HansKristian-Work committed Oct 15, 2024
1 parent 80cdb5e commit c82f1cc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spirv_msl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9560,7 +9560,7 @@ void CompilerMSL::emit_instruction(const Instruction &instruction)
uint32_t op0 = ops[2];
uint32_t op1 = ops[3];
auto &type = get<SPIRType>(result_type);
auto &op_type = expression_type(op0);
auto &op_type = get<SPIRType>(type.member_types[0]);
auto input_type = opcode == OpSMulExtended ? int_type : uint_type;
string cast_op0, cast_op1;

Expand Down

0 comments on commit c82f1cc

Please sign in to comment.