- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 30 for numCPU (0.12 sec)
-
pkg/kubelet/winstats/perfcounter_nodestats.go
NumCores: ProcessorCount(), MemoryCapacity: p.nodeInfo.memoryPhysicalCapacityBytes, MachineID: hostname, SystemUUID: systemUUID, BootID: bootId, }, nil } // runtime.NumCPU() will only return the information for a single Processor Group. // Since a single group can only hold 64 logical processors, this // means when there are more they will be divided into multiple groups.
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Jan 26 18:37:21 UTC 2024 - 9.2K bytes - Viewed (0) -
cmd/kubeadm/app/preflight/checks_test.go
} } func TestNumCPUCheck(t *testing.T) { var tests = []struct { numCPU int numErrors int numWarnings int }{ {0, 0, 0}, {999999999, 1, 0}, } for _, rt := range tests { t.Run(fmt.Sprintf("number of CPUs: %d", rt.numCPU), func(t *testing.T) { warnings, errors := NumCPUCheck{NumCPU: rt.numCPU}.Check() if len(warnings) != rt.numWarnings {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 29 06:58:01 UTC 2024 - 33.5K bytes - Viewed (0) -
src/runtime/syscall_windows_test.go
// in child process fmt.Fprintf(os.Stderr, "%d", runtime.NumCPU()) os.Exit(0) } switch n := runtime.NumberOfProcessors(); { case n < 1: t.Fatalf("system cannot have %d cpu(s)", n) case n == 1: if runtime.NumCPU() != 1 { t.Fatalf("runtime.NumCPU() returns %d on single cpu system", runtime.NumCPU()) } return } const (
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Aug 31 16:31:35 UTC 2023 - 32.5K bytes - Viewed (0) -
src/cmd/gofmt/long_test.go
"strings" "testing" ) var ( root = flag.String("root", runtime.GOROOT(), "test root directory") files = flag.String("files", "", "comma-separated list of files to test") ngo = flag.Int("n", runtime.NumCPU(), "number of goroutines used") verbose = flag.Bool("verbose", false, "verbose mode") nfiles int // number of files processed ) func gofmt(fset *token.FileSet, filename string, src *bytes.Buffer) error {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Sep 12 20:27:28 UTC 2023 - 3.8K bytes - Viewed (0) -
src/time/sleep_test.go
// https://golang.org/issue/38860 func BenchmarkParallelTimerLatency(b *testing.B) { gmp := runtime.GOMAXPROCS(0) if gmp < 2 || runtime.NumCPU() < gmp { b.Skip("skipping with GOMAXPROCS < 2 or NumCPU < GOMAXPROCS") } // allocate memory now to avoid GC interference later. timerCount := gmp - 1 stats := make([]struct { sum float64 max Duration count int64
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 22 16:33:57 UTC 2024 - 22.5K bytes - Viewed (0) -
src/cmd/dist/main.go
gohostarch = "mips64" } default: fatalf("unknown architecture: %s", out) } } if gohostarch == "arm" || gohostarch == "mips64" || gohostarch == "mips64le" { maxbg = min(maxbg, runtime.NumCPU()) } // For deterministic make.bash debugging and for smallest-possible footprint, // pay attention to GOMAXPROCS=1. This was a bad idea for 1.4 bootstrap, but // the bootstrap version is now 1.17+ and thus this is fine.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Jun 22 19:44:52 UTC 2023 - 5.5K bytes - Viewed (0) -
src/runtime/proc_test.go
runtime.Gosched() time.Sleep(time.Millisecond) } c <- true // runtime.UnlockOSThread() is deliberately omitted }() <-c } func TestGoroutineParallelism(t *testing.T) { if runtime.NumCPU() == 1 { // Takes too long, too easy to deadlock, etc. t.Skip("skipping on uniprocessor") } P := 4 N := 10 if testing.Short() { P = 3 N = 3 }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jun 14 00:03:57 UTC 2023 - 25.8K bytes - Viewed (0) -
src/log/log_test.go
return len(p), nil } func BenchmarkConcurrent(b *testing.B) { l := New(discard{}, "prefix: ", Ldate|Ltime|Lmicroseconds|Llongfile|Lmsgprefix) var group sync.WaitGroup for i := runtime.NumCPU(); i > 0; i-- { group.Add(1) go func() { for i := 0; i < b.N; i++ { l.Output(0, "hello, world!") } defer group.Done() }() } group.Wait() }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 21 20:04:37 UTC 2023 - 7.4K bytes - Viewed (0) -
src/runtime/gc_test.go
<-teardown return } *n-- countpwg(n, ready, teardown) } func TestMemoryLimit(t *testing.T) { if testing.Short() { t.Skip("stress test that takes time to run") } if runtime.NumCPU() < 4 { t.Skip("want at least 4 CPUs for this test") } got := runTestProg(t, "testprog", "GCMemoryLimit") want := "OK\n" if got != want { t.Fatalf("expected %q, but got %q", want, got) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jun 05 22:33:52 UTC 2024 - 17.6K bytes - Viewed (0) -
src/sync/atomic/atomic_test.go
} c <- 1 }() } for p := 0; p < procs; p++ { <-c } } } func TestStoreLoadSeqCst32(t *testing.T) { if runtime.NumCPU() == 1 { t.Skipf("Skipping test on %v processor machine", runtime.NumCPU()) } defer runtime.GOMAXPROCS(runtime.GOMAXPROCS(4)) N := int32(1e3) if testing.Short() { N = int32(1e2) } c := make(chan bool, 2) X := [2]int32{}
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 17 18:37:29 UTC 2024 - 71.4K bytes - Viewed (0)