Result:
found more than 700 distributions - search limited to the first 2001 files matching your query ( run in 1.058 )


Data-Graph-Shared

 view release on metacpan or  search on metacpan

graph.h  view on Meta::CPAN


/* ================================================================
 * Graph operations (must hold mutex)
 * ================================================================ */

static inline int32_t graph_add_node_locked(GraphHandle *h, int64_t data) {
    int32_t idx = graph_bit_alloc(h->node_bitmap, h->node_bwords, h->hdr->max_nodes);
    if (idx < 0) return -1;
    h->node_data[idx] = data;
    h->node_heads[idx] = GRAPH_NONE;
    __atomic_fetch_add(&h->hdr->node_count, 1, __ATOMIC_RELAXED);
    return idx;
}

static inline int graph_add_edge_locked(GraphHandle *h, uint32_t src, uint32_t dst, int64_t weight) {
    if (src >= h->hdr->max_nodes || dst >= h->hdr->max_nodes) return 0;
    if (!graph_bit_set(h->node_bitmap, src) || !graph_bit_set(h->node_bitmap, dst))
        return 0;
    int32_t eidx = graph_bit_alloc(h->edge_bitmap, h->edge_bwords, h->hdr->max_edges);
    if (eidx < 0) return 0;

graph.h  view on Meta::CPAN

    h->node_heads[src] = (uint32_t)eidx;
    __atomic_fetch_add(&h->hdr->edge_count, 1, __ATOMIC_RELAXED);
    return 1;
}

static inline int graph_remove_node_locked(GraphHandle *h, uint32_t node) {
    if (node >= h->hdr->max_nodes) return 0;
    if (!graph_bit_set(h->node_bitmap, node)) return 0;
    /* free all outgoing edges */
    uint32_t eidx = h->node_heads[node];
    while (eidx != GRAPH_NONE) {

graph.h  view on Meta::CPAN

    graph_bit_free(h->node_bitmap, node);
    __atomic_fetch_sub(&h->hdr->node_count, 1, __ATOMIC_RELAXED);
    return 1;
}

/* Like remove_node_locked, but also splices every other node's adjacency
 * list to drop edges pointing TO `node` (incoming edges). O(N+E). */
static inline int graph_remove_node_full_locked(GraphHandle *h, uint32_t node) {
    if (node >= h->hdr->max_nodes) return 0;
    if (!graph_bit_set(h->node_bitmap, node)) return 0;
    uint32_t max_n = h->hdr->max_nodes;
    for (uint32_t src = 0; src < max_n; src++) {
        if (src == node) continue;

graph.h  view on Meta::CPAN

                slot = &h->edges[eidx].next;
            }
            eidx = next;
        }
    }
    return graph_remove_node_locked(h, node);
}

/* ================================================================
 * Public API (lock + operation + unlock)
 * ================================================================ */

static inline int32_t graph_add_node(GraphHandle *h, int64_t data) {
    graph_mutex_lock(h->hdr);
    int32_t r = graph_add_node_locked(h, data);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    graph_mutex_unlock(h->hdr);
    return r;
}

static inline int graph_add_edge(GraphHandle *h, uint32_t src, uint32_t dst, int64_t weight) {
    graph_mutex_lock(h->hdr);
    int r = graph_add_edge_locked(h, src, dst, weight);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    graph_mutex_unlock(h->hdr);
    return r;
}

static inline int graph_remove_node(GraphHandle *h, uint32_t node) {
    graph_mutex_lock(h->hdr);
    int r = graph_remove_node_locked(h, node);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    graph_mutex_unlock(h->hdr);
    return r;
}

static inline int graph_remove_node_full(GraphHandle *h, uint32_t node) {
    graph_mutex_lock(h->hdr);
    int r = graph_remove_node_full_locked(h, node);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    graph_mutex_unlock(h->hdr);
    return r;
}

 view all matches for this distribution


Data-HashMap-Shared

 view release on metacpan or  search on metacpan

shm_generic.h  view on Meta::CPAN

    uint64_t arena_cap;       /* 72: immutable, read by seqlock string path */
    uint64_t reader_slots_off;/* 80: offset of reader-PID slot table for dead-reader recovery */
    uint8_t  _reserved1[40];  /* 88-127 */

    /* ---- Cache line 2 (128-191): rwlock + write-hot fields ---- */
    uint32_t rwlock;          /* 128: 0=unlocked, 1..0x7FFFFFFF=readers, 0x80000000|pid=writer */
    uint32_t rwlock_waiters;  /* 132 */
    uint32_t size;            /* 136 */
    uint32_t tombstones;      /* 140 */
    uint32_t lru_head;        /* 144: MRU slot index */
    uint32_t lru_tail;        /* 148: LRU slot index */

shm_generic.h  view on Meta::CPAN

#else
    __asm__ volatile("" ::: "memory");
#endif
}

