[secp256k1] refactor: Decouple table generation and ecmult_gen context
Summary:
This is a partial backport of secp256k1#988
https://github.com/bitcoin-core/secp256k1/pull/988/commits/e43ba02cfc836dba48c8c9a483e79b7589ce9ae1
Depends on D19382
Test Plan: ninja check-secp256k1
Reviewers: #bitcoin_abc, Fabien
Reviewed By: #bitcoin_abc, Fabien
Differential Revision: https://reviews.bitcoinabc.org/D19383