     if( i >= gridNSample ) return;
     if( j >= gridNSample ) return;
 
-
-    NearbyPoint* nPoint;
-    identification::CutSignals* signals;
-
-    {
-        const int idx = j * gridNSample + i;
-        nPoint  = &point_buffer[idx];
-        signals = &sig_buffer[idx * vCutsSize];
-    }
-
-    nPoint->point = make_float2( center.x - halfWidth + i*stepSize,
-                                center.y - halfWidth + j*stepSize );
+    const int idx = j * gridNSample + i;
+
+
+    NearbyPoint* nPoint = &point_buffer[idx];
+    identification::CutSignals* signals = &sig_buffer[idx * vCutsSize];
+
+    float2 condCenter = make_float2( center.x - halfWidth + i*stepSize,
+                                     center.y - halfWidth + j*stepSize );
 
     popart::geometry::matrix3x3  mInvT;
     mT.invert( mInvT ); // note: returns false if it fails
-    mInvT.condition( nPoint->point );
-
+    mInvT.condition( condCenter );
+
+    nPoint->point    = condCenter;
     nPoint->result   = 0.0f;
     nPoint->resSize  = 0;
     nPoint->readable = true;

 */
__global__
void idComputeResult( const int         tagIndex,
                      NearbyPoint*      nPoint,
                      const CutStruct*  vCuts,
                      const CutSignals* allcut_signals,
                      const int         vCutsSize )
{
    int myPair = blockIdx.x * 32 + threadIdx.y;
    int j      = __float2int_rd( 1.0f + __fsqrt_rd(1.0f+8.0f*myPair) ) / 2;
    int i      = myPair - j*(j-1)/2;


        ct  += __shfl_down( ct,  1 );

        if( threadIdx.x == 0 ) {
#ifdef NO_ATOMIC
            nPoint->result  += val;
            nPoint->resSize += ct;
#else
            atomicAdd( &nPoint->result,  val );
            atomicAdd( &nPoint->resSize, ct );
#endif
        }
    }
#ifdef NO_ATOMIC
    __syncthreads();
  }
#endif
}

__global__
