mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-25 14:16:44 +00:00
cleanup readme
This commit is contained in:
parent
74130f7018
commit
f8cd00314e
1 changed files with 2 additions and 4 deletions
|
|
@ -15,9 +15,9 @@ You need to have GMP development libraries installed on your system:
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
This package provides a GMP-backed implementation for modular exponentiation using direct C calls for maximum performance. The API can be expanded, however right now, the main usage is for the modexp precompile.
|
This package provides a GMP-backed implementation for modular exponentiation using a direct C call to avoid multiple calls to cgo. The main usage is for the modexp precompile.
|
||||||
|
|
||||||
### Byte Array Interface (Recommended)
|
### Byte Array Interface
|
||||||
|
|
||||||
```go
|
```go
|
||||||
import "github.com/ethereum/go-ethereum/crypto/modexp/gmp"
|
import "github.com/ethereum/go-ethereum/crypto/modexp/gmp"
|
||||||
|
|
@ -33,8 +33,6 @@ if err != nil {
|
||||||
// result = 24 (2^10 mod 1000)
|
// result = 24 (2^10 mod 1000)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## Testing
|
## Testing
|
||||||
|
|
||||||
Run tests from the go-ethereum root directory:
|
Run tests from the go-ethereum root directory:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue