@@ -556,7 +556,7 @@ extern "C" {
556556 // ==== C Interface of Memory-mappable Value Store ====
557557
558558 typedef pecos::mmap_valstore::Float32Store mmap_valstore_float32;
559- typedef pecos::mmap_valstore::StringStore mmap_valstore_str ;
559+ typedef pecos::mmap_valstore::BytesStore mmap_valstore_bytes ;
560560 typedef pecos::mmap_valstore::row_type row_type;
561561 typedef pecos::mmap_valstore::col_type col_type;
562562
@@ -565,35 +565,35 @@ extern "C" {
565565 void * mmap_valstore_new_ ## SUFFIX () { \
566566 return static_cast <void *>(new mmap_valstore_ ## SUFFIX ()); }
567567 MMAP_VALSTORE_NEW (float32)
568- MMAP_VALSTORE_NEW(str )
568+ MMAP_VALSTORE_NEW(bytes )
569569
570570 // Destruct
571571 #define MMAP_VALSTORE_DESTRUCT (SUFFIX ) \
572572 void mmap_valstore_destruct_ ## SUFFIX (void * map_ptr) { \
573573 delete static_cast <mmap_valstore_ ## SUFFIX *>(map_ptr); }
574574 MMAP_VALSTORE_DESTRUCT (float32)
575- MMAP_VALSTORE_DESTRUCT(str )
575+ MMAP_VALSTORE_DESTRUCT(bytes )
576576
577577 // Number of rows
578578 #define MMAP_MAP_N_ROW (SUFFIX ) \
579579 row_type mmap_valstore_n_row_ ## SUFFIX (void * map_ptr) { \
580580 return static_cast <mmap_valstore_ ## SUFFIX *>(map_ptr)->n_row (); }
581581 MMAP_MAP_N_ROW (float32)
582- MMAP_MAP_N_ROW(str )
582+ MMAP_MAP_N_ROW(bytes )
583583
584584 // Number of columns
585585 #define MMAP_MAP_N_COL (SUFFIX ) \
586586 col_type mmap_valstore_n_col_ ## SUFFIX (void * map_ptr) { \
587587 return static_cast <mmap_valstore_ ## SUFFIX *>(map_ptr)->n_col (); }
588588 MMAP_MAP_N_COL (float32)
589- MMAP_MAP_N_COL(str )
589+ MMAP_MAP_N_COL(bytes )
590590
591591 // Save
592592 #define MMAP_VALSTORE_SAVE (SUFFIX ) \
593593 void mmap_valstore_save_ ## SUFFIX (void * map_ptr, const char * map_dir) { \
594594 static_cast <mmap_valstore_ ## SUFFIX *>(map_ptr)->save (map_dir); }
595595 MMAP_VALSTORE_SAVE (float32)
596- MMAP_VALSTORE_SAVE(str )
596+ MMAP_VALSTORE_SAVE(bytes )
597597
598598 // Load
599599 #define MMAP_VALSTORE_LOAD (SUFFIX ) \
@@ -602,7 +602,7 @@ extern "C" {
602602 map_ptr->load (map_dir, lazy_load); \
603603 return static_cast <void *>(map_ptr); }
604604 MMAP_VALSTORE_LOAD (float32)
605- MMAP_VALSTORE_LOAD(str )
605+ MMAP_VALSTORE_LOAD(bytes )
606606
607607 // Create view from external values pointer
608608 void mmap_valstore_from_vals_float32 (
@@ -614,41 +614,41 @@ extern "C" {
614614 static_cast <mmap_valstore_float32 *>(map_ptr)->from_vals (n_row, n_col, vals);
615615 }
616616 // Allocate and Init
617- void mmap_valstore_from_vals_str (
617+ void mmap_valstore_from_vals_bytes (
618618 void * map_ptr,
619619 const row_type n_row,
620620 const col_type n_col,
621621 const char * const * vals,
622- const mmap_valstore_str::str_len_type * vals_lens
622+ const mmap_valstore_bytes::bytes_len_type * vals_lens
623623 ) {
624- static_cast <mmap_valstore_str *>(map_ptr)->from_vals (n_row, n_col, vals, vals_lens);
624+ static_cast <mmap_valstore_bytes *>(map_ptr)->from_vals (n_row, n_col, vals, vals_lens);
625625 }
626626
627627 // Get sub-matrix
628- void mmap_valstore_get_submatrix_float32 (
628+ void mmap_valstore_batch_get_float32 (
629629 void * map_ptr,
630- const uint32_t n_sub_row,
631- const uint32_t n_sub_col,
630+ const uint64_t n_sub_row,
631+ const uint64_t n_sub_col,
632632 const row_type* sub_rows,
633633 const col_type* sub_cols,
634634 mmap_valstore_float32::value_type* ret,
635635 const int threads
636636 ) {
637- static_cast <mmap_valstore_float32 *>(map_ptr)->get_submatrix (
637+ static_cast <mmap_valstore_float32 *>(map_ptr)->batch_get (
638638 n_sub_row, n_sub_col, sub_rows, sub_cols, ret, threads);
639639 }
640- void mmap_valstore_get_submatrix_str (
640+ void mmap_valstore_batch_get_bytes (
641641 void * map_ptr,
642- const uint32_t n_sub_row,
643- const uint32_t n_sub_col,
642+ const uint64_t n_sub_row,
643+ const uint64_t n_sub_col,
644644 const row_type* sub_rows,
645645 const col_type* sub_cols,
646- const mmap_valstore_str::str_len_type trunc_val_len,
646+ const mmap_valstore_bytes::bytes_len_type trunc_val_len,
647647 char * ret,
648- mmap_valstore_str::str_len_type * ret_lens,
648+ mmap_valstore_bytes::bytes_len_type * ret_lens,
649649 const int threads
650650 ) {
651- static_cast <mmap_valstore_str *>(map_ptr)->get_submatrix (
651+ static_cast <mmap_valstore_bytes *>(map_ptr)->batch_get (
652652 n_sub_row, n_sub_col, sub_rows, sub_cols, trunc_val_len, ret, ret_lens, threads);
653653 }
654654}
0 commit comments