2 // ************************************************************************
3 // This file is property of and copyright by the ALICE HLT Project *
4 // ALICE Experiment at CERN, All rights reserved. *
5 // See cxx source for full Copyright notice *
7 //*************************************************************************
9 #ifndef ALIHLTTPCCASTARTHITSFINDER_H
10 #define ALIHLTTPCCASTARTHITSFINDER_H
12 #include "AliHLTTPCCADef.h"
13 #include "AliHLTTPCCAHitId.h"
15 MEM_CLASS_PRE() class AliHLTTPCCATracker;
18 * @class AliHLTTPCCAStartHitsFinder
21 class AliHLTTPCCAStartHitsFinder
24 MEM_CLASS_PRE() class AliHLTTPCCASharedMemory
26 friend class AliHLTTPCCAStartHitsFinder;
28 #if !defined(HLTCA_GPUCODE)
29 AliHLTTPCCASharedMemory()
30 : fIRow( 0 ), fNRows( 0 ), fNHits( 0 ), fNOldStartHits( 0 ), fNRowStartHits( 0 ) {
33 for( int i=0; i<ALIHLTTPCCASTARTHITSFINDER_MAX_FROWSTARTHITS; i++)fRowStartHits[i] = tmp;
36 AliHLTTPCCASharedMemory( const AliHLTTPCCASharedMemory& /*dummy*/ )
37 : fIRow( 0 ), fNRows( 0 ), fNHits( 0 ), fNOldStartHits( 0 ), fNRowStartHits( 0 ) {
40 for( int i=0; i<ALIHLTTPCCASTARTHITSFINDER_MAX_FROWSTARTHITS; i++)fRowStartHits[i] = tmp;
42 AliHLTTPCCASharedMemory& operator=( const AliHLTTPCCASharedMemory& /*dummy*/ ) { return *this; }
43 #endif //!HLTCA_GPUCODE
46 int fIRow; // row index
48 int fNHits; // n hits in the row
49 AliHLTTPCCAHitId fRowStartHits[ALIHLTTPCCASTARTHITSFINDER_MAX_FROWSTARTHITS]; // temp. array for the start hits
50 int fNOldStartHits; // n start hits from other jobs
51 int fNRowStartHits; // n start hits for this row
54 GPUd() static int NThreadSyncPoints() { return 3; }
56 GPUd() static void Thread( int nBlocks, int nThreads, int iBlock, int iThread, int iSync,
57 MEM_LOCAL(GPUsharedref() AliHLTTPCCASharedMemory) &smem, MEM_CONSTANT(GPUconstant() AliHLTTPCCATracker) &tracker );
61 #endif //ALIHLTTPCCASTARTHITSFINDER_H