GlobalISel: Disallow undef generic virtual register uses
With an undef operand, it's possible for getVRegDef to fail and return null. This is an edge case very little code bothered to consider. Proper gMIR should use G_IMPLICIT_DEF instead. I initially tried to apply this restriction to all SSA MIR, so then getVRegDef would never fail anywhere. However, ProcessImplicitDefs does technically run while the function is in SSA. ProcessImplicitDefs and DetectDeadLanes would need to either move, or a new pseudo-SSA type of function property would need to be introduced.
Loading
Please sign in to comment