/* Extract writer PID from rwlock value (lower 31 bits when write-locked). */
#define SHM_RWLOCK_WRITER_BIT 0x80000000U
#define SHM_RWLOCK_PID_MASK   0x7FFFFFFFU
#define SHM_RWLOCK_WR(pid)    (SHM_RWLOCK_WRITER_BIT | ((uint32_t)(pid) & SHM_RWLOCK_PID_MASK))

/* Check if a PID is alive. Returns 1 if alive or unknown, 0 if definitely dead. */

shm_generic.h  view on Meta::CPAN

            shm_rwlock_spin_pause();
            continue;
        }
        shm_park_reader(h);
        cur = __atomic_load_n(lock, __ATOMIC_RELAXED);
        /* Sleep when write-locked OR when yielding to waiting writers */
        if (cur >= SHM_RWLOCK_WRITER_BIT || cur == 0) {
            long rc = syscall(SYS_futex, lock, FUTEX_WAIT, cur,
                              &shm_lock_timeout, NULL, 0);
            if (rc == -1 && errno == ETIMEDOUT) {
                shm_unpark_reader(h);

 view all matches for this distribution


Data-Heap-Shared

 view release on metacpan or  search on metacpan

heap.h  view on Meta::CPAN

    uint64_t total_size;
    uint64_t data_off;
    uint8_t  _pad0[32];

    uint32_t size;             /* 64: current element count (futex word for pop) */
    uint32_t mutex;            /* 68: 0=free, HEAP_MUTEX_BIT|pid=locked */
    uint32_t mutex_waiters;    /* 72 */
    uint32_t waiters_pop;      /* 76 */
    uint64_t stat_pushes;      /* 80 */
    uint64_t stat_pops;        /* 88 */
    uint64_t stat_waits;       /* 96 */

 view all matches for this distribution


Data-Histogram-Shared

 view release on metacpan or  search on metacpan

Shared.xs  view on Meta::CPAN

    idx = hist_index_for(h, (int64_t)value);
    if (idx < 0)
        croak("Data::Histogram::Shared->record: value %lld exceeds highest_trackable_value (%lld)",
              (long long)value, (long long)h->hdr->highest);
    hist_rwlock_wrlock(h);
    hist_record_locked(h, (int64_t)value, (int64_t)count);
    total = (IV)h->hdr->total_count;
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    hist_rwlock_wrunlock(h);
    RETVAL = total;
  OUTPUT:

Shared.xs  view on Meta::CPAN

                    croak("Data::Histogram::Shared->record_many: value %lld exceeds highest_trackable_value (%lld)",
                          (long long)v, (long long)h->hdr->highest);
                vals[i] = (int64_t)v;
            }
        }
        hist_rwlock_wrlock(h);                            /* locked region: NO croak-capable calls */
        for (i = 0; i < cnt; i++) hist_record_locked(h, vals[i], 1);
        __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);  /* a call always counts, even an empty batch */
        hist_rwlock_wrunlock(h);
        RETVAL = (UV)cnt;
    }
  OUTPUT:

Shared.xs  view on Meta::CPAN

  PREINIT:
    EXTRACT(self);
    IV v;
  CODE:
    hist_rwlock_rdlock(h);
    v = (IV)hist_value_at_percentile_locked(h, p);
    hist_rwlock_rdunlock(h);
    RETVAL = v;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

  PREINIT:
    EXTRACT(self);
    double m;
  CODE:
    hist_rwlock_rdlock(h);
    m = hist_mean_locked(h);
    hist_rwlock_rdunlock(h);
    RETVAL = m;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    SV *self
  PREINIT:
    EXTRACT(self);
  CODE:
    hist_rwlock_wrlock(h);
    hist_reset_locked(h);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    hist_rwlock_wrunlock(h);

IV
lowest(self)

Shared.xs  view on Meta::CPAN

        highest          = h->hdr->highest;
        sig_figs         = h->hdr->sig_figs;
        bucket_count     = h->hdr->bucket_count;
        sub_bucket_count = h->hdr->sub_bucket_count;
        ops              = h->hdr->stat_ops;
        mean             = hist_mean_locked(h);
        hist_rwlock_rdunlock(h);

        HV *hv = newHV();
        hv_stores(hv, "lowest",           newSViv((IV)lowest));
        hv_stores(hv, "highest",          newSViv((IV)highest));

 view all matches for this distribution


Data-HyperLogLog-Shared

 view release on metacpan or  search on metacpan

