Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 508 for bigN (0.05 sec)

  1. src/cmd/cgo/internal/test/issue9400_linux.go

    		// Indicate that signalling is done
    		atomic.StoreInt32(&issue9400.Baton, 0)
    	}()
    
    	// Grow the stack and put down a test pattern
    	const pattern = 0x123456789abcdef
    	var big [1024]uint64 // len must match assembly
    	for i := range big {
    		big[i] = pattern
    	}
    
    	// Disable GC for the duration of the test.
    	// This avoids a potential GC deadlock when spinning in uninterruptible ASM below #49695.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jul 18 19:55:29 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  2. src/crypto/x509/platform_test.go

    		{
    			name: "valid",
    			cert: &Certificate{
    				SerialNumber: big.NewInt(1),
    				DNSNames:     []string{"valid.testing.golang.invalid"},
    				NotBefore:    now.Add(-time.Hour),
    				NotAfter:     now.Add(time.Hour),
    				ExtKeyUsage:  []ExtKeyUsage{ExtKeyUsageServerAuth},
    			},
    		},
    		{
    			name: "valid (with name)",
    			cert: &Certificate{
    				SerialNumber: big.NewInt(1),
    				DNSNames:     []string{"valid.testing.golang.invalid"},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Feb 20 17:18:29 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  3. src/crypto/internal/bigmod/nat_test.go

    	for i := 0; i < b.N; i++ {
    		x.Mul(y, m)
    	}
    }
    
    func BenchmarkExpBig(b *testing.B) {
    	out := new(big.Int)
    	exponentBytes := makeBenchmarkExponent()
    	x := new(big.Int).SetBytes(exponentBytes)
    	e := new(big.Int).SetBytes(exponentBytes)
    	n := new(big.Int).SetBytes(exponentBytes)
    	one := new(big.Int).SetUint64(1)
    	n.Add(n, one)
    
    	b.ResetTimer()
    	for i := 0; i < b.N; i++ {
    		out.Exp(x, e, n)
    	}
    }
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jan 12 00:56:20 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  4. test/fixedbugs/issue15277.go

    package main
    
    import "runtime"
    
    type big [10 << 20]byte
    
    func f(x *big, start int64) {
    	if delta := inuse() - start; delta < 9<<20 {
    		println("after alloc: expected delta at least 9MB, got: ", delta)
    	}
    	runtime.KeepAlive(x)
    	x = nil
    	if delta := inuse() - start; delta > 1<<20 {
    		println("after drop: expected delta below 1MB, got: ", delta)
    	}
    	x = new(big)
    	if delta := inuse() - start; delta < 9<<20 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:25 UTC 2023
    - 851 bytes
    - Viewed (0)
  5. test/fixedbugs/issue20780b.go

    package main
    
    import "fmt"
    
    const N = 2e6
    
    type Big = [N]int
    
    var sink interface{}
    
    func main() {
    	g(0, f(0))
    
    	x1 := f(1)
    	sink = &x1
    	g(1, x1)
    	g(7, f(7))
    	g(1, x1)
    
    	x3 := f(3)
    	sink = &x3
    	g(1, x1)
    	g(3, x3)
    
    	h(f(0), x1, f(2), x3, f(4))
    }
    
    //go:noinline
    func f(k int) (x Big) {
    	for i := range x {
    		x[i] = k*N + i
    	}
    	return
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:25 UTC 2023
    - 860 bytes
    - Viewed (0)
  6. src/crypto/rand/util.go

    			return p, nil
    		}
    	}
    }
    
    // Int returns a uniform random value in [0, max). It panics if max <= 0.
    func Int(rand io.Reader, max *big.Int) (n *big.Int, err error) {
    	if max.Sign() <= 0 {
    		panic("crypto/rand: argument to Int is <= 0")
    	}
    	n = new(big.Int)
    	n.Sub(max, n.SetUint64(1))
    	// bitLen is the maximum bit length needed to encode a value < max.
    	bitLen := n.BitLen()
    	if bitLen == 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 13 17:09:47 UTC 2023
    - 2.4K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/ir/const.go

    )
    
    const (
    	// Maximum size in bits for big.Ints before signaling
    	// overflow and also mantissa precision for big.Floats.
    	ConstPrec = 512
    )
    
    func BigFloat(v constant.Value) *big.Float {
    	f := new(big.Float)
    	f.SetPrec(ConstPrec)
    	switch u := constant.Val(v).(type) {
    	case int64:
    		f.SetInt64(u)
    	case *big.Int:
    		f.SetInt(u)
    	case *big.Float:
    		f.Set(u)
    	case *big.Rat:
    		f.SetRat(u)
    	default:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Sep 12 18:53:26 UTC 2023
    - 4K bytes
    - Viewed (0)
  8. pkg/registry/core/service/allocator/bitmap.go

    	// allocated is a bit array of the allocated items in the range
    	allocated *big.Int
    }
    
    // AllocationBitmap implements Interface and Snapshottable
    var _ Interface = &AllocationBitmap{}
    var _ Snapshottable = &AllocationBitmap{}
    
    // bitAllocator represents a search strategy in the allocation map for a valid item.
    type bitAllocator interface {
    	AllocateBit(allocated *big.Int, max, count int) (int, bool)
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jan 25 20:32:40 UTC 2023
    - 7.6K bytes
    - Viewed (0)
  9. src/crypto/internal/mlkem768/mlkem768_test.go

    func TestZetas(t *testing.T) {
    	ζ := big.NewInt(17)
    	q := big.NewInt(q)
    	for k, zeta := range zetas {
    		// ζ^BitRev7(k) mod q
    		exp := new(big.Int).Exp(ζ, big.NewInt(int64(BitRev7(uint8(k)))), q)
    		if big.NewInt(int64(zeta)).Cmp(exp) != 0 {
    			t.Errorf("zetas[%d] = %v, expected %v", k, zeta, exp)
    		}
    	}
    }
    
    func TestGammas(t *testing.T) {
    	ζ := big.NewInt(17)
    	q := big.NewInt(q)
    	for k, gamma := range gammas {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 06 15:27:18 UTC 2024
    - 10.3K bytes
    - Viewed (0)
  10. platforms/core-configuration/model-core/src/test/groovy/org/gradle/api/internal/provider/DefaultProviderFactoryTest.groovy

            String    | 'hello'
            File      | TEST_FILE
        }
    
        def "can zip two providers"() {
            def big = withValues("big")
            def black = withValues("black")
            def cat = withValues("cat")
    
            when:
            def zipped = providerFactory.zip(
                    providerFactory.zip(big, black) { s1, s2 -> "$s1 $s2" } ,
                    cat) { s1, s2 -> "${s1.capitalize()} ${s2}"}
    
            then:
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Sep 28 09:51:04 UTC 2023
    - 4K bytes
    - Viewed (0)
Back to top