]>
Commit | Line | Data |
---|---|---|
00d07bcd | 1 | // @(#) $Id: AliHLTTPCCAUsedHitsInitialiser.cxx 27042 2008-07-02 12:06:02Z richterm $ |
d54804bf | 2 | //*************************************************************************** |
3 | // This file is property of and copyright by the ALICE HLT Project * | |
4 | // ALICE Experiment at CERN, All rights reserved. * | |
5 | // * | |
6 | // Primary Authors: Sergey Gorbunov <sergey.gorbunov@kip.uni-heidelberg.de> * | |
7 | // Ivan Kisel <kisel@kip.uni-heidelberg.de> * | |
8 | // for The ALICE HLT Project. * | |
9 | // * | |
10 | // Permission to use, copy, modify and distribute this software and its * | |
11 | // documentation strictly for non-commercial purposes is hereby granted * | |
12 | // without fee, provided that the above copyright notice appears in all * | |
13 | // copies and that both the copyright notice and this permission notice * | |
14 | // appear in the supporting documentation. The authors make no claims * | |
15 | // about the suitability of this software for any purpose. It is * | |
16 | // provided "as is" without express or implied warranty. * | |
17 | //*************************************************************************** | |
326c2d4b | 18 | |
00d07bcd | 19 | #include "AliHLTTPCCAUsedHitsInitialiser.h" |
20 | #include "AliHLTTPCCATracker.h" | |
326c2d4b | 21 | |
22 | ||
00d07bcd | 23 | void AliHLTTPCCAUsedHitsInitialiser::Thread |
24 | ( Int_t nBlocks, Int_t nThreads, Int_t iBlock, Int_t iThread, Int_t iSync, | |
25 | AliHLTTPCCASharedMemory &s, AliHLTTPCCATracker &tracker ) | |
dc4788ec | 26 | { |
00d07bcd | 27 | // initialise used hit flags with 0 |
28 | ||
29 | if( iSync==0 ) | |
30 | { | |
31 | if( iThread==0 ){ | |
32 | s.fNHits = tracker.NHitsTotal(); | |
33 | s.fUsedHits = tracker.HitIsUsed(); | |
34 | s.fNThreadsTotal = nThreads*nBlocks; | |
35 | s.fIh0 = nThreads*iBlock; | |
36 | } | |
37 | } | |
38 | else if( iSync==1 ) | |
39 | { | |
40 | for( int ih=s.fIh0 + iThread; ih<s.fNHits; ih+=s.fNThreadsTotal ) s.fUsedHits[ih] = 0; | |
41 | } | |
dc4788ec | 42 | } |
00d07bcd | 43 |