Shared.xs  view on Meta::CPAN

    STRLEN n;
    const char *s;
  CODE:
    s = SvPVbyte(item, n);
    hll_rwlock_wrlock(h);
    RETVAL = hll_add_locked(h, s, n);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    hll_rwlock_wrunlock(h);
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

                SV **el = av_fetch(av, (SSize_t)i, 0);
                if (el && *el) ps[i] = SvPVbyte(*el, ls[i]);
                else { ps[i] = ""; ls[i] = 0; }
            }
        }
        hll_rwlock_wrlock(h);                            /* locked region: NO croak-capable calls */
        for (i = 0; i < cnt; i++) added += (UV)hll_add_locked(h, ps[i], ls[i]);
        __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);  /* a call always counts, even an empty batch */
        hll_rwlock_wrunlock(h);
    }
    RETVAL = added;
  OUTPUT:

Shared.xs  view on Meta::CPAN

  PREINIT:
    EXTRACT(self);
    double E;
  CODE:
    hll_rwlock_rdlock(h);
    E = hll_count_locked(h);
    hll_rwlock_rdunlock(h);
    RETVAL = (UV)(E + 0.5);
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    SV *self
  PREINIT:
    EXTRACT(self);
  CODE:
    hll_rwlock_wrlock(h);
    hll_clear_locked(h);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    hll_rwlock_wrunlock(h);

UV
precision(self)

Shared.xs  view on Meta::CPAN

        uint64_t ops;
        uint32_t precision, m;
        /* Snapshot under the lock; do all (croak-capable) Perl allocation after
           releasing it -- so an OOM in newHV/newSVuv can never strand the lock. */
        hll_rwlock_rdlock(h);
        E         = hll_count_locked(h);
        ops       = h->hdr->stat_ops;
        precision = h->hdr->precision;
        m         = h->hdr->m;
        hll_rwlock_rdunlock(h);

 view all matches for this distribution


Data-Intern-Shared

 view release on metacpan or  search on metacpan

Shared.xs  view on Meta::CPAN

    SV *self
  PREINIT:
    EXTRACT(self);
  CODE:
    si_rwlock_wrlock(h);
    si_clear_locked(h);
    si_rwlock_wrunlock(h);

SV *
intern(self, str)
    SV *self

Shared.xs  view on Meta::CPAN

    const char *s;
    int64_t id;
  CODE:
    s = SvPVbyte(str, n);
    si_rwlock_wrlock(h);
    id = si_intern_locked(h, s, n);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    si_rwlock_wrunlock(h);
    RETVAL = (id < 0) ? &PL_sv_undef : newSVuv((UV)id);
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    const char *s;
    uint32_t id;
  CODE:
    s = SvPVbyte(str, n);
    si_rwlock_rdlock(h);
    int found = si_id_of_locked(h, s, n, &id);
    si_rwlock_rdunlock(h);
    RETVAL = found ? newSVuv(id) : &PL_sv_undef;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    const char *s;
    uint32_t id;
  CODE:
    s = SvPVbyte(str, n);
    si_rwlock_rdlock(h);
    RETVAL = si_id_of_locked(h, s, n, &id);
    si_rwlock_rdunlock(h);
  OUTPUT:
    RETVAL

SV *

 view all matches for this distribution


Data-Keys

 view release on metacpan or  search on metacpan

lib/Data/Keys/E/Dir/Lock.pm  view on Meta::CPAN

    my $lock_key = $key;
    $lock_key    =~ s{/}{_}g;
    my $lock_filename = File::Spec->catfile($self->lock_dir, $lock_key);

    $self->_lock_dir_data->{$key}->{'counter'}++;
    # return if already locked
    return
        if ($self->_lock_dir_data->{$key}->{'counter'} != 1);

    my $lock_fh;
    my $num_tries = 0;

lib/Data/Keys/E/Dir/Lock.pm  view on Meta::CPAN

