lib/PDL/Primitive-pp-vsearch_sample.c

filter: Statementstmt 73.8% 62 / 84 Branchbran 43.2% 77 / 178 Conditioncond n/a MC/DCmcdc n/a Subroutinesub n/a Podpod n/a totaltotal 53.0% 139 / 262 CC 0 SCAR 0
CC
0
Cov
0%
CRAP 0
« lib/PDL/Primitive-pp-vsearch_bin_inclusive.c ↑ Summary lib/PDL/Compression.xs »
1  
2 #line 453 "lib/PDL/PP.pm"
3 /*
4 * THIS FILE WAS GENERATED BY PDL::PP from lib/PDL/Primitive.pd! Do not modify!
5 */
6  
7 #define PDL_FREE_CODE(trans, destroy, comp_free_code, ntpriv_free_code) \
8 if (destroy) { \
9 comp_free_code \
10 } \
11 if ((trans)->dims_redone) { \
12 ntpriv_free_code \
13 }
14  
15 #include "EXTERN.h"
16 #include "perl.h"
17 #include "XSUB.h"
18 #include "pdl.h"
19 #include "pdlcore.h"
20 #define PDL PDL_Primitive
21 extern Core* PDL; /* Structure hold core C functions */
22 #line 23 "lib/PDL/Primitive-pp-vsearch_sample.c"
23 extern int pdl_srand_threads;
24 extern uint64_t *pdl_rand_state;
25 void pdl_srand(uint64_t **s, uint64_t seed, int n);
26 double pdl_drand(uint64_t *s);
27 #define PDL_MAYBE_SRAND \
28 if (pdl_srand_threads < 0) \
29 pdl_srand(&pdl_rand_state, PDL->pdl_seed(), PDL->online_cpus());
30 #define PDL_RAND_SET_OFFSET(v, thr, pdl) \
31 if (v < 0) { \
32 if (thr.mag_nthr >= 0) { \
33 int thr_no = PDL->magic_get_thread(pdl); \
34 if (thr_no < 0) return PDL->make_error_simple(PDL_EFATAL, "Invalid pdl_magic_get_thread!"); \
35 v = thr_no == 0 ? thr_no : thr_no % PDL->online_cpus(); \
36 } else { \
37 v = 0; \
38 } \
39 }
40  
41 #line 1888 "lib/PDL/PP.pm"
42 pdl_error pdl_vsearch_sample_readdata(pdl_trans *__privtrans) {
43 pdl_error PDL_err = {0, NULL, 0};
44 #line 45 "lib/PDL/Primitive-pp-vsearch_sample.c"
45 28 register PDL_Indx __n_size = __privtrans->ind_sizes[0];
46 28 ▶ if (!__privtrans->broadcast.incs) return PDL->make_error(PDL_EUSERERROR, "Error in vsearch_sample:" "broadcast.incs NULL");
Branch: 1 branch
BranchTrueFalseTotal
if (!__privtrans->broadcast.incs) return PDL->make_error(PDL_EUSERERROR, "Error in vsearch_sample:" "broadcast.incs NULL"); 0 28 28
47 /* broadcastloop declarations */
48 int __brcloopval;
49 register PDL_Indx __tind0,__tind1; /* counters along dim */
50 28 register PDL_Indx __tnpdls = __privtrans->broadcast.npdls;
51 /* dims here are how many steps along those dims */
52 28 register PDL_Indx __tinc0_vals = PDL_BRC_INC(__privtrans->broadcast.incs,__tnpdls,0,0);
53 28 register PDL_Indx __tinc0_x = PDL_BRC_INC(__privtrans->broadcast.incs,__tnpdls,1,0);
54 28 register PDL_Indx __tinc0_idx = PDL_BRC_INC(__privtrans->broadcast.incs,__tnpdls,2,0);
55 28 register PDL_Indx __tinc1_vals = PDL_BRC_INC(__privtrans->broadcast.incs,__tnpdls,0,1);
56 28 register PDL_Indx __tinc1_x = PDL_BRC_INC(__privtrans->broadcast.incs,__tnpdls,1,1);
57 28 register PDL_Indx __tinc1_idx = PDL_BRC_INC(__privtrans->broadcast.incs,__tnpdls,2,1);
58 #define PDL_BROADCASTLOOP_START_vsearch_sample_readdata PDL_BROADCASTLOOP_START( \
59 readdata, \
60 __privtrans->broadcast, \
61 __privtrans->vtable, \
62 vals_datap += __offsp[0]; \
63 x_datap += __offsp[1]; \
64 idx_datap += __offsp[2]; \
65 , \
66 ( ,vals_datap += __tinc1_vals - __tinc0_vals * __tdims0 \
67 ,x_datap += __tinc1_x - __tinc0_x * __tdims0 \
68 ,idx_datap += __tinc1_idx - __tinc0_idx * __tdims0 \
69 ), \
70 ( ,vals_datap += __tinc0_vals \
71 ,x_datap += __tinc0_x \
72 ,idx_datap += __tinc0_idx \
73 ) \
74 )
75 #define PDL_BROADCASTLOOP_END_vsearch_sample_readdata PDL_BROADCASTLOOP_END( \
76 __privtrans->broadcast, \
77 vals_datap -= __tinc1_vals * __tdims1 + __offsp[0]; \
78 x_datap -= __tinc1_x * __tdims1 + __offsp[1]; \
79 idx_datap -= __tinc1_idx * __tdims1 + __offsp[2]; \
80 )
81 28 register PDL_Indx __inc_x_n = __privtrans->inc_sizes[PDL_INC_ID(__privtrans->vtable,1,0)]; (void)__inc_x_n;
82 #ifndef PDL_DECLARE_PARAMS_vsearch_sample_1
83 #define PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_TYPE_OP,PDL_PPSYM_OP,PDL_TYPE_PARAM_idx,PDL_PPSYM_PARAM_idx) \
84 PDL_DECLARE_PARAMETER_BADVAL(PDL_TYPE_OP, vals, (__privtrans->pdls[0]), 1, PDL_PPSYM_OP) \
85 PDL_DECLARE_PARAMETER_BADVAL(PDL_TYPE_OP, x, (__privtrans->pdls[1]), 1, PDL_PPSYM_OP) \
86 PDL_DECLARE_PARAMETER_BADVAL(PDL_TYPE_PARAM_idx, idx, (__privtrans->pdls[2]), 1, PDL_PPSYM_PARAM_idx)
87 #endif
88 #define PDL_IF_BAD(t,f) f
89 28 switch (__privtrans->__datatype) { /* Start generic switch */
90 0 case PDL_F: {
91 0 ▶ PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N)
Branch: 12 branches
BranchTrueFalseTotal
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Float,F,PDL_Indx,N) 0 0 0
92 0 ▶ PDL_BROADCASTLOOP_START_vsearch_sample_readdata {
Branch: 7 branches
BranchTrueFalseTotal
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 0 0
93 0 ▶ {/* Open n */ PDL_EXPAND2(register PDL_Indx n=0, __n_stop=(__n_size)); for(; n<__n_stop; n+=1) {
Branch: 1 branch
BranchTrueFalseTotal
{/* Open n */ PDL_EXPAND2(register PDL_Indx n=0, __n_stop=(__n_size)); for(; n<__n_stop; n+=1) { 0 0 0
94 0 ▶ if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,F,vals_badval_isnan) ) {
Branch: 2 branches
BranchTrueFalseTotal
if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,F,vals_badval_isnan) ) { 0 0 0
if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,F,vals_badval_isnan) ) { 0 0 0
95 0 PDL_Indx n1 = __privtrans->ind_sizes[0]-1;
96 0 PDL_Indx low = -1;
97 0 PDL_Indx high = __privtrans->ind_sizes[0];
98 PDL_Indx mid;
99  
100 0 PDL_Float value = (vals_datap)[0];
101  
102 /* determine sort order of data */
103 0 int up = ((x_datap)[0+(__inc_x_n*(n1))] > (x_datap)[0+(__inc_x_n*(0))]);
104
105 0 ▶ while ( high - low > 1 ) {
Branch: 1 branch
BranchTrueFalseTotal
while ( high - low > 1 ) { 0 0 0
106 0 mid = low + (( high - low )>> 1);;
107 0 ▶ if ( ( value > (x_datap)[0+(__inc_x_n*(mid))] ) == up ) low = mid;
Branch: 1 branch
BranchTrueFalseTotal
if ( ( value > (x_datap)[0+(__inc_x_n*(mid))] ) == up ) low = mid; 0 0 0
108 0 else high = mid;
109 }
110 0 (idx_datap)[0] = low >= n1 ? n1
111 0 ▶ : up ? low + 1
Branch: 1 branch
BranchTrueFalseTotal
: up ? low + 1 0 0 0
112 0 ▶ : PDLMAX(low, 0);
Branch: 1 branch
BranchTrueFalseTotal
: PDLMAX(low, 0); 0 0 0
113  
114
115 }
116  
117 else {
118 0 (idx_datap)[0]=idx_badval;
119 }
120 }} /* Close n */
121  
122 0 ▶ }PDL_BROADCASTLOOP_END_vsearch_sample_readdata
Branch: 2 branches
BranchTrueFalseTotal
}PDL_BROADCASTLOOP_END_vsearch_sample_readdata 0 0 0
}PDL_BROADCASTLOOP_END_vsearch_sample_readdata 0 0 0
123 0 } break;
124 7 case PDL_D: {
125 7 ▶ PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N)
Branch: 12 branches
BranchTrueFalseTotal
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 7 0 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 2 5 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 7 0 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 7 0 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_Double,D,PDL_Indx,N) 0 7 7
126 1344 ▶ PDL_BROADCASTLOOP_START_vsearch_sample_readdata {
Branch: 7 branches
BranchTrueFalseTotal
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 7 7
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 7 7
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 7 7
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 7 7
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 7 7
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 1323 7 1330
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 7 7 14
127 824052 ▶ {/* Open n */ PDL_EXPAND2(register PDL_Indx n=0, __n_stop=(__n_size)); for(; n<__n_stop; n+=1) {
Branch: 1 branch
BranchTrueFalseTotal
{/* Open n */ PDL_EXPAND2(register PDL_Indx n=0, __n_stop=(__n_size)); for(; n<__n_stop; n+=1) { 822729 1323 824052
128 822729 ▶ if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,D,vals_badval_isnan) ) {
Branch: 2 branches
BranchTrueFalseTotal
if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,D,vals_badval_isnan) ) { 0 822729 822729
if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,D,vals_badval_isnan) ) { 822729 0 822729
129 822729 PDL_Indx n1 = __privtrans->ind_sizes[0]-1;
130 822729 PDL_Indx low = -1;
131 822729 PDL_Indx high = __privtrans->ind_sizes[0];
132 PDL_Indx mid;
133  
134 822729 PDL_Double value = (vals_datap)[0];
135  
136 /* determine sort order of data */
137 822729 int up = ((x_datap)[0+(__inc_x_n*(n1))] > (x_datap)[0+(__inc_x_n*(0))]);
138
139 8853019 ▶ while ( high - low > 1 ) {
Branch: 1 branch
BranchTrueFalseTotal
while ( high - low > 1 ) { 8030290 822729 8853019
140 8030290 mid = low + (( high - low )>> 1);;
141 8030290 ▶ if ( ( value > (x_datap)[0+(__inc_x_n*(mid))] ) == up ) low = mid;
Branch: 1 branch
BranchTrueFalseTotal
if ( ( value > (x_datap)[0+(__inc_x_n*(mid))] ) == up ) low = mid; 6683690 1346600 8030290
142 1346600 else high = mid;
143 }
144 822729 (idx_datap)[0] = low >= n1 ? n1
145 1121329 ▶ : up ? low + 1
Branch: 1 branch
BranchTrueFalseTotal
: up ? low + 1 298600 524129 822729
146 298600 ▶ : PDLMAX(low, 0);
Branch: 1 branch
BranchTrueFalseTotal
: PDLMAX(low, 0); 160000 138600 298600
147  
148
149 }
150  
151 else {
152 0 (idx_datap)[0]=idx_badval;
153 }
154 }} /* Close n */
155  
156 7 ▶ }PDL_BROADCASTLOOP_END_vsearch_sample_readdata
Branch: 2 branches
BranchTrueFalseTotal
}PDL_BROADCASTLOOP_END_vsearch_sample_readdata 0 7 7
}PDL_BROADCASTLOOP_END_vsearch_sample_readdata 0 7 7
157 7 } break;
158 21 case PDL_LD: {
159 21 ▶ PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N)
Branch: 12 branches
BranchTrueFalseTotal
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 21 0 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 21 0 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 21 0 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
PDL_DECLARE_PARAMS_vsearch_sample_1(PDL_LDouble,E,PDL_Indx,N) 0 21 21
160 5860 ▶ PDL_BROADCASTLOOP_START_vsearch_sample_readdata {
Branch: 7 branches
BranchTrueFalseTotal
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 21 21
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 21 21
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 21 21
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 21 21
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 0 21 21
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 5797 21 5818
PDL_BROADCASTLOOP_START_vsearch_sample_readdata { 21 21 42
161 4197028 ▶ {/* Open n */ PDL_EXPAND2(register PDL_Indx n=0, __n_stop=(__n_size)); for(; n<__n_stop; n+=1) {
Branch: 1 branch
BranchTrueFalseTotal
{/* Open n */ PDL_EXPAND2(register PDL_Indx n=0, __n_stop=(__n_size)); for(; n<__n_stop; n+=1) { 4191231 5797 4197028
162 4191231 ▶ if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,E,vals_badval_isnan) ) {
Branch: 2 branches
BranchTrueFalseTotal
if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,E,vals_badval_isnan) ) { 0 4191231 4191231
if ( !PDL_ISBAD2((vals_datap)[0],vals_badval,E,vals_badval_isnan) ) { 3145773 1045458 4191231
163 3145773 PDL_Indx n1 = __privtrans->ind_sizes[0]-1;
164 3145773 PDL_Indx low = -1;
165 3145773 PDL_Indx high = __privtrans->ind_sizes[0];
166 PDL_Indx mid;
167  
168 3145773 PDL_LDouble value = (vals_datap)[0];
169  
170 /* determine sort order of data */
171 3145773 int up = ((x_datap)[0+(__inc_x_n*(n1))] > (x_datap)[0+(__inc_x_n*(0))]);
172
173 33298488 ▶ while ( high - low > 1 ) {
Branch: 1 branch
BranchTrueFalseTotal
while ( high - low > 1 ) { 30152715 3145773 33298488
174 30152715 mid = low + (( high - low )>> 1);;
175 30152715 ▶ if ( ( value > (x_datap)[0+(__inc_x_n*(mid))] ) == up ) low = mid;
Branch: 1 branch
BranchTrueFalseTotal
if ( ( value > (x_datap)[0+(__inc_x_n*(mid))] ) == up ) low = mid; 15806949 14345766 30152715
176 14345766 else high = mid;
177 }
178 3145773 (idx_datap)[0] = low >= n1 ? n1
179 6287208 ▶ : up ? low + 1
Branch: 1 branch
BranchTrueFalseTotal
: up ? low + 1 3141435 4338 3145773
180 3141435 ▶ : PDLMAX(low, 0);
Branch: 1 branch
BranchTrueFalseTotal
: PDLMAX(low, 0); 1571802 1569633 3141435
181  
182
183 }
184  
185 else {
186 1045458 (idx_datap)[0]=idx_badval;
187 }
188 }} /* Close n */
189  
190 21 ▶ }PDL_BROADCASTLOOP_END_vsearch_sample_readdata
Branch: 2 branches
BranchTrueFalseTotal
}PDL_BROADCASTLOOP_END_vsearch_sample_readdata 0 21 21
}PDL_BROADCASTLOOP_END_vsearch_sample_readdata 0 21 21
191 21 } break;
192 0 default: return PDL->make_error(PDL_EUSERERROR, "PP INTERNAL ERROR in vsearch_sample: unhandled datatype(%d), only handles (FDE)! PLEASE MAKE A BUG REPORT\n", __privtrans->__datatype);
193 }
194 #undef PDL_IF_BAD
195 28 return PDL_err;
196 }
197  
198 static pdl_datatypes pdl_vsearch_sample_vtable_gentypes[] = { PDL_F, PDL_D, PDL_LD, -1 };
199 static PDL_Indx pdl_vsearch_sample_vtable_realdims[] = { 0, 1, 0 };
200 static char *pdl_vsearch_sample_vtable_parnames[] = { "vals","x","idx" };
201 static short pdl_vsearch_sample_vtable_parflags[] = {
202 0,
203 0,
204 PDL_PARAM_ISCREAT|PDL_PARAM_ISOUT|PDL_PARAM_ISTYPED|PDL_PARAM_ISWRITE
205 };
206 static pdl_datatypes pdl_vsearch_sample_vtable_partypes[] = { -1, -1, PDL_IND };
207 static PDL_Indx pdl_vsearch_sample_vtable_realdims_starts[] = { 0, 0, 1 };
208 static PDL_Indx pdl_vsearch_sample_vtable_realdims_ind_ids[] = { 0 };
209 static char *pdl_vsearch_sample_vtable_indnames[] = { "n" };
210 pdl_transvtable pdl_vsearch_sample_vtable = {
211 PDL_TRANS_DO_BROADCAST|PDL_TRANS_BADPROCESS, 0, pdl_vsearch_sample_vtable_gentypes, 2, 3, NULL /*CORE21*/,
212 pdl_vsearch_sample_vtable_realdims, pdl_vsearch_sample_vtable_parnames,
213 pdl_vsearch_sample_vtable_parflags, pdl_vsearch_sample_vtable_partypes,
214 pdl_vsearch_sample_vtable_realdims_starts, pdl_vsearch_sample_vtable_realdims_ind_ids, 1,
215 1, pdl_vsearch_sample_vtable_indnames,
216 NULL, pdl_vsearch_sample_readdata, NULL,
217 NULL,
218 0,"PDL::Primitive::vsearch_sample"
219 };
220  
221  
222 28 pdl_error pdl_run_vsearch_sample(pdl *vals,pdl *x,pdl *idx) {
223 28 pdl_error PDL_err = {0, NULL, 0};
224 28 ▶ if (!PDL) return (pdl_error){PDL_EFATAL, "PDL core struct is NULL, can't continue",0};
Branch: 1 branch
BranchTrueFalseTotal
if (!PDL) return (pdl_error){PDL_EFATAL, "PDL core struct is NULL, can't continue",0}; 0 28 28
225 28 pdl_trans *__privtrans = PDL->create_trans(&pdl_vsearch_sample_vtable);
226 28 ▶ if (!__privtrans) return PDL->make_error_simple(PDL_EFATAL, "Couldn't create trans");
Branch: 1 branch
BranchTrueFalseTotal
if (!__privtrans) return PDL->make_error_simple(PDL_EFATAL, "Couldn't create trans"); 0 28 28
227 28 __privtrans->pdls[0] = vals;
228 28 __privtrans->pdls[1] = x;
229 28 __privtrans->pdls[2] = idx;
230 28 ▶ PDL_RETERROR(PDL_err, PDL->type_coerce(__privtrans));
Branch: 1 branch
BranchTrueFalseTotal
PDL_RETERROR(PDL_err, PDL->type_coerce(__privtrans)); 0 28 28
231 28 ▶ PDL_RETERROR(PDL_err, PDL->make_trans_mutual(__privtrans));
Branch: 1 branch
BranchTrueFalseTotal
PDL_RETERROR(PDL_err, PDL->make_trans_mutual(__privtrans)); 0 28 28
232 28 return PDL_err;
233 }
« lib/PDL/Primitive-pp-vsearch_bin_inclusive.c ↑ Summary lib/PDL/Compression.xs »