Help us shape the future of Go! Take the 2026 Go Developer Survey

sync

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2026 License: Apache-2.0 Imports: 4 Imported by: 3

Documentation

Index

Constants

View Source
const (
	LLGoFiles   = "_wrap/pthd.c"
	LLGoPackage = "link"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Cond

type Cond C.pthread_cond_t

Cond is a condition variable.

func (*Cond) Broadcast

func (c *Cond) Broadcast() c.Int

llgo:link (*Cond).Broadcast C.pthread_cond_broadcast

func (*Cond) Destroy

func (c *Cond) Destroy()

llgo:link (*Cond).Destroy C.pthread_cond_destroy

func (*Cond) Init

func (c *Cond) Init(attr *CondAttr) c.Int

llgo:link (*Cond).Init C.pthread_cond_init

func (*Cond) Signal

func (c *Cond) Signal() c.Int

llgo:link (*Cond).Signal C.pthread_cond_signal

func (*Cond) TimedWait

func (c *Cond) TimedWait(m *Mutex, abstime *time.Timespec) c.Int

llgo:link (*Cond).TimedWait C.pthread_cond_timedwait

func (*Cond) Wait

func (c *Cond) Wait(m *Mutex) c.Int

llgo:link (*Cond).Wait C.pthread_cond_wait

type CondAttr

type CondAttr C.pthread_condattr_t

CondAttr is a condition variable attribute object.

func (*CondAttr) Destroy

func (a *CondAttr) Destroy()

llgo:link (*CondAttr).Destroy C.pthread_condattr_destroy

func (*CondAttr) GetClock

func (a *CondAttr) GetClock(clock *time.ClockidT) c.Int

llgo:link (*CondAttr).GetClock C.pthread_condattr_getclock

func (*CondAttr) Init

func (a *CondAttr) Init(attr *CondAttr) c.Int

llgo:link (*CondAttr).Init C.pthread_condattr_init

func (*CondAttr) SetClock

func (a *CondAttr) SetClock(clock time.ClockidT) c.Int

llgo:link (*CondAttr).SetClock C.pthread_condattr_setclock

type Mutex

type Mutex C.pthread_mutex_t

Mutex is a mutual exclusion lock.

func (*Mutex) Destroy

func (m *Mutex) Destroy()

llgo:link (*Mutex).Destroy C.pthread_mutex_destroy

func (*Mutex) Init

func (m *Mutex) Init(attr *MutexAttr) c.Int

llgo:link (*Mutex).Init C.pthread_mutex_init

func (*Mutex) Lock

func (m *Mutex) Lock()

llgo:link (*Mutex).Lock C.wrap_pthread_mutex_lock

func (*Mutex) TryLock

func (m *Mutex) TryLock() c.Int

llgo:link (*Mutex).TryLock C.pthread_mutex_trylock

func (*Mutex) Unlock

func (m *Mutex) Unlock()

llgo:link (*Mutex).Unlock C.wrap_pthread_mutex_unlock

type MutexAttr

type MutexAttr C.pthread_mutexattr_t

MutexAttr is a mutex attribute object.

func (*MutexAttr) Destroy

func (a *MutexAttr) Destroy()

llgo:link (*MutexAttr).Destroy C.pthread_mutexattr_destroy

func (*MutexAttr) Init

func (a *MutexAttr) Init(attr *MutexAttr) c.Int

llgo:link (*MutexAttr).Init C.pthread_mutexattr_init

func (*MutexAttr) SetType

func (a *MutexAttr) SetType(typ MutexType) c.Int

llgo:link (*MutexAttr).SetType C.pthread_mutexattr_settype

type MutexType

type MutexType c.Int
const (
	MUTEX_NORMAL     MutexType = C.PTHREAD_MUTEX_NORMAL
	MUTEX_ERRORCHECK MutexType = C.PTHREAD_MUTEX_ERRORCHECK
	MUTEX_RECURSIVE  MutexType = C.PTHREAD_MUTEX_RECURSIVE
	MUTEX_DEFAULT    MutexType = C.PTHREAD_MUTEX_DEFAULT
)

type Once

type Once C.pthread_once_t

Once is an object that will perform exactly one action.

var OnceInit Once

func (*Once) Do

func (o *Once) Do(f func()) c.Int

llgo:link (*Once).Do C.pthread_once

type RWLock

type RWLock C.pthread_rwlock_t

RWLock is a read-write lock.

func (*RWLock) Destroy

func (rw *RWLock) Destroy()

llgo:link (*RWLock).Destroy C.pthread_rwlock_destroy

func (*RWLock) Init

func (rw *RWLock) Init(attr *RWLockAttr) c.Int

llgo:link (*RWLock).Init C.pthread_rwlock_init

func (*RWLock) Lock

func (rw *RWLock) Lock()

llgo:link (*RWLock).Lock C.pthread_rwlock_wrlock

func (*RWLock) RLock

func (rw *RWLock) RLock()

llgo:link (*RWLock).RLock C.pthread_rwlock_rdlock

func (*RWLock) RUnlock

func (rw *RWLock) RUnlock()

llgo:link (*RWLock).RUnlock C.pthread_rwlock_unlock

func (*RWLock) TryLock

func (rw *RWLock) TryLock() c.Int

llgo:link (*RWLock).TryLock C.pthread_rwlock_trywrlock

func (*RWLock) TryRLock

func (rw *RWLock) TryRLock() c.Int

llgo:link (*RWLock).TryRLock C.pthread_rwlock_tryrdlock

func (*RWLock) Unlock

func (rw *RWLock) Unlock()

llgo:link (*RWLock).Unlock C.pthread_rwlock_unlock

type RWLockAttr

type RWLockAttr C.pthread_rwlockattr_t

RWLockAttr is a read-write lock attribute object.

func (*RWLockAttr) Destroy

func (a *RWLockAttr) Destroy()

llgo:link (*RWLockAttr).Destroy C.pthread_rwlockattr_destroy

func (*RWLockAttr) GetPShared

func (a *RWLockAttr) GetPShared(pshared *c.Int) c.Int

llgo:link (*RWLockAttr).GetPShared C.pthread_rwlockattr_getpshared

func (*RWLockAttr) Init

func (a *RWLockAttr) Init(attr *RWLockAttr) c.Int

llgo:link (*RWLockAttr).Init C.pthread_rwlockattr_init

func (*RWLockAttr) SetPShared

func (a *RWLockAttr) SetPShared(pshared c.Int) c.Int

llgo:link (*RWLockAttr).SetPShared C.pthread_rwlockattr_setpshared

Jump to

Keyboard shortcuts

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