sub unlock {
    my $self = shift;
    my $key  = shift;
    
    if (not $self->_lock_dir_data->{$key}) {
        warn 'unlock("'.$key.'") but is is not locked';
        return;
    };

    $self->_lock_dir_data->{$key}->{'counter'}--;

 view all matches for this distribution


Data-Lock

 view release on metacpan or  search on metacpan

lib/Data/Lock.pm  view on Meta::CPAN

our @EXPORT_OK = qw/dlock dunlock/;

#my @builtin_types = 
#    qw/SCALAR ARRAY HASH CODE REF GLOB LVALUE FORMAT IO VSTRING Regexp/;

for my $locked ( 0, 1 ) {
    my $subname = $locked ? 'dlock' : 'dunlock';
    no strict 'refs';
    *{$subname} = sub {
        no warnings "uninitialized";
        return if $_[1] and Internals::SvREADONLY( $_[0]) == $locked;
        Internals::SvREADONLY( $_[0], $locked );
        return unless my $type = Scalar::Util::reftype( $_[0] );
        for (
              $type eq 'ARRAY' ? @{ $_[0] }
            : $type eq 'HASH'  ? values %{ $_[0] }
            : $type ne 'CODE'  ? ${ $_[0] }
            :                    ()
          )
        {
            &$subname($_, 1) if ref $_;
            Internals::SvREADONLY( $_, $locked );
        }
            $type eq 'ARRAY' ? Internals::SvREADONLY( @{ $_[0] }, $locked )
          : $type eq 'HASH'  ? Internals::SvREADONLY( %{ $_[0] }, $locked )
          : $type ne 'CODE'  ? Internals::SvREADONLY( ${ $_[0] }, $locked )
          :                    undef;
    };
}

1;

 view all matches for this distribution


Data-Log-Shared

 view release on metacpan or  search on metacpan

log.h  view on Meta::CPAN

    uint64_t data_off;         /* 24 */
    uint8_t  _pad0[32];        /* 32-63 */

    uint64_t tail;             /* 64: byte offset past last entry (CAS target) */
    uint64_t count;            /* 72: number of committed entries */
    uint32_t waiters;          /* 80: blocked tailers */
    uint32_t wake_seq;         /* 84: FUTEX_WAIT target (avoids 64-bit count wraparound) */
    uint64_t stat_appends;     /* 88 */
    uint64_t stat_waits;       /* 96 */
    uint64_t stat_timeouts;    /* 104 */
    uint64_t truncation;       /* 112: entries before this offset are invalid */

 view all matches for this distribution


Data-MessagePack-Stream

 view release on metacpan or  search on metacpan

msgpack-3.3.0/include/msgpack/sysdep.h  view on Meta::CPAN

#           define WIN32_LEAN_AND_MEAN
#       endif /* WIN32_LEAN_AND_MEAN */
#   endif
    typedef long _msgpack_atomic_counter_t;
#if defined(_AMD64_) || defined(_M_X64) || defined(_M_ARM64)
#    define _msgpack_sync_decr_and_fetch(ptr) _InterlockedDecrement(ptr)
#    define _msgpack_sync_incr_and_fetch(ptr) _InterlockedIncrement(ptr)
#else
#    define _msgpack_sync_decr_and_fetch(ptr) InterlockedDecrement(ptr)
#    define _msgpack_sync_incr_and_fetch(ptr) InterlockedIncrement(ptr)
#endif
#elif defined(__GNUC__) && ((__GNUC__*10 + __GNUC_MINOR__) < 41)

#   if defined(__cplusplus)
#       define _msgpack_atomic_counter_header "msgpack/gcc_atomic.hpp"

 view all matches for this distribution


Data-MessagePack

 view release on metacpan or  search on metacpan

include/msgpack/sysdep.h  view on Meta::CPAN

#endif

#ifdef _WIN32
#   define _msgpack_atomic_counter_header <windows.h>
    typedef long _msgpack_atomic_counter_t;
#   define _msgpack_sync_decr_and_fetch(ptr) InterlockedDecrement(ptr)
#   define _msgpack_sync_incr_and_fetch(ptr) InterlockedIncrement(ptr)
#elif defined(__GNUC__) && ((__GNUC__*10 + __GNUC_MINOR__) < 41)

#   if defined(__cplusplus)
#       define _msgpack_atomic_counter_header "gcc_atomic.hpp"
#   else

 view all matches for this distribution


Data-NDArray-Shared

 view release on metacpan or  search on metacpan

lib/Data/NDArray/Shared.pm  view on Meta::CPAN

# NDArray -> a NEW (copied) PDL piddle; dims = reverse(shape).
sub to_pdl {
    my ($self) = @_;
    _require_pdl();
    my $p = PDL->new_from_specification(_pdl_ctor($self->dtype)->(), reverse $self->shape);
    ${ $p->get_dataref } = $self->buffer;   # read-locked snapshot
    $p->upd_data;
    return $p;
}

# A NEW shared NDArray copied from a piddle; $path undef => anonymous mapping.

lib/Data/NDArray/Shared.pm  view on Meta::CPAN

first); the dtype and shape follow the piddle's type and C<reverse> of its dims.
C<$path> is the backing file (C<undef> or omitted for an anonymous mapping).

=item * C<< $array->update_from_pdl($piddle) >>

Copy C<$piddle> into this array B<in place> (write-locked). The piddle's type
must match the dtype and its dims must equal C<< reverse($array-E<gt>shape) >>,
else it croaks. Returns the array.

=item * C<< $piddle = $array->as_pdl_alias >>

lib/Data/NDArray/Shared.pm  view on Meta::CPAN

if the module was installed without PDL present it C<croak>s, while the copy
methods above keep working through a runtime C<require PDL>. Reinstall with PDL
installed to enable it.

B<Caveats.> The alias B<bypasses the rwlock>: you must coordinate access
yourself (no other process mutating concurrently), as with any unlocked
shared-memory view. Do not B<resize or retype> the alias (a reshape that grows
it, a type conversion) -- it is a fixed window onto the mapping; use
C<to_pdl>/C<from_pdl> when you want an independent, resizable copy.

=item * C<< $bytes = $array->buffer >>

