Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 16 for cputicks (0.15 sec)

  1. src/runtime/runtime.go

    //
    // Must not run concurrently with ticksPerSecond.
    func (t *ticksType) init() {
    	lock(&ticks.lock)
    	t.startTime = nanotime()
    	t.startTicks = cputicks()
    	unlock(&ticks.lock)
    }
    
    // minTimeForTicksPerSecond is the minimum elapsed time we require to consider our ticksPerSecond
    // measurement to be of decent enough quality for profiling.
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:16:47 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  2. src/runtime/sema.go

    	t0 := int64(0)
    	s.releasetime = 0
    	s.acquiretime = 0
    	s.ticket = 0
    	if profile&semaBlockProfile != 0 && blockprofilerate > 0 {
    		t0 = cputicks()
    		s.releasetime = -1
    	}
    	if profile&semaMutexProfile != 0 && mutexprofilerate > 0 {
    		if t0 == 0 {
    			t0 = cputicks()
    		}
    		s.acquiretime = t0
    	}
    	for {
    		lockWithRank(&root.lock, lockRankRoot)
    		// Add ourselves to nwait to disable "easy case" in semrelease.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 19K bytes
    - Viewed (0)
  3. src/runtime/chan.go

    	// chanrecv() and closechan() to update this thread's view of c.closed and full().
    	if !block && c.closed == 0 && full(c) {
    		return false
    	}
    
    	var t0 int64
    	if blockprofilerate > 0 {
    		t0 = cputicks()
    	}
    
    	lock(&c.lock)
    
    	if c.closed != 0 {
    		unlock(&c.lock)
    		panic(plainError("send on closed channel"))
    	}
    
    	if sg := c.recvq.dequeue(); sg != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:16:50 UTC 2024
    - 25.9K bytes
    - Viewed (0)
  4. src/runtime/metrics_test.go

    					// The test imposes a delay with usleep, verified with calls to
    					// nanotime. Compare against the runtime/metrics package's view
    					// (based on nanotime) rather than runtime/pprof's view (based
    					// on cputicks).
    					t.Errorf("runtime/metrics reported less than the known minimum contention duration (%fs < %fs)", have, want)
    				}
    			})
    			if have, want := n, int64(len(mus)); have != want {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 17:52:17 UTC 2024
    - 45K bytes
    - Viewed (0)
  5. src/runtime/select.go

    		pcs = pc1[:ncases:ncases]
    	}
    	casePC := func(casi int) uintptr {
    		if pcs == nil {
    			return 0
    		}
    		return pcs[casi]
    	}
    
    	var t0 int64
    	if blockprofilerate > 0 {
    		t0 = cputicks()
    	}
    
    	// The compiler rewrites selects that statically have
    	// only 0 or 1 cases plus default into simpler constructs.
    	// The only way we can end up with such small sel.ncase
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Mar 13 21:36:04 UTC 2024
    - 15K bytes
    - Viewed (0)
  6. src/runtime/debuglog.go

    // call with "if dlogEnabled".
    //
    //go:nosplit
    //go:nowritebarrierrec
    func dlog() *dlogger {
    	if !dlogEnabled {
    		return nil
    	}
    
    	// Get the time.
    	tick, nano := uint64(cputicks()), uint64(nanotime())
    
    	// Try to get a cached logger.
    	l := getCachedDlogger()
    
    	// If we couldn't get a cached logger, try to get one from the
    	// global pool.
    	if l == nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 15:10:48 UTC 2024
    - 18.3K bytes
    - Viewed (0)
  7. src/runtime/asm_riscv64.s

    	CALL	runtime·mstart0(SB)
    	RET // not reached
    
    // void setg_gcc(G*); set g called from gcc with g in A0
    TEXT setg_gcc<>(SB),NOSPLIT,$0-0
    	MOV	A0, g
    	CALL	runtime·save_g(SB)
    	RET
    
    // func cputicks() int64
    TEXT runtime·cputicks(SB),NOSPLIT,$0-8
    	// RDTIME to emulate cpu ticks
    	// RDCYCLE reads counter that is per HART(core) based
    	// according to the riscv manual, see issue 46737
    	RDTIME	A0
    	MOV	A0, ret+0(FP)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 09 13:57:06 UTC 2023
    - 27K bytes
    - Viewed (0)
  8. src/runtime/asm_loong64.s

    	BREAK
    	RET
    
    TEXT runtime·asminit(SB),NOSPLIT|NOFRAME,$0-0
    	RET
    
    TEXT runtime·mstart(SB),NOSPLIT|TOPFRAME,$0
    	JAL     runtime·mstart0(SB)
    	RET // not reached
    
    // func cputicks() int64
    TEXT runtime·cputicks(SB),NOSPLIT,$0-8
    	RDTIMED	R0, R4
    	MOVV	R4, ret+0(FP)
    	RET
    
    /*
     *  go-routine
     */
    
    // void gogo(Gobuf*)
    // restore state from Gobuf; longjmp
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 13 15:04:25 UTC 2024
    - 26.5K bytes
    - Viewed (0)
  9. src/runtime/asm_386.s

    	get_tls(CX)
    	MOVL	g(CX), AX
    	CMPL	(g_stack+stack_hi)(AX), SP
    	JHI	2(PC)
    	CALL	runtime·abort(SB)
    	CMPL	SP, (g_stack+stack_lo)(AX)
    	JHI	2(PC)
    	CALL	runtime·abort(SB)
    	RET
    
    // func cputicks() int64
    TEXT runtime·cputicks(SB),NOSPLIT,$0-8
    	// LFENCE/MFENCE instruction support is dependent on SSE2.
    	// When no SSE2 support is present do not enforce any serialization
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 15 15:45:13 UTC 2024
    - 43.1K bytes
    - Viewed (0)
  10. src/index/suffixarray/suffixarray_test.go

    	for i := 0; i < b.N; i++ {
    		New(data)
    	}
    }
    
    func makeText(name string) ([]byte, error) {
    	var data []byte
    	switch name {
    	case "opticks":
    		var err error
    		data, err = os.ReadFile("../../testdata/Isaac.Newton-Opticks.txt")
    		if err != nil {
    			return nil, err
    		}
    	case "go":
    		err := filepath.WalkDir("../..", func(path string, info fs.DirEntry, err error) error {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 14.1K bytes
    - Viewed (0)
Back to top