Skip to content

Commit 221cc53

Browse files
committed
Fix algorithm names
1 parent ab9376d commit 221cc53

File tree

1 file changed

+37
-36
lines changed

1 file changed

+37
-36
lines changed

benchmarks/bulk-insert-and-query.cc

Lines changed: 37 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -633,28 +633,28 @@ int main(int argc, char * argv[]) {
633633
auto cf = FilterBenchmark<
634634
CuckooFilterStable<uint64_t, 8, SingleTable, SimpleMixSplit>>(
635635
add_count, to_add, to_lookup, seed);
636-
cout << setw(NAME_WIDTH) << "CuckooStable8" << cf << endl;
636+
cout << setw(NAME_WIDTH) << "Cuckoo8" << cf << endl;
637637
}
638638

639639
if (algorithmId == 4 || algorithmId < 0) {
640640
auto cf = FilterBenchmark<
641641
CuckooFilterStable<uint64_t, 12, SingleTable, SimpleMixSplit>>(
642642
add_count, to_add, to_lookup, seed);
643-
cout << setw(NAME_WIDTH) << "CuckooStable12" << cf << endl;
643+
cout << setw(NAME_WIDTH) << "Cuckoo12" << cf << endl;
644644
}
645645

646646
if (algorithmId == 5 || algorithmId < 0) {
647647
auto cf = FilterBenchmark<
648648
CuckooFilterStable<uint64_t, 16, SingleTable, SimpleMixSplit>>(
649649
add_count, to_add, to_lookup, seed);
650-
cout << setw(NAME_WIDTH) << "CuckooStable16" << cf << endl;
650+
cout << setw(NAME_WIDTH) << "Cuckoo16" << cf << endl;
651651
}
652652

653653
if (algorithmId == 6 || algorithmId < 0) {
654654
auto cf = FilterBenchmark<
655655
CuckooFilterStable<uint64_t, 13, PackedTable, SimpleMixSplit>>(
656656
add_count, to_add, to_lookup, seed);
657-
cout << setw(NAME_WIDTH) << "CuckooSemiSortStable13" << cf << endl;
657+
cout << setw(NAME_WIDTH) << "CuckooSemiSort13" << cf << endl;
658658
}
659659