The raw contiguous data region as a byte string (read-locked snapshot),
row-major C-order -- useful on its own for serialization or IPC, and the basis
for C<to_pdl>. C<< $array->update_from_bytes($bytes) >> is the inverse
(write-locked; the string must be exactly C<< size * itemsize >> bytes).

=back

See F<eg/pdl_interop.pl> for a worked example, including a cross-process PDL
transform on one shared array.

 view all matches for this distribution


Data-OFAC

 view release on metacpan or  search on metacpan

lib/Data/OFAC.pm  view on Meta::CPAN

        individuals and companies owned or controlled by, or acting for or on
        behalf of, targeted countries. It also lists individuals, groups, and
        entities, such as terrorists and narcotics traffickers designated under
        programs that are not country-specific. Collectively, such individuals
        and companies are called "Specially Designated Nationals" or "SDNs."
        Their assets are blocked and U.S. persons are generally prohibited from
        dealing with them.

    This interface is helpful for insitutions that use Perl, and may have a
    need to screen individuals as potential customers.

 view all matches for this distribution


Data-ObjectStore

 view release on metacpan or  search on metacpan

lib/Data/ObjectStore.pm  view on Meta::CPAN


Adds an advisory (flock) lock for each of the unique names given.

=head2 unlock()

Unlocks all names locked by this thread

=head2 sync()

Asks the data provider to sync to persistance.

lib/Data/ObjectStore.pm  view on Meta::CPAN

Adds an advisory (flock) lock for each of the unique names given.
This may not be called twice in a row without an unlock in between.

=head2 unlock

Unlocks all names locked by this thread

=head2 _init

    This is called the first time an object is created. It is not
    called when the object is loaded from storage. This can be used

 view all matches for this distribution


Data-Page-Viewport

 view release on metacpan or  search on metacpan

lib/Data/Page/Viewport.pm  view on Meta::CPAN

	my(@bound) = $page -> offset(- 1) -> bounds();

the call to C<sub offset(- 1)> will have no effect.

That is, when trying to go back past the beginning of the data set, the
bounds will be locked to values within 0 .. data_size.

Similarly, a call which would go beyond the other end of the data set,
will lock the bounds to the same range.

In short, you can't fall off the edge by calling C<sub offset()>.

 view all matches for this distribution


Data-Password-Filter

 view release on metacpan or  search on metacpan

share/dictionary.txt  view on Meta::CPAN

blockage's
blockages
blockbuster
blockbuster's
blockbusters
blocked
blockhead
blockhead's
blockheads
blockhouse
blockhouse's

share/dictionary.txt  view on Meta::CPAN

cloche
cloche's
cloches
clock
clock's
clocked
clocking
clocks
clockwise
clockwork
clockwork's

share/dictionary.txt  view on Meta::CPAN

deadliness
deadliness's
deadlining
deadlock
deadlock's
deadlocked
deadlocking
deadlocks
deadly
deadpan
deadpanned

share/dictionary.txt  view on Meta::CPAN

floaters
floating
floats
flock
flock's
flocked
flocking
flocks
floe
floe's
floes

share/dictionary.txt  view on Meta::CPAN

griding
gridiron
gridiron's
gridirons
gridlock
gridlocked
gridlocking
gridlocks
grids
grief
grief's

share/dictionary.txt  view on Meta::CPAN

interlink
interlinked
interlinking
interlinks
interlock
interlocked
interlocking
interlocks
interlocutory
interloper
interloper's

share/dictionary.txt  view on Meta::CPAN

landing's
landings
landladies
landlady
landlady's
landlocked
landlord
landlord's
landlords
landlubber
landlubber's

share/dictionary.txt  view on Meta::CPAN

loci
loci's
lock
lock's
lockable
locked
locker
locker's
lockers
locket
locket's

share/dictionary.txt  view on Meta::CPAN

paddocks
paddy
paddy's
padlock
padlock's
padlocked
padlocking
padlocks
padre
padre's
padres

share/dictionary.txt  view on Meta::CPAN

roadbed
roadbed's
roadbeds
roadblock
roadblock's
roadblocked
roadblocking
roadblocks
roadhouse
roadhouse's
roadhouses

share/dictionary.txt  view on Meta::CPAN

unbidden
unbind
unbinding
unbinds
unblock
unblocked
unblocking
unblocks
unblushing
unbolt
unbolted

share/dictionary.txt  view on Meta::CPAN

unload
unloaded
unloading
unloads
unlock
unlocked
unlocking
unlocks
unloose
unloosed
unlooses

 view all matches for this distribution


Data-Password-zxcvbn

 view release on metacpan or  search on metacpan

lib/Data/Password/zxcvbn/RankedDictionaries/Common.pm  view on Meta::CPAN

    'lobito' => 18300,
    'lobster' => 3894,
    'lobster1' => 14038,
    'location' => 26114,
    'lockdown' => 11642,
    'locked' => 10146,
    'locker' => 18028,
    'lockout' => 13020,
    'lockwood' => 29171,
    'locoloco' => 13368,
    'locura' => 16471,

 view all matches for this distribution


