Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 88 for setBig (0.1 sec)

  1. src/crypto/internal/bigmod/nat_test.go

    	N, _ := NewModulusFromBig(n)
    	A := NewNat().setBig(a).ExpandFor(N)
    	B := NewNat().setBig(b).ExpandFor(N)
    
    	if A.Mul(B, N).IsZero() != 1 {
    		t.Error("a * b mod (a * b) != 0")
    	}
    
    	i := new(big.Int).ModInverse(a, b)
    	N, _ = NewModulusFromBig(b)
    	A = NewNat().setBig(a).ExpandFor(N)
    	I := NewNat().setBig(i).ExpandFor(N)
    	one := NewNat().setBig(big.NewInt(1)).ExpandFor(N)
    
    	if A.Mul(I, N).Equal(one) != 1 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jan 12 00:56:20 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  2. src/runtime/stack_test.go

    		}
    	}
    }
    
    func testDeferPtrsGoexit(c chan int, i int) {
    	var y int
    	defer func() {
    		c <- y
    	}()
    	defer setBig(&y, 42, bigBuf{})
    	useStackAndCall(i, Goexit)
    }
    
    func setBig(p *int, x int, b bigBuf) {
    	*p = x
    }
    
    // TestDeferPtrsPanic is like TestDeferPtrsGoexit, but it's using panic instead
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jun 14 00:03:57 UTC 2023
    - 23.1K bytes
    - Viewed (0)
  3. src/crypto/internal/bigmod/nat.go

    func (x *Nat) set(y *Nat) *Nat {
    	x.reset(len(y.limbs))
    	copy(x.limbs, y.limbs)
    	return x
    }
    
    // setBig assigns x = n, optionally resizing n to the appropriate size.
    //
    // The announced length of x is set based on the actual bit size of the input,
    // ignoring leading zeroes.
    func (x *Nat) setBig(n *big.Int) *Nat {
    	limbs := n.Bits()
    	x.reset(len(limbs))
    	for i := range limbs {
    		x.limbs[i] = uint(limbs[i])
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 13 18:57:38 UTC 2024
    - 24K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/types/size.go

    	case TFLOAT32:
    		w = 4
    		t.floatRegs = 1
    		t.setAlg(AFLOAT32)
    
    	case TFLOAT64:
    		w = 8
    		t.align = uint8(RegSize)
    		t.floatRegs = 1
    		t.setAlg(AFLOAT64)
    
    	case TCOMPLEX64:
    		w = 8
    		t.align = 4
    		t.floatRegs = 2
    		t.setAlg(ACPLX64)
    
    	case TCOMPLEX128:
    		w = 16
    		t.align = uint8(RegSize)
    		t.floatRegs = 2
    		t.setAlg(ACPLX128)
    
    	case TPTR:
    		w = int64(PtrSize)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 15K bytes
    - Viewed (0)
  5. src/runtime/os_netbsd.go

    	var uc ucontextt
    	getcontext(unsafe.Pointer(&uc))
    
    	// _UC_SIGMASK does not seem to work here.
    	// It would be nice if _UC_SIGMASK and _UC_STACK
    	// worked so that we could do all the work setting
    	// the sigmask and the stack here, instead of setting
    	// the mask here and the stack in netbsdMstart.
    	// For now do the blocking manually.
    	uc.uc_flags = _UC_SIGMASK | _UC_CPU
    	uc.uc_link = nil
    	uc.uc_sigmask = sigset_all
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 10.1K bytes
    - Viewed (0)
  6. src/runtime/signal_unix.go

    		// it may hit stack split that is not expected here.
    		if gp != nil {
    			setg(nil)
    		}
    		badsignal(uintptr(sig), c)
    		// Restore g
    		if gp != nil {
    			setg(gp)
    		}
    		return
    	}
    
    	setg(gp.m.gsignal)
    
    	// If some non-Go code called sigaltstack, adjust.
    	var gsignalStack gsignalStack
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 10 16:04:54 UTC 2024
    - 45K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/math/BigIntegerMathTest.java

            assertTrue(ZERO.setBit(result).compareTo(x) <= 0);
            assertTrue(ZERO.setBit(result + 1).compareTo(x) > 0);
          }
        }
      }
    
      public void testLog2Ceiling() {
        for (BigInteger x : POSITIVE_BIGINTEGER_CANDIDATES) {
          for (RoundingMode mode : asList(CEILING, UP)) {
            int result = BigIntegerMath.log2(x, mode);
            assertTrue(ZERO.setBit(result).compareTo(x) >= 0);
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 17 17:58:33 UTC 2024
    - 27.8K bytes
    - Viewed (0)
  8. src/runtime/os_freebsd.go

    }
    
    // See os_freebsd2.go, os_freebsd_amd64.go for setsig function
    
    //go:nosplit
    //go:nowritebarrierrec
    func setsigstack(i uint32) {
    	var sa sigactiont
    	sigaction(i, nil, &sa)
    	if sa.sa_flags&_SA_ONSTACK != 0 {
    		return
    	}
    	sa.sa_flags |= _SA_ONSTACK
    	sigaction(i, &sa, nil)
    }
    
    //go:nosplit
    //go:nowritebarrierrec
    func getsig(i uint32) uintptr {
    	var sa sigactiont
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Dec 05 20:34:30 UTC 2023
    - 11.6K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/ssa/shortcircuit.go

    				if p.Controls[0] != a {
    					continue
    				}
    				if e.i == 0 {
    					if ct == nil {
    						ct = f.ConstBool(f.Config.Types.Bool, true)
    					}
    					v.SetArg(i, ct)
    				} else {
    					if cf == nil {
    						cf = f.ConstBool(f.Config.Types.Bool, false)
    					}
    					v.SetArg(i, cf)
    				}
    			}
    		}
    	}
    
    	// Step 2: Redirect control flow around known branches.
    	// p:
    	//   ... goto b ...
    	// b: <- p ...
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 03 17:47:02 UTC 2022
    - 12.6K bytes
    - Viewed (0)
  10. src/runtime/os_darwin.go

    	_SIG_SETMASK = 3
    	_SS_DISABLE  = 4
    )
    
    //extern SigTabTT runtimeĀ·sigtab[];
    
    type sigset uint32
    
    var sigset_all = ^sigset(0)
    
    //go:nosplit
    //go:nowritebarrierrec
    func setsig(i uint32, fn uintptr) {
    	var sa usigactiont
    	sa.sa_flags = _SA_SIGINFO | _SA_ONSTACK | _SA_RESTART
    	sa.sa_mask = ^uint32(0)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Dec 05 20:34:30 UTC 2023
    - 11.9K bytes
    - Viewed (0)
Back to top