in reply to What is the best approach to check if a position falls within a target range?

If step #2 is doing what it sounds like you're doing, you're making a (shallow) copy of the array, which will double the amount of memory used for that data. Instead, work with the array ref directly. This may apply for step #3 too, depending on how that's implemented.

For example, instead of
my @data = @{ $hash{chrN} }; for my $SNP (@data) { ... }
do
for my $SNP (@{ $hash{chrN} }) { ... }
or
my $data_ref = $hash{chrN}; for my $SNP (@$data_ref) { ... }