Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 415 for SWAP (0.08 sec)

  1. src/sync/atomic/type.go

    // Store atomically stores val into x.
    func (x *Bool) Store(val bool) { StoreUint32(&x.v, b32(val)) }
    
    // Swap atomically stores new into x and returns the previous value.
    func (x *Bool) Swap(new bool) (old bool) { return SwapUint32(&x.v, b32(new)) != 0 }
    
    // CompareAndSwap executes the compare-and-swap operation for the boolean value x.
    func (x *Bool) CompareAndSwap(old, new bool) (swapped bool) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:37:29 UTC 2024
    - 8.5K bytes
    - Viewed (0)
  2. src/crypto/ecdh/x25519.go

    	e[31] |= 64
    
    	var x1, x2, z2, x3, z3, tmp0, tmp1 field.Element
    	x1.SetBytes(point[:])
    	x2.One()
    	x3.Set(&x1)
    	z3.One()
    
    	swap := 0
    	for pos := 254; pos >= 0; pos-- {
    		b := e[pos/8] >> uint(pos&7)
    		b &= 1
    		swap ^= int(b)
    		x2.Swap(&x3, swap)
    		z2.Swap(&z3, swap)
    		swap = int(b)
    
    		tmp0.Subtract(&x3, &z3)
    		tmp1.Subtract(&x2, &z2)
    		x2.Add(&x2, &z2)
    		z2.Add(&x3, &z3)
    		z3.Multiply(&tmp0, &x2)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 13 17:09:47 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  3. test/fixedbugs/bug064.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package main
    
    func
    swap(x, y int) (u, v int) {
    	return y, x
    }
    
    func
    main() {
    	a := 1;
    	b := 2;
    	a, b = swap(swap(a, b));
    	if a != 2 || b != 1 {
    		panic("bad swap");
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Feb 18 21:15:42 UTC 2012
    - 342 bytes
    - Viewed (0)
  4. pkg/kubelet/metrics/collectors/resource_metrics.go

    	if s.Swap == nil || s.Swap.SwapUsageBytes == nil {
    		return
    	}
    
    	ch <- metrics.NewLazyMetricWithTimestamp(s.Swap.Time.Time,
    		metrics.NewLazyConstMetric(containerSwapUsageDesc, metrics.GaugeValue,
    			float64(*s.Swap.SwapUsageBytes), s.Name, pod.PodRef.Name, pod.PodRef.Namespace))
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Sep 08 07:13:37 UTC 2023
    - 9.2K bytes
    - Viewed (1)
  5. src/sort/zsortfunc.go

    	data.Swap(a, pivot)
    	i, j := a+1, b-1 // i and j are inclusive of the elements remaining to be partitioned
    
    	for i <= j && data.Less(i, a) {
    		i++
    	}
    	for i <= j && !data.Less(j, a) {
    		j--
    	}
    	if i > j {
    		data.Swap(j, a)
    		return j, true
    	}
    	data.Swap(i, j)
    	i++
    	j--
    
    	for {
    		for i <= j && data.Less(i, a) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 13 20:16:24 UTC 2022
    - 11.5K bytes
    - Viewed (0)
  6. src/sort/gen_sort_variants.go

    	{{Swap "data" "a" "pivot"}}
    	i, j := a+1, b-1 // i and j are inclusive of the elements remaining to be partitioned
    
    	for i <= j && {{Less "data" "i" "a"}} {
    		i++
    	}
    	for i <= j && !{{Less "data" "j" "a"}} {
    		j--
    	}
    	if i > j {
    		{{Swap "data" "j" "a"}}
    		return j, true
    	}
    	{{Swap "data" "i" "j"}}
    	i++
    	j--
    
    	for {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:27 UTC 2023
    - 19.6K bytes
    - Viewed (0)
  7. pkg/kubelet/util/swap/swap_util.go

    func isSwapOnAccordingToProcSwaps(procSwapsContent []byte) bool {
    	procSwapsContent = bytes.TrimSpace(procSwapsContent) // extra trailing \n
    	procSwapsStr := string(procSwapsContent)
    	procSwapsLines := strings.Split(procSwapsStr, "\n")
    
    	// If there is more than one line (table headers) in /proc/swaps then swap is enabled
    	klog.InfoS("Swap is on", "/proc/swaps contents", procSwapsStr)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon May 27 10:07:06 UTC 2024
    - 4.2K bytes
    - Viewed (0)
  8. src/sort/zsortinterface.go

    	data.Swap(a, pivot)
    	i, j := a+1, b-1 // i and j are inclusive of the elements remaining to be partitioned
    
    	for i <= j && data.Less(i, a) {
    		i++
    	}
    	for i <= j && !data.Less(j, a) {
    		j--
    	}
    	if i > j {
    		data.Swap(j, a)
    		return j, true
    	}
    	data.Swap(i, j)
    	i++
    	j--
    
    	for {
    		for i <= j && data.Less(i, a) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 13 20:16:24 UTC 2022
    - 11.2K bytes
    - Viewed (0)
  9. test/simassign.go

    			printit()
    			panic("fail")
    		}
    	}
    
    	if !testit(false) {
    		print("final val\n")
    		printit()
    		panic("fail")
    	}
    
    	a, b = swap(1, 2)
    	if a != 2 || b != 1 {
    		panic("bad swap")
    	}
    
    	a, b = swap(swap(a, b))
    	if a != 2 || b != 1 {
    		panic("bad swap")
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Feb 24 00:48:19 UTC 2012
    - 1.1K bytes
    - Viewed (0)
  10. pkg/kubelet/server/stats/summary_test.go

    	assert.Equal(summary.Node.StartTime, systemBootTime)
    	assert.Equal(summary.Node.CPU, cgroupStatsMap["/"].cs.CPU)
    	assert.Equal(summary.Node.Memory, cgroupStatsMap["/"].cs.Memory)
    	assert.Equal(summary.Node.Swap, cgroupStatsMap["/"].cs.Swap)
    	assert.Equal(summary.Node.Network, cgroupStatsMap["/"].ns)
    	assert.Equal(summary.Node.Fs, rootFsStats)
    	assert.Equal(summary.Node.Runtime, &statsapi.RuntimeStats{ContainerFs: imageFsStats, ImageFs: imageFsStats})
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 08:12:16 UTC 2024
    - 15.1K bytes
    - Viewed (0)
Back to top