cuptiowner

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 4, 2026 License: Apache-2.0 Imports: 6 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package cuptiowner coordinates cooperating metric collectors by CUDA device. Exclusion is a library measurement policy, not a claim that every native API pair is incompatible. It does not reserve external processes or activity tracing.

Index

Constants

This section is empty.

Variables

View Source
var DefaultNsightPerfGlobalRuntimeDirs = []string{
	"/run/nvidia/nsight-perf",
}

DefaultNsightPerfGlobalRuntimeDirs lists the system-wide runtime directories where nvidia-nsight-perf places its router.observer socket.

View Source
var ErrCountersOwnedByNsightPerf = errors.New("counters owned by nvidia-nsight-perf")

ErrCountersOwnedByNsightPerf reports that the NVIDIA Nsight Perf SDK daemon (nvidia-nsight-perf) has bound its router.observer socket and exclusively owns the GPU hardware performance counters.

Functions

func CheckNsightPerfCoexistence

func CheckNsightPerfCoexistence(pkgPrefix string, getenv func(string) string, globalRuntimeDirs []string) error

CheckNsightPerfCoexistence inspects NVIDIA_NSIGHT_PERF_OBSERVER_SOCKET and the global and user-local ($XDG_RUNTIME_DIR) nvidia-nsight-perf runtime directories for an active router.observer socket. When detected, it returns an error wrapping ErrCountersOwnedByNsightPerf and the conflicting socket path before any CUPTI hardware counter API is called.

Types

type Lease

type Lease struct {
	// contains filtered or unexported fields
}

Lease reserves a device until native cleanup succeeds. Do not copy it.

func AcquireDevice

func AcquireDevice(device uint32) (*Lease, error)

AcquireDevice rejects another cooperating metric collector on this ordinal. Device zero is valid. All participants must use CUDA device ordinals.

func (*Lease) Release

func (l *Lease) Release()

Release relinquishes ownership after native cleanup succeeds. It is nil-safe and cannot release a newer owner's lease.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL