Skip to content

Commit

Permalink
Replaced break with return null
Browse files Browse the repository at this point in the history
  • Loading branch information
jkurdek committed Mar 14, 2024
1 parent 5bbe5c4 commit 1ebb378
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions src/mono/mono/mini/simd-intrinsics.c
Original file line number Diff line number Diff line change
Expand Up @@ -3067,7 +3067,6 @@ emit_vector_2_3_4 (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *f
}
case SN_CopyTo:
return NULL;
break;
case SN_Clamp: {
if (!(!fsig->hasthis && fsig->param_count == 3 && mono_metadata_type_equal (fsig->ret, type) && mono_metadata_type_equal (fsig->params [0], type) && mono_metadata_type_equal (fsig->params [1], type) && mono_metadata_type_equal (fsig->params [2], type)))
return NULL;
Expand Down Expand Up @@ -3107,9 +3106,10 @@ emit_vector_2_3_4 (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *f
default:
g_assert_not_reached ();
}
#else
return NULL;
#endif
}
break;
case SN_Length:
case SN_LengthSquared: {
#if defined (TARGET_ARM64)
Expand All @@ -3135,9 +3135,10 @@ emit_vector_2_3_4 (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *f
default:
g_assert_not_reached ();
}
#else
return NULL;
#endif
}
break;
case SN_Lerp: {
#if defined (TARGET_ARM64)
MonoInst* v1 = args [1];
Expand All @@ -3156,9 +3157,10 @@ emit_vector_2_3_4 (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *f
result->inst_c1 = MONO_TYPE_R4;

return result;
#else
return NULL;
#endif
}
break;
case SN_Normalize: {
#if defined (TARGET_ARM64)
MonoInst* vec = args[0];
Expand Down Expand Up @@ -3187,9 +3189,10 @@ emit_vector_2_3_4 (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *f
normalized_vec->inst_c1 = MONO_TYPE_R4;

return normalized_vec;
#else
return NULL;
#endif
}
break;
case SN_Conjugate: {
#if defined (TARGET_ARM64)
float value[4];
Expand All @@ -3202,9 +3205,10 @@ emit_vector_2_3_4 (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *f
result->inst_c0 = OP_FMUL;
result->inst_c1 = MONO_TYPE_R4;
return result;
#else
return NULL;
#endif
}
break;
default:
g_assert_not_reached ();
}
Expand Down

0 comments on commit 1ebb378

Please sign in to comment.