MCPcopy
hub / github.com/google/uuid / BenchmarkUUID_NewPooled

Function BenchmarkUUID_NewPooled

uuid_test.go:757–767  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

755}
756
757func BenchmarkUUID_NewPooled(b *testing.B) {
758 EnableRandPool()
759 b.RunParallel(func(pb *testing.PB) {
760 for pb.Next() {
761 _, err := NewRandom()
762 if err != nil {
763 b.Fatal(err)
764 }
765 }
766 })
767}
768
769func BenchmarkUUIDs_Strings(b *testing.B) {
770 uuid1, err := Parse("f47ac10b-58cc-0372-8567-0e02b2c3d479")

Callers

nothing calls this directly

Calls 2

EnableRandPoolFunction · 0.85
NewRandomFunction · 0.85

Tested by

no test coverage detected