I found a nontrivial mistake in my currently-under-review paper. Should I send a correction to the editor?
If the mistake is important, you should send a correction now, rather than waiting for the referee report.  (If it's not important in the context of the overall paper, then the right course of action is more debatable, but in your case it sounds like an important enough mistake to require notifying the referee.)


If you wait, you are wasting the referee's time figuring out something you already know.
I think it looks better to catch your own mistake than to have it pointed out by the referee.
If the referee doesn't notice the mistake and suggests accepting the paper, I imagine the editor will rescind the acceptance after you point out the mistake, or at least suggest further refereeing (since not noticing a completely wrong proof calls into question the reliability of the referee report).  On the other hand, if you point it out, the referee may still recommend accepting the revised manuscript.



  For context, this is one of three main results of the paper, but its proof only takes up about two manuscript pages (out of 18 total).


This sounds like an ideal case for pointing out the mistake: it has real importance, but I'd bet the chances of acceptance remain reasonable.