Fix for bug 12398: Lowering is inconsistent in checking safety of RegOptional. (#19740)
This fixes an inconsistency in lowering where it fails to make an
operand contained because IsSafeToContainMem() returns false yet
it marks it regOptional, which may cause a problem if the operand
will be loaded at the point of use.
I also fixed a case where an operand was marked RegOptional even though
there is a type size mismatch.
There are 7 places that are affected, I added repro cases for 4 of them.
I wasn't able to construct repros for the 3 places that deal with
floating point operands but decided to fix those places anyway.
Fixes #12398.