Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 650 for Madvise (0.12 sec)

  1. src/runtime/mem_linux.go

    		// madvise will round this to any physical page
    		// *covered* by this range, so an unaligned madvise
    		// will release more memory than intended.
    		throw("unaligned sysUnused")
    	}
    
    	advise := atomic.Load(&adviseUnused)
    	if debug.madvdontneed != 0 && advise != madviseUnsupported {
    		advise = _MADV_DONTNEED
    	}
    	switch advise {
    	case _MADV_FREE:
    		if madvise(v, n, _MADV_FREE) == 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 5K bytes
    - Viewed (0)
  2. src/runtime/mem_darwin.go

    	// accounting information about the process to task_info.
    	madvise(v, n, _MADV_FREE_REUSABLE)
    }
    
    func sysUsedOS(v unsafe.Pointer, n uintptr) {
    	// MADV_FREE_REUSE is necessary to keep the kernel's accounting
    	// accurate. If called on any memory region that hasn't been
    	// MADV_FREE_REUSABLE'd, it's a no-op.
    	madvise(v, n, _MADV_FREE_REUSE)
    }
    
    func sysHugePageOS(v unsafe.Pointer, n uintptr) {
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 22 19:05:10 UTC 2023
    - 2K bytes
    - Viewed (0)
  3. src/runtime/mem_bsd.go

    	if err != 0 {
    		return nil
    	}
    	return v
    }
    
    func sysUnusedOS(v unsafe.Pointer, n uintptr) {
    	if debug.madvdontneed != 0 {
    		madvise(v, n, _MADV_DONTNEED)
    	} else {
    		madvise(v, n, _MADV_FREE)
    	}
    }
    
    func sysUsedOS(v unsafe.Pointer, n uintptr) {
    }
    
    func sysHugePageOS(v unsafe.Pointer, n uintptr) {
    }
    
    func sysNoHugePageOS(v unsafe.Pointer, n uintptr) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 22 19:05:10 UTC 2023
    - 2.2K bytes
    - Viewed (0)
  4. src/runtime/race/race_darwin_amd64.go

    //go:cgo_import_dynamic mach_task_self_ mach_task_self_ ""
    //go:cgo_import_dynamic mach_timebase_info mach_timebase_info ""
    //go:cgo_import_dynamic mach_vm_region_recurse mach_vm_region_recurse ""
    //go:cgo_import_dynamic madvise madvise ""
    //go:cgo_import_dynamic malloc_num_zones malloc_num_zones ""
    //go:cgo_import_dynamic malloc_zones malloc_zones ""
    //go:cgo_import_dynamic memcpy memcpy ""
    //go:cgo_import_dynamic memset_pattern16 memset_pattern16 ""
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 16 19:29:22 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  5. src/runtime/race/race_darwin_arm64.go

    //go:cgo_import_dynamic mach_task_self_ mach_task_self_ ""
    //go:cgo_import_dynamic mach_timebase_info mach_timebase_info ""
    //go:cgo_import_dynamic mach_vm_region_recurse mach_vm_region_recurse ""
    //go:cgo_import_dynamic madvise madvise ""
    //go:cgo_import_dynamic malloc_num_zones malloc_num_zones ""
    //go:cgo_import_dynamic malloc_zones malloc_zones ""
    //go:cgo_import_dynamic memcpy memcpy ""
    //go:cgo_import_dynamic memset_pattern16 memset_pattern16 ""
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 16 19:29:22 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  6. src/runtime/stubs2.go

    //
    //go:noescape
    func write1(fd uintptr, p unsafe.Pointer, n int32) int32
    
    //go:noescape
    func open(name *byte, mode, perm int32) int32
    
    // return value is only set on linux to be used in osinit().
    func madvise(addr unsafe.Pointer, n uintptr, flags int32) int32
    
    // exitThread terminates the current thread, writing *wait = freeMStack when
    // the stack is safe to reclaim.
    //
    //go:noescape
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 1.1K bytes
    - Viewed (0)
  7. src/runtime/mem_aix.go

    		}
    		if err == _EAGAIN {
    			print("runtime: mmap: too much locked memory (check 'ulimit -l').\n")
    			exit(2)
    		}
    		return nil
    	}
    	return p
    }
    
    func sysUnusedOS(v unsafe.Pointer, n uintptr) {
    	madvise(v, n, _MADV_DONTNEED)
    }
    
    func sysUsedOS(v unsafe.Pointer, n uintptr) {
    }
    
    func sysHugePageOS(v unsafe.Pointer, n uintptr) {
    }
    
    func sysNoHugePageOS(v unsafe.Pointer, n uintptr) {
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 22 19:05:10 UTC 2023
    - 2K bytes
    - Viewed (0)
  8. src/runtime/os_openbsd_syscall2.go

    //
    //go:noescape
    func write1(fd uintptr, p unsafe.Pointer, n int32) int32
    
    //go:noescape
    func open(name *byte, mode, perm int32) int32
    
    // return value is only set on linux to be used in osinit().
    func madvise(addr unsafe.Pointer, n uintptr, flags int32) int32
    
    // exitThread terminates the current thread, writing *wait = freeMStack when
    // the stack is safe to reclaim.
    //
    //go:noescape
    func exitThread(wait *atomic.Uint32)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 2.5K bytes
    - Viewed (0)
  9. src/runtime/os2_aix.go

    		println("syscall munmap failed: ", hex(err))
    		throw("syscall munmap")
    	}
    }
    
    //go:nosplit
    func madvise(addr unsafe.Pointer, n uintptr, flags int32) {
    	r, err := syscall3(&libc_madvise, uintptr(addr), uintptr(n), uintptr(flags))
    	if int32(r) == -1 {
    		println("syscall madvise failed: ", hex(err))
    		throw("syscall madvise")
    	}
    }
    
    func sigaction1(sig, new, old uintptr)
    
    //go:nosplit
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Dec 14 17:22:18 UTC 2023
    - 20.9K bytes
    - Viewed (0)
  10. src/runtime/sys_openbsd2.go

    	KeepAlive(addr) // Just for consistency. Hopefully addr is not a Go address.
    }
    func munmap_trampoline()
    
    //go:nosplit
    //go:cgo_unsafe_args
    func madvise(addr unsafe.Pointer, n uintptr, flags int32) {
    	libcCall(unsafe.Pointer(abi.FuncPCABI0(madvise_trampoline)), unsafe.Pointer(&addr))
    	KeepAlive(addr) // Just for consistency. Hopefully addr is not a Go address.
    }
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 25 19:53:03 UTC 2024
    - 8.7K bytes
    - Viewed (0)
Back to top