Skip to content

Commit

Permalink
mark known bottleneck with a comment
Browse files Browse the repository at this point in the history
Updates #685
  • Loading branch information
shawnlaffan committed Feb 24, 2018
1 parent a3d9d5b commit 1d6b62a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/Biodiverse/Randomise.pm
Original file line number Diff line number Diff line change
Expand Up @@ -2619,6 +2619,9 @@ sub swap_to_reach_richness_targets {
# clean up the tracker hashes
$filled_groups{$last_filled} = $new_richness;
delete $unfilled_groups{$last_filled};
# THIS NEXT LOOP IS A MAJOR BOTTLENECK (bremove call)
# when working with large data sets
# need to avoid indexing in the first place?
foreach my $label (keys %{$unfilled_gps_without_label_by_gp{$last_filled}}) {
my $list = $unfilled_gps_without_label{$label};
bremove {$_ cmp $last_filled} @$list;
Expand Down

0 comments on commit 1d6b62a

Please sign in to comment.