Skip to content

Commit

Permalink
[FIX] Sanitizer
Browse files Browse the repository at this point in the history
  • Loading branch information
eseiler committed Sep 25, 2024
1 parent cce9378 commit 0458944
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/ci_sanitizer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ concurrency:

env:
TZ: Europe/Berlin
ASAN_OPTIONS: strict_string_checks=1:detect_stack_use_after_return=1:check_initialization_order=1:strict_init_order=1:detect_leaks=1
TSAN_OPTIONS: ignore_noninstrumented_modules=1
UBSAN_OPTIONS: print_stacktrace=1

Expand All @@ -28,6 +27,8 @@ jobs:
name: ${{ matrix.name }} ${{ matrix.build_type }} ${{ matrix.os }}
runs-on: ${{ matrix.os }}
if: github.repository_owner == 'seqan' || github.event_name == 'workflow_dispatch'
env:
ASAN_OPTIONS: strict_string_checks=1:detect_stack_use_after_return=1:check_initialization_order=1:strict_init_order=1:detect_leaks=${{ contains(matrix.os, 'macos') && '0' || '1' }}
strategy:
fail-fast: false
matrix:
Expand Down
14 changes: 10 additions & 4 deletions src/ibf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -865,17 +865,23 @@ void ibf_helper(std::vector<std::filesystem::path> const & minimiser_files,
{
if (elem.second >= expressions[i][j])
{
ibfs[j].emplace(elem.first, seqan3::bin_index{i});
counts_per_level[i][j]++;
#pragma omp critical
{
ibfs[j].emplace(elem.first, seqan3::bin_index{i});
counts_per_level[i][j]++;
}
break;
}
}
else
{
if (elem.second >= ibf_args.expression_thresholds[j])
{
ibfs[j].emplace(elem.first, seqan3::bin_index{i});
counts_per_level[i][j]++;
#pragma omp critical
{
ibfs[j].emplace(elem.first, seqan3::bin_index{i});
counts_per_level[i][j]++;
}
break;
}
}
Expand Down

0 comments on commit 0458944

Please sign in to comment.