@@ -21,7 +21,7 @@ namespace ashvardanian {
2121namespace stringzilla {
2222namespace scripts {
2323
24- void log_environment () {
24+ int log_environment () {
2525 std::printf (" - Uses Haswell: %s \n " , SZ_USE_HASWELL ? " yes" : " no" );
2626 std::printf (" - Uses Skylake: %s \n " , SZ_USE_SKYLAKE ? " yes" : " no" );
2727 std::printf (" - Uses Ice Lake: %s \n " , SZ_USE_ICE ? " yes" : " no" );
@@ -57,6 +57,7 @@ void log_environment() {
5757 std::printf (" - CUDA managed memory support: %s\n " , prop.managedMemory == 1 ? " yes" : " no" );
5858 std::printf (" - CUDA unified memory support: %s\n " , prop.unifiedAddressing == 1 ? " yes" : " no" );
5959#endif
60+ return 0 ;
6061}
6162
6263/* *
@@ -527,15 +528,15 @@ void test_similarity_scores_memory_usage() {
527528 experiment.batch_size , experiment.min_string_length , experiment.max_string_length ,
528529 experiment.iterations );
529530
530- // Single-threaded serial Levenshtein distance implementation
531- test_similarity_scores_fuzzy<sz_size_t >( //
532- levenshtein_baselines_t {}, //
533- levenshtein_distances<sz_cap_serial_k, char , std::allocator<char >> {}, experiment);
534-
535- // Multi-threaded parallel Levenshtein distance implementation
531+ // Multi-threaded serial Levenshtein distance implementation
536532 test_similarity_scores_fuzzy<sz_size_t >( //
537533 levenshtein_baselines_t {}, //
538534 levenshtein_distances<sz_cap_parallel_k, char , std::allocator<char >> {}, experiment);
535+
536+ // CUDA Levenshtein distance against Multi-threaded on CPU
537+ test_similarity_scores_fuzzy<sz_size_t >( //
538+ levenshtein_distances<sz_cap_parallel_k, char , std::allocator<char >> {}, //
539+ levenshtein_distances<sz_cap_cuda_k, char , std::allocator<char >> {}, experiment);
539540 }
540541}
541542
0 commit comments