| line |
true |
false |
branch |
|
28
|
0 |
8 |
if (!SvROK(self)) return; |
|
30
|
0 |
8 |
if (!h) return; |
|
38
|
8 |
0 |
EXTRACT_RING(self); |
|
|
0 |
8 |
EXTRACT_RING(self); |
|
|
0 |
8 |
EXTRACT_RING(self); |
|
48
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
50
|
0 |
1 |
RETVAL = (UV)h->hdr->capacity; |
|
58
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
68
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
70
|
0 |
1 |
RETVAL = (UV)__atomic_load_n(&h->hdr->count, __ATOMIC_ACQUIRE); |
|
79
|
2 |
0 |
EXTRACT_RING(self); |
|
|
0 |
2 |
EXTRACT_RING(self); |
|
|
0 |
2 |
EXTRACT_RING(self); |
|
82
|
2 |
0 |
if (items > 2) timeout = SvNV(ST(2)); |
|
83
|
1 |
1 |
RETVAL = ring_wait(h, expected_count, timeout); |
|
91
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
99
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
101
|
1 |
0 |
RETVAL = h->path ? newSVpv(h->path, 0) : &PL_sv_undef; |
|
109
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
111
|
0 |
1 |
RETVAL = h->backing_fd; |
|
119
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
121
|
0 |
1 |
RETVAL = ring_create_eventfd(h); |
|
130
|
0 |
0 |
EXTRACT_RING(self); |
|
|
0 |
0 |
EXTRACT_RING(self); |
|
|
0 |
0 |
EXTRACT_RING(self); |
|
132
|
0 |
0 |
if (h->notify_fd >= 0 && h->notify_fd != fd) close(h->notify_fd); |
|
|
0 |
0 |
if (h->notify_fd >= 0 && h->notify_fd != fd) close(h->notify_fd); |
|
139
|
0 |
0 |
EXTRACT_RING(self); |
|
|
0 |
0 |
EXTRACT_RING(self); |
|
|
0 |
0 |
EXTRACT_RING(self); |
|
141
|
0 |
0 |
RETVAL = h->notify_fd; |
|
149
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
151
|
1 |
0 |
RETVAL = ring_notify(h); |
|
159
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
162
|
1 |
0 |
RETVAL = (v >= 0) ? newSViv((IV)v) : &PL_sv_undef; |
|
170
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
179
|
1 |
0 |
if (sv_isobject(self_or_class)) { |
|
181
|
0 |
1 |
if (!h) croak("destroyed object"); |
|
184
|
0 |
0 |
if (items < 2) croak("Usage: ...->unlink($path)"); |
|
187
|
0 |
1 |
if (!p) croak("cannot unlink anonymous or memfd object"); |
|
188
|
0 |
1 |
if (unlink(p) != 0) croak("unlink(%s): %s", p, strerror(errno)); |
|
194
|
1 |
0 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
|
0 |
1 |
EXTRACT_RING(self); |
|
222
|
3 |
2 |
const char *p = SvOK(path) ? SvPV_nolen(path) : NULL; |
|
224
|
0 |
5 |
if (!h) croak("Data::RingBuffer::Shared::Int->new: %s", errbuf); |
|
238
|
0 |
1 |
if (!h) croak("Data::RingBuffer::Shared::Int->new_memfd: %s", errbuf); |
|
251
|
0 |
1 |
if (!h) croak("Data::RingBuffer::Shared::Int->new_from_fd: %s", errbuf); |
|
261
|
11 |
0 |
EXTRACT_RING(self); |
|
|
0 |
11 |
EXTRACT_RING(self); |
|
|
0 |
11 |
EXTRACT_RING(self); |
|
272
|
15 |
0 |
EXTRACT_RING(self); |
|
|
0 |
15 |
EXTRACT_RING(self); |
|
|
0 |
15 |
EXTRACT_RING(self); |
|
274
|
9 |
6 |
uint32_t n = (items > 1) ? (uint32_t)SvUV(ST(1)) : 0; |
|
276
|
14 |
1 |
RETVAL = ring_read_latest(h, n, &v) ? newSViv((IV)v) : &PL_sv_undef; |
|
285
|
5 |
0 |
EXTRACT_RING(self); |
|
|
0 |
5 |
EXTRACT_RING(self); |
|
|
0 |
5 |
EXTRACT_RING(self); |
|
288
|
3 |
2 |
RETVAL = ring_read_seq(h, seq, &v) ? newSViv((IV)v) : &PL_sv_undef; |
|
305
|
0 |
1 |
const char *p = SvOK(path) ? SvPV_nolen(path) : NULL; |
|
307
|
0 |
1 |
if (!h) croak("Data::RingBuffer::Shared::F64->new: %s", errbuf); |
|
321
|
0 |
0 |
if (!h) croak("Data::RingBuffer::Shared::F64->new_memfd: %s", errbuf); |
|
334
|
0 |
0 |
if (!h) croak("Data::RingBuffer::Shared::F64->new_from_fd: %s", errbuf); |
|
344
|
2 |
0 |
EXTRACT_RING(self); |
|
|
0 |
2 |
EXTRACT_RING(self); |
|
|
0 |
2 |
EXTRACT_RING(self); |
|
355
|
2 |
0 |
EXTRACT_RING(self); |
|
|
0 |
2 |
EXTRACT_RING(self); |
|
|
0 |
2 |
EXTRACT_RING(self); |
|
357
|
1 |
1 |
uint32_t n = (items > 1) ? (uint32_t)SvUV(ST(1)) : 0; |
|
359
|
2 |
0 |
RETVAL = ring_read_latest(h, n, &v) ? newSVnv(v) : &PL_sv_undef; |
|
368
|
0 |
0 |
EXTRACT_RING(self); |
|
|
0 |
0 |
EXTRACT_RING(self); |
|
|
0 |
0 |
EXTRACT_RING(self); |
|
371
|
0 |
0 |
RETVAL = ring_read_seq(h, seq, &v) ? newSVnv(v) : &PL_sv_undef; |