In ReflectionMethodBodyScanner and HandleCallAction, we do many of the same checks that already occur in GetIntrinsicIdFromMethod, and in a few places we have 'when' conditions that could just be regular cases. This removes the extra checks so the switch can be simpler and more optimized.
In the linker, we also get the IntrinsicId twice, so this adds an optional parameter for a known IntrinsicId.
In ReflectionMethodBodyScanner and HandleCallAction, we do many of the same checks that already occur in
GetIntrinsicIdFromMethod
, and in a few places we have 'when' conditions that could just be regular cases. This removes the extra checks so the switch can be simpler and more optimized.In the linker, we also get the IntrinsicId twice, so this adds an optional parameter for a known IntrinsicId.