2 // @(#) $Id: AliHLTTPCCATracker.h 33907 2009-07-23 13:52:49Z sgorbuno $
3 // ************************************************************************
4 // This file is property of and copyright by the ALICE HLT Project *
5 // ALICE Experiment at CERN, All rights reserved. *
6 // See cxx source for full Copyright notice *
8 //*************************************************************************
10 #ifndef ALIHLTTPCCATRACKERFRAMEWORK_H
11 #define ALIHLTTPCCATRACKERFRAMEWORK_H
13 #include "AliHLTTPCCATracker.h"
14 #include "AliHLTTPCCAGPUTracker.h"
15 #include "AliHLTTPCCAParam.h"
16 #include "AliHLTTPCCASliceOutput.h"
17 #include "AliHLTLogging.h"
20 class AliHLTTPCCASliceOutput;
21 class AliHLTTPCCAClusterData;
23 class AliHLTTPCCATrackerFramework : AliHLTLogging
26 AliHLTTPCCATrackerFramework(int allowGPU = 1);
27 ~AliHLTTPCCATrackerFramework();
29 int InitGPU(int sliceCount = 1, int forceDeviceID = -1);
31 void SetGPUDebugLevel(int Level, std::ostream *OutFile = NULL, std::ostream *GPUOutFile = NULL);
32 int SetGPUTrackerOption(char* OptionName, int OptionValue) {return(fGPUTracker->SetGPUTrackerOption(OptionName, OptionValue));}
33 int SetGPUTracker(bool enable);
35 int InitializeSliceParam(int iSlice, AliHLTTPCCAParam ¶m);
37 GPUhd() const AliHLTTPCCASliceOutput::outputControlStruct* OutputControl() const { return fOutputControl; }
38 GPUhd() void SetOutputControl( AliHLTTPCCASliceOutput::outputControlStruct* val);
40 int ProcessSlices(int firstSlice, int sliceCount, AliHLTTPCCAClusterData* pClusterData, AliHLTTPCCASliceOutput** pOutput);
41 unsigned long long int* PerfTimer(int GPU, int iSlice, int iTimer);
43 int MaxSliceCount() const { return(fUseGPUTracker ? fGPUSliceCount : fCPUSliceCount); }
44 int GetGPUStatus() const { return(fGPUTrackerAvailable + fUseGPUTracker); }
46 const AliHLTTPCCAParam& Param(int iSlice) const { return(fCPUTrackers[iSlice].Param()); }
47 const AliHLTTPCCARow& Row(int iSlice, int iRow) const { return(fCPUTrackers[iSlice].Row(iRow)); } //TODO: Should be changed to return only row parameters
50 static const int fgkNSlices = 36; //* N slices
52 bool fGPULibAvailable; //Is the Library with the GPU code available at all?
53 bool fGPUTrackerAvailable; // Is the GPU Tracker Available?
54 bool fUseGPUTracker; // use the GPU tracker
55 int fGPUDebugLevel; // debug level for the GPU code
56 int fGPUSliceCount; //How many slices to process parallel
57 AliHLTTPCCAGPUTracker* fGPUTracker;
60 AliHLTTPCCASliceOutput::outputControlStruct* fOutputControl;
62 AliHLTTPCCATracker fCPUTrackers[fgkNSlices];
65 AliHLTTPCCATrackerFramework( const AliHLTTPCCATrackerFramework& );
66 AliHLTTPCCATrackerFramework &operator=( const AliHLTTPCCATrackerFramework& );
68 ClassDef( AliHLTTPCCATrackerFramework, 0 )
72 #endif //ALIHLTTPCCATRACKERFRAMEWORK_H