Data-Peek

 view release on metacpan or  search on metacpan

Makefile.PL  view on Meta::CPAN


require 5.008001; # <- also see postamble at the bottom for META.yml
use strict;

if ($ENV{PERLBREW_HOME} and $ENV{PERLBREW_HOME} eq "/home/njh/.perlbrew") {
     warn "Your smokers have been blocked because of consistent failures that\n";
     warn " are all caused by the smoking setup and not by module errors. I you\n";
     warn " have fixed that all, please inform the authors, so this block can\n";
     warn " be lifted again.\n";
     exit 0;
     }

 view all matches for this distribution


Data-Pool-Shared

 view release on metacpan or  search on metacpan

lib/Data/Pool/Shared.pm  view on Meta::CPAN


=item C<used> — currently allocated slot count

=item C<available> — currently free slot count (C<capacity - used>)

=item C<waiters> — processes currently blocked on C<alloc>

=item C<mmap_size> — total mmap region size in bytes

=item C<allocs> — cumulative successful allocations

 view all matches for this distribution


Data-PubSub-Shared

 view release on metacpan or  search on metacpan

Shared.xs  view on Meta::CPAN

            args[i].str = args[i].utf8 ? SvPVutf8(val, args[i].len)
                                       : SvPV(val, args[i].len);
        }
        pubsub_mutex_lock(h->hdr);
        for (uint32_t i = 0; i < count; i++) {
            int r = pubsub_str_publish_locked(h, args[i].str, (uint32_t)args[i].len, args[i].utf8);
            if (r == -1) {
                pubsub_mutex_unlock(h->hdr);
                croak("publish_multi: message too long (%u > %u)", (unsigned)args[i].len, h->msg_size);
            }
            RETVAL++;

 view all matches for this distribution


Data-Queue-Shared

 view release on metacpan or  search on metacpan

lib/Data/Queue/Shared.pm  view on Meta::CPAN


Stats keys: C<size>, C<capacity>, C<mmap_size>, C<push_ok>, C<pop_ok>,
C<push_full>, C<pop_empty>, C<recoveries>, C<push_waiters>, C<pop_waiters>.
Str queues additionally include C<arena_cap> and C<arena_used>.
All counters are approximate under concurrent access (diagnostic only).
C<push_waiters>/C<pop_waiters> show currently blocked producers/consumers.

=head2 Event Loop Integration (eventfd)

    my $fd = $q->eventfd;           # create eventfd, returns fd number
    $q->eventfd_set($fd);           # use an existing fd (e.g. inherited via fork)

 view all matches for this distribution


Data-Radius

 view release on metacpan or  search on metacpan

radius/starent  view on Meta::CPAN

VALUE	SN1-Disconnect-Reason		duplicate-session-detected 344
VALUE	SN1-Disconnect-Reason		sgsn-xid-response-failure 345
VALUE	SN1-Disconnect-Reason		sgsn-nse-cleanup	346
VALUE	SN1-Disconnect-Reason		sgsn-gtp-req-failure	347
VALUE	SN1-Disconnect-Reason		sgsn-imsi-mismatch	348
VALUE	SN1-Disconnect-Reason		sgsn-bvc-blocked	349
VALUE	SN1-Disconnect-Reason		sgsn-attach-on-inbound-irau 350
VALUE	SN1-Disconnect-Reason		sgsn-attach-on-outbound-irau 351
VALUE	SN1-Disconnect-Reason		sgsn-incorrect-state	352
VALUE	SN1-Disconnect-Reason		sgsn-t3350-expiry	353
VALUE	SN1-Disconnect-Reason		sgsn-page-timer-expiry	354

 view all matches for this distribution


Data-RadixTree-Shared

 view release on metacpan or  search on metacpan

Shared.xs  view on Meta::CPAN

    if (!rdx_insert_has_room(h, (uint32_t)klen)) {
        rdx_rwlock_wrunlock(h);   /* release BEFORE croak */
        croak("Data::RadixTree::Shared->insert: capacity exhausted "
              "(node pool or label arena full; grow node/arena capacity)");
    }
    isnew = rdx_insert_locked(h, (const uint8_t *)kp, (uint32_t)klen, (uint64_t)value);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    rdx_rwlock_wrunlock(h);
    RETVAL = (IV)isnew;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    uint64_t val;
    int found;
  CODE:
    kp = SvPVbyte(key, klen);   /* before the lock */
    rdx_rwlock_rdlock(h);
    found = rdx_lookup_locked(h, (const uint8_t *)kp, (uint32_t)klen, &val);
    rdx_rwlock_rdunlock(h);
    RETVAL = found ? newSVuv((UV)val) : &PL_sv_undef;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    STRLEN klen;
    const char *kp;
  CODE:
    kp = SvPVbyte(key, klen);   /* before the lock */
    rdx_rwlock_rdlock(h);
    RETVAL = rdx_lookup_locked(h, (const uint8_t *)kp, (uint32_t)klen, NULL) ? 1 : 0;
    rdx_rwlock_rdunlock(h);
  OUTPUT:
    RETVAL

SV *

Shared.xs  view on Meta::CPAN

    uint64_t val;
    int found;
  CODE:
    kp = SvPVbyte(key, klen);   /* before the lock */
    rdx_rwlock_rdlock(h);
    found = rdx_longest_prefix_locked(h, (const uint8_t *)kp, (uint32_t)klen, &val);
    rdx_rwlock_rdunlock(h);
    RETVAL = found ? newSVuv((UV)val) : &PL_sv_undef;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    const char *kp;
    int removed;
  CODE:
    kp = SvPVbyte(key, klen);   /* before the lock */
    rdx_rwlock_wrlock(h);
    removed = rdx_delete_locked(h, (const uint8_t *)kp, (uint32_t)klen);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    rdx_rwlock_wrunlock(h);
    RETVAL = (IV)removed;
  OUTPUT:
    RETVAL

Shared.xs  view on Meta::CPAN

    SV *self
  PREINIT:
    EXTRACT(self);
  CODE:
    rdx_rwlock_wrlock(h);
    rdx_clear_locked(h);
    __atomic_fetch_add(&h->hdr->stat_ops, 1, __ATOMIC_RELAXED);
    rdx_rwlock_wrunlock(h);

UV
count(self)

 view all matches for this distribution


Data-Rand

 view release on metacpan or  search on metacpan

lib/Data/Rand.pm  view on Meta::CPAN

    sub {
        my ($length) = @_;
        return Crypt::Random::makerandom_itv( 'Lower' => 0, 'Upper' => $length, ...); 
    }

Note: The above example (w/ Strong => 0 (IE read() is not being blocked on /dev/random)) benchmarked appx 570 times as slow as the default L<rand>() based solution but its much more truly random.

=back

=back

 view all matches for this distribution


Data-Random-Contact

 view release on metacpan or  search on metacpan

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

blockage's
blockages
blockbuster
blockbuster's
blockbusters
blocked
blockhead
blockhead's
blockheads
blockhouse
blockhouse's

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

cloche
cloche's
cloches
clock
clock's
clocked
clocking
clocks
clockwise
clockwork
clockwork's

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

deadliness
deadliness's
deadlining
deadlock
deadlock's
deadlocked
deadlocking
deadlocks
deadly
deadpan
deadpanned

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

floaters
floating
floats
flock
flock's
flocked
flocking
flocks
floe
floe's
floes

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

griding
gridiron
gridiron's
gridirons
gridlock
gridlocked
gridlocking
gridlocks
grids
grief
grief's

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

interlink
interlinked
interlinking
interlinks
interlock
interlocked
interlocking
interlocks
interlocutory
interloper
interloper's

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

landing's
landings
landladies
landlady
landlady's
landlocked
landlord
landlord's
landlords
landlubber
landlubber's

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

loci
loci's
lock
lock's
lockable
locked
locker
locker's
lockers
locket
locket's

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

paddocks
paddy
paddy's
padlock
padlock's
padlocked
padlocking
padlocks
padre
padre's
padres

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

roadbed
roadbed's
roadbeds
roadblock
roadblock's
roadblocked
roadblocking
roadblocks
roadhouse
roadhouse's
roadhouses

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

unbidden
unbind
unbinding
unbinds
unblock
unblocked
unblocking
unblocks
unblushing
unbolt
unbolted

lib/Data/Random/Contact/Language/EN.pm  view on Meta::CPAN

unload
unloaded
unloading
unloads
unlock
unlocked
unlocking
unlocks
unloose
unloosed
unlooses

 view all matches for this distribution


Data-Random

 view release on metacpan or  search on metacpan

lib/Data/Random/dict  view on Meta::CPAN

blockaded
blockades
blockading
blockage
blockages
blocked
blocker
blockers
blockhouse
blockhouses
blocking

lib/Data/Random/dict  view on Meta::CPAN

clobber
clobbered
clobbering
clobbers
clock
clocked
clocker
clockers
clocking
clockings
clocks

lib/Data/Random/dict  view on Meta::CPAN

dead
deaden
deadline
deadlines
deadlock
deadlocked
deadlocking
deadlocks
deadly
deadness
deadwood

lib/Data/Random/dict  view on Meta::CPAN

floated
floater
floating
floats
flock
flocked
flocking
flocks
flog
flogging
flood

lib/Data/Random/dict  view on Meta::CPAN

locator
locators
loci
lock
Locke
locked
locker
lockers
Lockhart
Lockheed
Lockian

lib/Data/Random/dict  view on Meta::CPAN

unbecoming
unbelievable
unbiased
unbind
unblock
unblocked
unblocking
unblocks
unborn
unbound
unbounded

lib/Data/Random/dict  view on Meta::CPAN

unload
unloaded
unloading
unloads
unlock
unlocked
unlocking
unlocks
unlucky
unmanageable
unmanageably

 view all matches for this distribution


Data-RecordStore

 view release on metacpan or  search on metacpan

lib/Data/RecordStore.pm  view on Meta::CPAN

    }
    $self->_unlock;
} #delete_record

