         /******       APPROX          ******/
         /***********************************/
 
-        n_total = calc_prefix<DIM2>(prefix, tid,  1 - (split || !use_node));
+        n_total = calc_prefix<DIM2>(prefix, 1 - (split || !use_node));
         offset = prefix[tid];
 
         if (!split && use_node) approxM[n_approx + offset - 1] = node;


template<const int DIM2>
__device__ __forceinline__ int inclusive_segscan_block64(
    int *shmem, const int tid, const int packed_value, int &dist_block, int &nseg)
{
#if 0
  const int laneId = tid & (WARP_SIZE - 1);
  const int warpId = tid >> WARP_SIZE2;
#endif

  const int  flag = packed_value < 0;
  const int  mask = BTEST(flag);
  const int value = (mask & (-1-packed_value)) + (~mask & 1);

          __syncthreads();

          // step 2:
          const int nl = inclusive_segscan_array<DIM2>(&body_list[n_direct], nb);
          nb = directM[prefix[nl_pre + nl - 1]];                       // number of bodies stored in these leaves
          __syncthreads();

