Isn’t musk a clear counterexample here? He has had numerous liaisons with subordinates. Yet I haven’t seen either SpaceX or Tesla (who actually could) move to fire him.
Or is he the exception?
It's entirely up to company policy. Nvidia had no policy barring personal relationships among employees. When it's a direct report it creates some risk that staffers will claim coercion or favoritism. For many companies, that risk is too high to allow, but I've worked for publicly traded companies where that sort of thing happened openly.