diff --git a/src/unifrac_task.hpp b/src/unifrac_task.hpp index 7900059..a6b88c5 100644 --- a/src/unifrac_task.hpp +++ b/src/unifrac_task.hpp @@ -69,14 +69,14 @@ namespace SUCMP_NM { #ifdef _OPENACC const uint64_t bufels = n_samples_r * (stop_idx-start_idx); #endif - for(unsigned int stripe=start_idx; stripe < stop_idx; stripe++) { + for(uint64_t stripe=start_idx; stripe < stop_idx; stripe++) { double * dm_stripe = dm_stripes[stripe]; - TFloat * buf_stripe = this->operator[](stripe); - for(unsigned int j=0; j(const UnifracTaskVector& ) = delete; UnifracTaskVector& operator= (const UnifracTaskVector&) = delete; - TFloat * operator[](unsigned int idx) { return buf+((idx-start_idx)*n_samples_r);} - const TFloat * operator[](unsigned int idx) const { return buf+((idx-start_idx)*n_samples_r);} + TFloat * operator[](unsigned int idx) { return buf+buf_idx(idx);} + const TFloat * operator[](unsigned int idx) const { return buf+buf_idx(idx);} ~UnifracTaskVector() @@ -102,10 +102,10 @@ namespace SUCMP_NM { const uint64_t bufels = n_samples_r * (stop_idx-start_idx); #pragma acc exit data copyout(ibuf[:bufels]) #endif - for(unsigned int stripe=start_idx; stripe < stop_idx; stripe++) { + for(uint64_t stripe=start_idx; stripe < stop_idx; stripe++) { double * dm_stripe = dm_stripes[stripe]; - TFloat * buf_stripe = this->operator[](stripe); - for(unsigned int j=0; j