update c-lib to upstream#19
Conversation
Also update build.rs and ext.c
| else | ||
| { | ||
| secp256k1_ecmult_const(&res, &pt, &s); | ||
| secp256k1_ecmult_const(&res, &pt, &s, 256); |
There was a problem hiding this comment.
ext.c is not present in upstream (our extention), so we need to make sure 256 is the right size here
There was a problem hiding this comment.
Not sure, if I am the right person to ask, but imo that's the correct change :)
|
|
||
| impl error::Error for Error { | ||
| fn cause(&self) -> Option<&error::Error> { None } | ||
| fn cause(&self) -> Option<&dyn error::Error> { None } |
|
|
||
| base_config.flag("-g") | ||
| .include("depend/secp256k1/src") | ||
| .debug(true) |
There was a problem hiding this comment.
This doesn't mean the same thing as in Rust I take it? But what does it mean? Includes symbols?
There was a problem hiding this comment.
we used "-g" flag previously, I guess this should mean the same
There was a problem hiding this comment.
That's the same as debug = true in rust, adds debug symbols to the build (doesn't downgrade the perf much)
| else | ||
| { | ||
| secp256k1_ecmult_const(&res, &pt, &s); | ||
| secp256k1_ecmult_const(&res, &pt, &s, 256); |
| include src/modules/ecdh/Makefile.am.include | ||
| endif | ||
|
|
||
| if ENABLE_MODULE_SCHNORR |
There was a problem hiding this comment.
seems like schnorr support was removed, do we use it though?
There was a problem hiding this comment.
afaik we do not, but maybe @svyatonik can help with that too?
There was a problem hiding this comment.
Ehhh...The only thing I can guarantee is that we don't use it in blockchain clients - parity-ethereum (and specifically in SecretStore), parity-bitcoin, parity-zcash (and obviously in substrate). Can't tell about the the rest...
I've updated the c-lib to f5c8a00, build.rs to upstream except for disabling
USE_EXTERNAL_DEFAULT_CALLBACKS(https://github.com/paritytech/rust-secp256k1/compare/master...paritytech:ao-update-c-lib-to-upstream?expand=1#diff-a7b0a2dee0126cddf994326e705a91eaR103) (link time errors otherwise).The benchmarks on parity-ethereum shows 33% improvement for
verify_block_unordered