Documentation ¶
Index ¶
- Constants
- func Assert(assertion bool, msg string, args ...interface{})
- func FrSliceToString(slice []fr.Element) string
- func FrToGenericArray(slice []fr.Element) []interface{}
- func GetChallenge(challengeSeed []fr.Element) fr.Element
- func GetPath(p string) (string, error)
- func IntSliceToString(slice []int) string
- func Log2Ceil(a int) int
- func Log2Floor(a int) int
- func Max(a int, b int) int
- func Min(a int, b int) int
- func Parallelize(nbIterations int, work func(int, int), maxCpus ...int)
- func ProfileTrace(b *testing.B, profiled, traced bool, fn func())
- func RandomFrArray(size int) []fr.Element
- func TryDispatch(nbIteration, minTaskSize int, dispatch func(start, stop int)) int
- func Uint64ToFr(x uint64) fr.Element
- func UintSliceToString(slice []uint) string
- type TimeTracker
Constants ¶
const GKR_MIMC string = "gkr-mimc"
Variables ¶
This section is empty.
Functions ¶
func FrSliceToString ¶
FrSliceToString pretty prints a slice of fr.Element to ease debugging
func FrToGenericArray ¶
FrToGenericArray downcast to an slice of interface
func GetChallenge ¶
GetChallenge returns a interaction challenge
func GetPath ¶
Helper to create to a file, and does a few checks Ensure it does not create a file from outside the repo The path should be specified assuming it is relative to the root of the project
func IntSliceToString ¶
IntSliceToString pretty-prints a slice of int for debugging
func Parallelize ¶
Parallelize process in parallel the work function
func ProfileTrace ¶
ProfileTrace run the benchmark function with optionally, benchmarking and tracing
func TryDispatch ¶
Split the large task in smaller chunks appropriately, and `dispatch` for all`. Usefull to send jobs to a worker pool, returns `true`. If it's not practical to dispatch asynchronously, does nothing and returns `0`
func Uint64ToFr ¶
Uint64ToFr allows to quickly create fr.Element
func UintSliceToString ¶
UintSliceToString pretty-prints a slice of uint for debugging
Types ¶
type TimeTracker ¶
type TimeTracker struct {
// contains filtered or unexported fields
}
func NewTimer ¶
func NewTimer(label string) TimeTracker
func (TimeTracker) Close ¶
func (t TimeTracker) Close()