660660
if (algorithmId == 7 || algorithmId < 0) {
@@ -680,106 +680,107 @@ int main(int argc, char * argv[]) {
680680

681681
#ifdef __AVX2__
682682
if (algorithmId == 10 || algorithmId < 0) {
683-
auto cf = FilterBenchmark<SimdBlockFilter<SimpleMixSplit>>(
683+
auto cf = FilterBenchmark<SimdBlockFilterFixed<SimpleMixSplit>>(
684684
add_count, to_add, to_lookup, seed);
685685
cout << setw(NAME_WIDTH) << "BlockedBloom" << cf << endl;
686686
}
687687
#endif
688688

689689
if (algorithmId == 11 || algorithmId < 0) {
690-
auto cf = FilterBenchmark<
691-
GcsFilter<uint64_t, 8, SimpleMixSplit>>(
692-
add_count, to_add, to_lookup, seed);
693-
cout << setw(NAME_WIDTH) << "GCS" << cf << endl;
690+
auto start_time = NowNanos();
691+
std::sort(to_add.begin(), to_add.end());
692+
const auto sort_time = NowNanos() - start_time;
693+
std::cout << "Sort time: " << sort_time / to_add.size() << " ns/key\n";
694694
}
695695

696-
#ifdef __AVX2__
697696
if (algorithmId == 12 || algorithmId < 0) {
698697
auto cf = FilterBenchmark<
699-
GQFilter<uint64_t, 8, SimpleMixSplit>>(
698+
XorFilterPlus<uint64_t, uint8_t, SimpleMixSplit>>(
700699
add_count, to_add, to_lookup, seed);
701-
cout << setw(NAME_WIDTH) << "CQF" << cf << endl;
700+
cout << setw(NAME_WIDTH) << "Xor+8" << cf << endl;
702701
}
703-
#endif
704702

705703
if (algorithmId == 13 || algorithmId < 0) {
706704
auto cf = FilterBenchmark<
707-
XorFilterPlus<uint64_t, uint8_t, SimpleMixSplit>>(
705+
XorFilterPlus<uint64_t, uint16_t, SimpleMixSplit>>(
708706
add_count, to_add, to_lookup, seed);
709-
cout << setw(NAME_WIDTH) << "Xor+8" << cf << endl;
707+
cout << setw(NAME_WIDTH) << "Xor+16" << cf << endl;
710708
}
711709

712710
if (algorithmId == 14 || algorithmId < 0) {
713711
auto cf = FilterBenchmark<
714-
XorFilterPlus<uint64_t, uint16_t, SimpleMixSplit>>(
712+
GcsFilter<uint64_t, 8, SimpleMixSplit>>(
715713
add_count, to_add, to_lookup, seed);
716-
cout << setw(NAME_WIDTH) << "Xor+16" << cf << endl;
714+
cout << setw(NAME_WIDTH) << "GCS" << cf << endl;
717715
}
718716

719717
#ifdef __AVX2__
720718
if (algorithmId == 15 || algorithmId < 0) {
721-
auto cf = FilterBenchmark<SimdBlockFilterFixed<SimpleMixSplit>>(
719+
auto cf = FilterBenchmark<
720+
GQFilter<uint64_t, 8, SimpleMixSplit>>(
722721
add_count, to_add, to_lookup, seed);
723-
cout << setw(NAME_WIDTH) << "BlockedBloomFixed" << cf << endl;
722+
cout << setw(NAME_WIDTH) << "CQF" << cf << endl;
724723
}
725724
#endif
726725

726+
// other algorithms, but not all that interesting or
727+
// not fully optimized
728+
729+
#ifdef __AVX2__
727730
if (algorithmId == 16 || algorithmId < 0) {
728-
auto start_time = NowNanos();
729-
std::sort(to_add.begin(), to_add.end());
730-
const auto sort_time = NowNanos() - start_time;
731-
std::cout << "Sort time: " << sort_time / to_add.size() << " ns/key\n";
731+
auto cf = FilterBenchmark<SimdBlockFilter<SimpleMixSplit>>(
732+
add_count, to_add, to_lookup, seed);
733+
cout << setw(NAME_WIDTH) << "BlockedBloom-2^n" << cf << endl;
732734
}
735+
#endif
733736

734-
// other algorithms, but not all that interesting or
735-
// not fully optimized
736737
if (algorithmId == 17 || algorithmId < 0) {
737738
auto cf = FilterBenchmark<
738739
CuckooFilter<uint64_t, 8, SingleTable, SimpleMixSplit>>(
739740
add_count, to_add, to_lookup, seed);
740-
cout << setw(NAME_WIDTH) << "Cuckoo2^n-8" << cf << endl;
741+
cout << setw(NAME_WIDTH) << "Cuckoo8-2^n" << cf << endl;
741742
}
742743

743744
if (algorithmId == 18 || algorithmId < 0) {
744745
auto cf = FilterBenchmark<
745746
CuckooFilter<uint64_t, 12, SingleTable, SimpleMixSplit>>(
746747
add_count, to_add, to_lookup, seed);
747-
cout << setw(NAME_WIDTH) << "Cuckoo2^n-12" << cf << endl;
748+
cout << setw(NAME_WIDTH) << "Cuckoo12-2^n" << cf << endl;
748749
}
749750

750751
if (algorithmId == 19 || algorithmId < 0) {
751752
auto cf = FilterBenchmark<
752753
CuckooFilter<uint64_t, 16, SingleTable, SimpleMixSplit>>(
753754
add_count, to_add, to_lookup, seed);
754-
cout << setw(NAME_WIDTH) << "Cuckoo2^n-16" << cf << endl;
755+
cout << setw(NAME_WIDTH) << "Cuckoo16-2^n" << cf << endl;
755756
}
756757

757758
if (algorithmId == 20 || algorithmId < 0) {
758759
auto cf = FilterBenchmark<
759760
CuckooFilter<uint64_t, 13, PackedTable, SimpleMixSplit>>(
760761
add_count, to_add, to_lookup, seed);
761-
cout << setw(NAME_WIDTH) << "CuckooSemiSort2^n-13" << cf << endl;
762+
cout << setw(NAME_WIDTH) << "CuckooSemiSort13-2^n" << cf << endl;
762763
}
763764

764765
if (algorithmId == 21 || algorithmId < 0) {
765766
auto cf = FilterBenchmark<
766767
XorFilter2n<uint64_t, uint8_t, UIntArray<uint8_t>, SimpleMixSplit>>(
767768
add_count, to_add, to_lookup, seed);
768-
cout << setw(NAME_WIDTH) << "Xor2^n-8" << cf << endl;
769+
cout << setw(NAME_WIDTH) << "Xor8-2^n" << cf << endl;
769770
}
770771

771772
if (algorithmId == 22 || algorithmId < 0) {
772773
auto cf = FilterBenchmark<
773774
XorFilter2<uint64_t, uint16_t, NBitArray<uint16_t, 10>, SimpleMixSplit>>(
774775
add_count, to_add, to_lookup, seed);
775-
cout << setw(NAME_WIDTH) << "Xor-10" << cf << endl;
776+
cout << setw(NAME_WIDTH) << "Xor10" << cf << endl;
776777
}
777778

778779
if (algorithmId == 23 || algorithmId < 0) {
779780
auto cf = FilterBenchmark<
780781
XorFilter2<uint64_t, uint16_t, NBitArray<uint16_t, 14>, SimpleMixSplit>>(
781782
add_count, to_add, to_lookup, seed);
782-
cout << setw(NAME_WIDTH) << "Xor-14" << cf << endl;
783+
cout << setw(NAME_WIDTH) << "Xor14" << cf << endl;
783784
}
784785

785786
if (algorithmId == 24 || algorithmId < 0) {
@@ -792,18 +793,18 @@ int main(int argc, char * argv[]) {
792793

793794
// broken algorithms (don't always find all key)
794795
/*
795-
if (algorithmId == 24 || algorithmId < 0) {
796+
if (algorithmId == 25 || algorithmId < 0) {
796797
auto cf = FilterBenchmark<
797798
CuckooFilter<uint64_t, 9, PackedTable, SimpleMixSplit>>(
798799
add_count, to_add, to_lookup, seed);
799-
cout << setw(NAME_WIDTH) << "SemiSort-9-2^n" << cf << endl;
800+
cout << setw(NAME_WIDTH) << "CuckooSemiSort9-2^n" << cf << endl;
800801
}
801802
802-
if (algorithmId == 25 || algorithmId < 0) {
803+
if (algorithmId == 26 || algorithmId < 0) {
803804
auto cf = FilterBenchmark<
804805
CuckooFilter<uint64_t, 17, PackedTable, SimpleMixSplit>>(
805806
add_count, to_add, to_lookup, seed);
806-
cout << setw(NAME_WIDTH) << "SemiSort-17-2^n" << cf << endl;
807+
cout << setw(NAME_WIDTH) << "CuckooSemiSort17-2^n" << cf << endl;
807808
}
808809
*/
809810

0 commit comments

Comments
 (0)