forked from bitcoin-core/secp256k1
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
batch: Initialize an experimental batch module
This commit adds the foundational configuration, build scripts, and an initial structure for experimental batch module.
- Loading branch information
Showing
11 changed files
with
296 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#ifndef SECP256K1_BATCH_H | ||
#define SECP256K1_BATCH_H | ||
|
||
#include "secp256k1.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
/** This module implements a Batch Verification object that supports: | ||
* | ||
* 1. Schnorr signatures compliant with Bitcoin Improvement Proposal 340 | ||
* "Schnorr Signatures for secp256k1" | ||
* (https://github.com/bitcoin/bips/blob/master/bip-0340.mediawiki). | ||
* | ||
* 2. Taproot commitments compliant with Bitcoin Improvemtn Proposal 341 | ||
* "Taproot: SegWit version 1 spending rules" | ||
* (https://github.com/bitcoin/bips/blob/master/bip-0341.mediawiki). | ||
*/ | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif /* SECP256K1_BATCH_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,117 @@ | ||
/* src/libsecp256k1-config.h. Generated from libsecp256k1-config.h.in by configure. */ | ||
/* src/libsecp256k1-config.h.in. Generated from configure.ac by autoheader. */ | ||
|
||
#ifndef LIBSECP256K1_CONFIG_H | ||
|
||
#define LIBSECP256K1_CONFIG_H | ||
|
||
/* Define this symbol to compile out all VERIFY code */ | ||
/* #undef COVERAGE */ | ||
|
||
/* Set ecmult gen precision bits */ | ||
#define ECMULT_GEN_PREC_BITS 4 | ||
|
||
/* Set window size for ecmult precomputation */ | ||
#define ECMULT_WINDOW_SIZE 15 | ||
|
||
/* Define this symbol to enable the batch verification module */ | ||
#define ENABLE_MODULE_BATCH 1 | ||
|
||
/* Define this symbol to enable the ECDH module */ | ||
/* #undef ENABLE_MODULE_ECDH */ | ||
|
||
/* Define this symbol to enable the extrakeys module */ | ||
#define ENABLE_MODULE_EXTRAKEYS 1 | ||
|
||
/* Define this symbol to enable the ECDSA pubkey recovery module */ | ||
/* #undef ENABLE_MODULE_RECOVERY */ | ||
|
||
/* Define this symbol to enable the schnorrsig module */ | ||
#define ENABLE_MODULE_SCHNORRSIG 1 | ||
|
||
/* Define to 1 if you have the <dlfcn.h> header file. */ | ||
#define HAVE_DLFCN_H 1 | ||
|
||
/* Define to 1 if you have the <inttypes.h> header file. */ | ||
#define HAVE_INTTYPES_H 1 | ||
|
||
/* Define to 1 if you have the <stdint.h> header file. */ | ||
#define HAVE_STDINT_H 1 | ||
|
||
/* Define to 1 if you have the <stdio.h> header file. */ | ||
#define HAVE_STDIO_H 1 | ||
|
||
/* Define to 1 if you have the <stdlib.h> header file. */ | ||
#define HAVE_STDLIB_H 1 | ||
|
||
/* Define to 1 if you have the <strings.h> header file. */ | ||
#define HAVE_STRINGS_H 1 | ||
|
||
/* Define to 1 if you have the <string.h> header file. */ | ||
#define HAVE_STRING_H 1 | ||
|
||
/* Define to 1 if you have the <sys/stat.h> header file. */ | ||
#define HAVE_SYS_STAT_H 1 | ||
|
||
/* Define to 1 if you have the <sys/types.h> header file. */ | ||
#define HAVE_SYS_TYPES_H 1 | ||
|
||
/* Define to 1 if you have the <unistd.h> header file. */ | ||
#define HAVE_UNISTD_H 1 | ||
|
||
/* Define this symbol if valgrind is installed, and it supports the host | ||
platform */ | ||
/* #undef HAVE_VALGRIND */ | ||
|
||
/* Define to the sub-directory where libtool stores uninstalled libraries. */ | ||
#define LT_OBJDIR ".libs/" | ||
|
||
/* Name of package */ | ||
#define PACKAGE "libsecp256k1" | ||
|
||
/* Define to the address where bug reports for this package should be sent. */ | ||
#define PACKAGE_BUGREPORT "https://github.com/bitcoin-core/secp256k1/issues" | ||
|
||
/* Define to the full name of this package. */ | ||
#define PACKAGE_NAME "libsecp256k1" | ||
|
||
/* Define to the full name and version of this package. */ | ||
#define PACKAGE_STRING "libsecp256k1 0.1.0-pre" | ||
|
||
/* Define to the one symbol short name of this package. */ | ||
#define PACKAGE_TARNAME "libsecp256k1" | ||
|
||
/* Define to the home page for this package. */ | ||
#define PACKAGE_URL "https://github.com/bitcoin-core/secp256k1" | ||
|
||
/* Define to the version of this package. */ | ||
#define PACKAGE_VERSION "0.1.0-pre" | ||
|
||
/* Define to 1 if all of the C90 standard headers exist (not just the ones | ||
required in a freestanding environment). This macro is provided for | ||
backward compatibility; new code need not use it. */ | ||
#define STDC_HEADERS 1 | ||
|
||
/* Define this symbol to enable x86_64 assembly optimizations */ | ||
#define USE_ASM_X86_64 1 | ||
|
||
/* Define this symbol if an external (non-inline) assembly implementation is | ||
used */ | ||
/* #undef USE_EXTERNAL_ASM */ | ||
|
||
/* Define this symbol if an external implementation of the default callbacks | ||
is used */ | ||
/* #undef USE_EXTERNAL_DEFAULT_CALLBACKS */ | ||
|
||
/* Define this symbol to force the use of the (unsigned) __int128 based wide | ||
multiplication implementation */ | ||
/* #undef USE_FORCE_WIDEMUL_INT128 */ | ||
|
||
/* Define this symbol to force the use of the (u)int64_t based wide | ||
multiplication implementation */ | ||
/* #undef USE_FORCE_WIDEMUL_INT64 */ | ||
|
||
/* Version number of package */ | ||
#define VERSION "0.1.0-pre" | ||
|
||
#endif /*LIBSECP256K1_CONFIG_H*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
/* src/libsecp256k1-config.h.in. Generated from configure.ac by autoheader. */ | ||
|
||
#ifndef LIBSECP256K1_CONFIG_H | ||
|
||
#define LIBSECP256K1_CONFIG_H | ||
|
||
/* Define this symbol to compile out all VERIFY code */ | ||
#undef COVERAGE | ||
|
||
/* Set ecmult gen precision bits */ | ||
#undef ECMULT_GEN_PREC_BITS | ||
|
||
/* Set window size for ecmult precomputation */ | ||
#undef ECMULT_WINDOW_SIZE | ||
|
||
/* Define this symbol to enable the batch verification module */ | ||
#undef ENABLE_MODULE_BATCH | ||
|
||
/* Define this symbol to enable the ECDH module */ | ||
#undef ENABLE_MODULE_ECDH | ||
|
||
/* Define this symbol to enable the extrakeys module */ | ||
#undef ENABLE_MODULE_EXTRAKEYS | ||
|
||
/* Define this symbol to enable the ECDSA pubkey recovery module */ | ||
#undef ENABLE_MODULE_RECOVERY | ||
|
||
/* Define this symbol to enable the schnorrsig module */ | ||
#undef ENABLE_MODULE_SCHNORRSIG | ||
|
||
/* Define to 1 if you have the <dlfcn.h> header file. */ | ||
#undef HAVE_DLFCN_H | ||
|
||
/* Define to 1 if you have the <inttypes.h> header file. */ | ||
#undef HAVE_INTTYPES_H | ||
|
||
/* Define to 1 if you have the <stdint.h> header file. */ | ||
#undef HAVE_STDINT_H | ||
|
||
/* Define to 1 if you have the <stdio.h> header file. */ | ||
#undef HAVE_STDIO_H | ||
|
||
/* Define to 1 if you have the <stdlib.h> header file. */ | ||
#undef HAVE_STDLIB_H | ||
|
||
/* Define to 1 if you have the <strings.h> header file. */ | ||
#undef HAVE_STRINGS_H | ||
|
||
/* Define to 1 if you have the <string.h> header file. */ | ||
#undef HAVE_STRING_H | ||
|
||
/* Define to 1 if you have the <sys/stat.h> header file. */ | ||
#undef HAVE_SYS_STAT_H | ||
|
||
/* Define to 1 if you have the <sys/types.h> header file. */ | ||
#undef HAVE_SYS_TYPES_H | ||
|
||
/* Define to 1 if you have the <unistd.h> header file. */ | ||
#undef HAVE_UNISTD_H | ||
|
||
/* Define this symbol if valgrind is installed, and it supports the host | ||
platform */ | ||
#undef HAVE_VALGRIND | ||
|
||
/* Define to the sub-directory where libtool stores uninstalled libraries. */ | ||
#undef LT_OBJDIR | ||
|
||
/* Name of package */ | ||
#undef PACKAGE | ||
|
||
/* Define to the address where bug reports for this package should be sent. */ | ||
#undef PACKAGE_BUGREPORT | ||
|
||
/* Define to the full name of this package. */ | ||
#undef PACKAGE_NAME | ||
|
||
/* Define to the full name and version of this package. */ | ||
#undef PACKAGE_STRING | ||
|
||
/* Define to the one symbol short name of this package. */ | ||
#undef PACKAGE_TARNAME | ||
|
||
/* Define to the home page for this package. */ | ||
#undef PACKAGE_URL | ||
|
||
/* Define to the version of this package. */ | ||
#undef PACKAGE_VERSION | ||
|
||
/* Define to 1 if all of the C90 standard headers exist (not just the ones | ||
required in a freestanding environment). This macro is provided for | ||
backward compatibility; new code need not use it. */ | ||
#undef STDC_HEADERS | ||
|
||
/* Define this symbol to enable x86_64 assembly optimizations */ | ||
#undef USE_ASM_X86_64 | ||
|
||
/* Define this symbol if an external (non-inline) assembly implementation is | ||
used */ | ||
#undef USE_EXTERNAL_ASM | ||
|
||
/* Define this symbol if an external implementation of the default callbacks | ||
is used */ | ||
#undef USE_EXTERNAL_DEFAULT_CALLBACKS | ||
|
||
/* Define this symbol to force the use of the (unsigned) __int128 based wide | ||
multiplication implementation */ | ||
#undef USE_FORCE_WIDEMUL_INT128 | ||
|
||
/* Define this symbol to force the use of the (u)int64_t based wide | ||
multiplication implementation */ | ||
#undef USE_FORCE_WIDEMUL_INT64 | ||
|
||
/* Version number of package */ | ||
#undef VERSION | ||
|
||
#endif /*LIBSECP256K1_CONFIG_H*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
include_HEADERS += include/secp256k1_batch.h | ||
noinst_HEADERS += src/modules/batch/main_impl.h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#ifndef SECP256K1_MODULE_BATCH_MAIN_H | ||
#define SECP256K1_MODULE_BATCH_MAIN_H | ||
|
||
#include "include/secp256k1_batch.h" | ||
|
||
#endif /* SECP256K1_MODULE_BATCH_MAIN_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
timestamp for src/libsecp256k1-config.h |