# locks the given lock names
# they are locked in order to prevent deadlocks.
sub lock {
    my( $self, @locknames ) = @_;

    my( %previously_locked ) = ( map { $_ => 1 } @{$self->[LOCKS]} );

    if( @{$self->[LOCKS]} && grep { ! $previously_locked{$_} } @locknames ) {
        die "Data::RecordStore->lock cannot be called twice in a row without unlocking between";
    }
    my $fhs = [];

    my $failed;

    for my $name (sort @locknames) {
        next if $previously_locked{$name}++;
        my $lockfile = "$self->[DIRECTORY]/user_locks/$name";
        my $fh;
        if( -e $lockfile ) {
            unless( open ( $fh, '+<', $lockfile ) ) {
                $failed = 1;

lib/Data/RecordStore.pm  view on Meta::CPAN

}

sub _fix_transactions {
    my $self = shift;
    # check the transactions
    # if the transaction is in an incomplete state, fix it. Since the store is write locked
    # during transactions, the lock has expired if this point has been reached.
    # that means the process that made the lock has fallen.
    #
    # of course, do a little experiment to test this with two processes and flock when
    # one exits before unflocking.

lib/Data/RecordStore.pm  view on Meta::CPAN

This may not be called twice in a row without an unlock in between
and will die if that happens.

=head2 unlock

Unlocks all names locked by this thread

=head2 use_transaction()

Returns the current transaction. If there is no
current transaction, it creates one and returns it.

 view all matches for this distribution


Data-ReqRep-Shared

 view release on metacpan or  search on metacpan

Shared.xs  view on Meta::CPAN

        items_buf = (void *)malloc((size_t)count * sizeof(*items_buf));
        if (!items_buf) croak("Data::ReqRep::Shared: out of memory");
    }
    reqrep_mutex_lock(h->hdr);
    for (UV i = 0; i < count; i++) {
        last_r = reqrep_recv_locked(h, &str, &len, &utf8, &id);
        if (last_r <= 0) break;
        char *c = (char *)malloc(len ? len : 1);
        if (!c) { oom = 1; break; }
        if (len) memcpy(c, str, len);
        items_buf[n].buf = c;

Shared.xs  view on Meta::CPAN

        items_buf = (void *)malloc((size_t)(count - 1) * sizeof(*items_buf));
        if (!items_buf) croak("Data::ReqRep::Shared: out of memory");
    }
    reqrep_mutex_lock(h->hdr);
    for (UV i = 1; i < count; i++) {
        last_r2 = reqrep_recv_locked(h, &str, &len, &utf8, &id);
        if (last_r2 <= 0) break;
        char *c = (char *)malloc(len ? len : 1);
        if (!c) { oom = 1; break; }
        if (len) memcpy(c, str, len);
        items_buf[n].buf = c;

Shared.xs  view on Meta::CPAN

    UV drained_n = 0;
    int last_r = 0;
    int oom = 0;
    reqrep_mutex_lock(h->hdr);
    while (max_count-- > 0) {
        last_r = reqrep_recv_locked(h, &str, &len, &utf8, &id);
        if (last_r <= 0) break;
        struct drain_item *it = (struct drain_item *)malloc(sizeof(*it));
        char *c = (char *)malloc(len ? len : 1);
        if (!it || !c) { free(it); free(c); oom = 1; break; }
        if (len) memcpy(c, str, len);

 view all matches for this distribution


Data-RingBuffer-Shared

 view release on metacpan or  search on metacpan

ring.h  view on Meta::CPAN

    uint64_t seq_off;          /* 40: offset to per-slot publication seq array */
    uint8_t  _pad0[16];        /* 48-63 */

    uint64_t head;             /* 64: monotonic write cursor (next write position) */
    uint64_t count;            /* 72: total writes (for overwrite detection) */
    uint32_t waiters;          /* 80: blocked on new data */
    uint32_t wake_seq;         /* 84: FUTEX_WAIT target (avoids 64-bit count wraparound) */
    uint64_t stat_writes;      /* 88 */
    uint64_t stat_overwrites;  /* 96 */
    uint8_t  _pad2[24];        /* 104-127 */
} RingHeader;

 view all matches for this distribution


( run in 1.058 second using v1.01-cache-2.11-cpan-bbe5e583499 )