@@ -115,7 +115,7 @@ ancestor_builder_print_state(ancestor_builder_t *self, FILE *out)
115
115
}
116
116
fprintf (out , "\n" );
117
117
}
118
- tsk_blkalloc_print_state (& self -> allocator , out );
118
+ tsi_blkalloc_print_state (& self -> allocator , out );
119
119
ancestor_builder_check_state (self );
120
120
return 0 ;
121
121
}
@@ -144,12 +144,12 @@ ancestor_builder_alloc(
144
144
goto out ;
145
145
}
146
146
/* Pre-calculate the maximum sizes asked for in other methods when calling
147
- * tsk_blkalloc_get (&self->allocator, ...) */
147
+ * tsi_blkalloc_get (&self->allocator, ...) */
148
148
max_size = TSK_MAX (self -> num_samples * sizeof (allele_t ), max_size );
149
149
/* NB: using self->max_sites below is probably overkill: the real number should be
150
150
* the maximum number of focal sites in a single ancestor, usually << max_sites */
151
151
max_size = TSK_MAX (self -> max_sites * sizeof (tsk_id_t ), max_size );
152
- ret = tsk_blkalloc_init (& self -> allocator , max_size );
152
+ ret = tsi_blkalloc_init (& self -> allocator , max_size );
153
153
if (ret != 0 ) {
154
154
goto out ;
155
155
}
@@ -163,7 +163,7 @@ ancestor_builder_free(ancestor_builder_t *self)
163
163
{
164
164
tsi_safe_free (self -> sites );
165
165
tsi_safe_free (self -> descriptors );
166
- tsk_blkalloc_free (& self -> allocator );
166
+ tsi_blkalloc_free (& self -> allocator );
167
167
return 0 ;
168
168
}
169
169
@@ -177,8 +177,8 @@ ancestor_builder_get_time_map(ancestor_builder_t *self, double time)
177
177
search .time = time ;
178
178
avl_node = avl_search (& self -> time_map , & search );
179
179
if (avl_node == NULL ) {
180
- avl_node = tsk_blkalloc_get (& self -> allocator , sizeof (* avl_node ));
181
- time_map = tsk_blkalloc_get (& self -> allocator , sizeof (* time_map ));
180
+ avl_node = tsi_blkalloc_get (& self -> allocator , sizeof (* avl_node ));
181
+ time_map = tsi_blkalloc_get (& self -> allocator , sizeof (* time_map ));
182
182
if (avl_node == NULL || time_map == NULL ) {
183
183
goto out ;
184
184
}
@@ -439,10 +439,10 @@ ancestor_builder_add_site(ancestor_builder_t *self, double time, allele_t *genot
439
439
search .num_samples = self -> num_samples ;
440
440
avl_node = avl_search (pattern_map , & search );
441
441
if (avl_node == NULL ) {
442
- avl_node = tsk_blkalloc_get (& self -> allocator , sizeof (avl_node_t ));
443
- map_elem = tsk_blkalloc_get (& self -> allocator , sizeof (pattern_map_t ));
442
+ avl_node = tsi_blkalloc_get (& self -> allocator , sizeof (avl_node_t ));
443
+ map_elem = tsi_blkalloc_get (& self -> allocator , sizeof (pattern_map_t ));
444
444
site -> genotypes
445
- = tsk_blkalloc_get (& self -> allocator , self -> num_samples * sizeof (allele_t ));
445
+ = tsi_blkalloc_get (& self -> allocator , self -> num_samples * sizeof (allele_t ));
446
446
if (avl_node == NULL || map_elem == NULL || site -> genotypes == NULL ) {
447
447
ret = TSI_ERR_NO_MEMORY ;
448
448
goto out ;
@@ -465,7 +465,7 @@ ancestor_builder_add_site(ancestor_builder_t *self, double time, allele_t *genot
465
465
}
466
466
map_elem -> num_sites ++ ;
467
467
468
- list_node = tsk_blkalloc_get (& self -> allocator , sizeof (site_list_t ));
468
+ list_node = tsi_blkalloc_get (& self -> allocator , sizeof (site_list_t ));
469
469
if (list_node == NULL ) {
470
470
ret = TSI_ERR_NO_MEMORY ;
471
471
goto out ;
@@ -538,7 +538,7 @@ ancestor_builder_finalise(ancestor_builder_t *self)
538
538
descriptor = self -> descriptors + self -> num_ancestors ;
539
539
self -> num_ancestors ++ ;
540
540
descriptor -> time = time_map -> time ;
541
- focal_sites = tsk_blkalloc_get (
541
+ focal_sites = tsi_blkalloc_get (
542
542
& self -> allocator , pattern_map -> num_sites * sizeof (tsk_id_t ));
543
543
if (focal_sites == NULL ) {
544
544
ret = TSI_ERR_NO_MEMORY ;
0 commit comments