Fixes https://github.com/bitcoin/secp256k1/issues/257 by catching the degenerate case, which appears as an intermediate variable being 0/0, and using an alternate expression for that variable in this case.
This results in only a ~3% perf hit on signing. There are no changes in the multiplication or squaring count; this is entirely due to additions and cmovs. “I doubt we can do better” but I said that about an earlier revision with a 6% hit and Peter Dettman found a way to beat it, so my doubts aren’t worth much :)