 |
ATLAS Offline Software
|
Go to the documentation of this file.
6 #ifndef EFTRACKING_FPGA_INTEGRATION_F150KERNELTESTERALG_H
7 #define EFTRACKING_FPGA_INTEGRATION_F150KERNELTESTERALG_H
20 #include "xrt/xrt_device.h"
21 #include "xrt/xrt_kernel.h"
22 #include <experimental/xrt_ip.h>
25 #include "CL/cl2xrt.hpp"
28 #include "GaudiKernel/ServiceHandle.h"
29 #include "GaudiKernel/IChronoSvc.h"
35 #define EVENT_COUNT_RST 0x80000000
36 #define USER_CTRL_OFFSET 0x10
43 using IntegrationBase::IntegrationBase;
51 "ChronoStatSvc",
name()};
57 "Tool for creating xAOD cluster containers"};
60 this,
"TestVectorTool",
"TestVectorTool",
"Tool for preparing test vectors"};
63 this,
"FPGADataFormatTool",
"FPGADataFormatTool",
"Tool for formatting FPGA data"};
65 Gaudi::Property<std::string>
m_xclbin{
this,
"xclbin",
"",
"xclbin path and name"};
67 Gaudi::Property<bool>
m_runSE{
this,
"RunSlicing",
"",
"Whether to run slicing engine or not"};
68 Gaudi::Property<bool>
m_runIO{
this,
"RunInsideOut",
"",
"Whether to run inside out or not"};
69 Gaudi::Property<bool>
m_runIOOnSE{
this,
"RunInsideOutOnSlicingEngine",
"",
"Whether to run inside out on the output of the slicing engine"};
70 Gaudi::Property<bool>
m_runFull150{
this,
"RunFullF150",
"",
"Whether to run Full 150 chain"};
71 Gaudi::Property<bool>
m_outputTextFile{
this,
"outputTextFile",
"",
"Whether to output text file"};
80 ToolHandle<OutputConversionTool>
m_outputConversionTool{
this,
"OutputConversionTool",
"OutputConversionTool",
"tool for output conversion"};
83 Gaudi::Property<std::string>
m_slicingEngineInputName{
this,
"SlicingEngineInputName",
"",
"Name of the slicing engine input kernel"};
84 Gaudi::Property<std::string>
m_slicingEngineOutputName{
this,
"SlicingEngineOutputName",
"",
"Name of the slicing engine output kernel"};
85 Gaudi::Property<std::string>
m_insideOutInputName{
this,
"InsideOutInputName",
"",
"Name of the inside out input kernel"};
86 Gaudi::Property<std::string>
m_insideOutOutputName{
this,
"InsideOutOutputName",
"",
"Name of the inside out output kernel"};
89 Gaudi::Property<std::string>
m_pixelEdmKernelName{
this,
"PixelEDMPrepKernelName",
"",
"Name of the FPGA kernel"};
90 Gaudi::Property<std::string>
m_stripEdmKernelName{
this,
"StripEDMPrepKernelName",
"",
"Name of the FPGA kernel"};
91 Gaudi::Property<std::string>
m_pixelClusterKernelName{
this,
"PixelClusterKernelName",
"",
"Name of the pixel clustering kernel"};
92 Gaudi::Property<std::string>
m_stripClusterKernelName{
this,
"StripClusterKernelName",
"",
"Name of the strip clustering kernel"};
93 Gaudi::Property<std::string>
m_stripL2GKernelName{
this,
"StripL2GKernelName",
"",
"Name of the strip L2G kernel"};
154 std::string
get_cu_name(
const std::string& kernel_name,
int cu);
156 void dumpHexData(std::span<const uint64_t>
data,
const std::string &dataDescriptor,
const EventContext &ctx)
const;
160 #endif // EFTRACKING_FPGA_INTEGRATION_F150KERNELTESTERALG_H
cl::Kernel m_stripL2GKernel ATLAS_THREAD_SAFE
std::string get_cu_name(const std::string &kernel_name, int cu)
The base class for the EFTracking FPGA integration development.
char data[hepevt_bytes_allocation_ATLAS]
cl::Kernel m_insideOutOutput ATLAS_THREAD_SAFE
Gaudi::Property< std::string > m_slicingEngineInputName
ToolHandle< FPGADataFormatTool > m_FPGADataFormatTool
Tool for formatting FPGA data.
cl::Event m_slicingEngineOutputEndEvent ATLAS_THREAD_SAFE
cl::Kernel m_slicingEngineInput ATLAS_THREAD_SAFE
cl::Kernel m_slicingEngineOutput ATLAS_THREAD_SAFE
ServiceHandle< IChronoSvc > m_chronoSvc
Service for timing the algorithm.
Gaudi::Property< bool > m_runFull150
Whether to run the Full F150 include F100 on hy.
Gaudi::Property< std::string > m_slicingEngineOutputName
ToolHandle< OutputConversionTool > m_outputConversionTool
Gaudi::Property< std::string > m_insideOutInputName
virtual StatusCode execute(const EventContext &ctx) const override final
Should be overriden by derived classes to perform meaningful work.
SG::WriteHandleKey< std::vector< uint64_t > > m_FPGATrackOutput
cl::Buffer m_insideOutInputBuffer ATLAS_THREAD_SAFE
SG::WriteHandleKey< std::vector< uint64_t > > m_FPGAPixelOutput
cl::Kernel m_insideOutInput ATLAS_THREAD_SAFE
cl::Kernel m_stripEdmPrepKernel ATLAS_THREAD_SAFE
Gaudi::Property< bool > m_runIOOnSE
Whether to run inside out on the output of slicing engine.
SG::WriteHandleKey< std::vector< uint64_t > > m_FPGAStripOutput
Gaudi::Property< std::string > m_pixelEdmKernelName
Name of the FPGA kernel.
cl::Buffer m_stripL2GEDMOutputBuffer ATLAS_THREAD_SAFE
cl::Buffer m_stripClusterEDMOutputBuffer ATLAS_THREAD_SAFE
cl::Event m_insideOutEndEvent ATLAS_THREAD_SAFE
cl::Buffer m_pixelClusterEDMOutputBuffer ATLAS_THREAD_SAFE
cl::Kernel m_stripClusteringKernel ATLAS_THREAD_SAFE
void dumpHexData(std::span< const uint64_t > data, const std::string &dataDescriptor, const EventContext &ctx) const
SG::ReadHandleKey< std::vector< uint64_t > > m_FPGAPixelRDO
Property holding a SG store/key/clid from which a WriteHandle is made.
Gaudi::Property< bool > m_outputTextFile
Whether to run SE or not.
ToolHandle< xAODClusterMaker > m_xaodClusterMaker
Tool for creating xAOD containers.
Gaudi::Property< std::string > m_stripClusterKernelName
Name of the strip clustering kernel.
::StatusCode StatusCode
StatusCode definition for legacy code.
cl::Buffer m_slicingEngineOutputBuffer ATLAS_THREAD_SAFE
cl::Buffer m_slicingEngineInputBuffer ATLAS_THREAD_SAFE
SG::ReadHandleKey< std::vector< uint64_t > > m_FPGAStripRDO
virtual StatusCode initialize() override final
Detect the OpenCL devices and prepare OpenCL context.
cl::Buffer m_insideOutOutputBuffer ATLAS_THREAD_SAFE
xrt::device m_xrt_accelerator
The class for enconding RDO to FPGA format.
std::atomic< cl_ulong > m_SE_kernelTime
Sum for the average time of the kernel execution.
Gaudi::Property< bool > m_runIO
Whether to run inside out or not.
cl::Buffer m_stripL2GOutputBuffer ATLAS_THREAD_SAFE
ToolHandle< TestVectorTool > m_testVectorTool
Tool for preparing test vectors.
cl::Buffer m_pixelClusterOutputBuffer ATLAS_THREAD_SAFE
cl::Event m_slicingEngineInputEndEvent ATLAS_THREAD_SAFE
std::atomic< ulonglong > m_numEvents
Number of events for the average time of the kernel execution.
cl::Buffer m_stripClusterInputBuffer ATLAS_THREAD_SAFE
Gaudi::Property< std::string > m_xclbin
Path and name of the xclbin file.
cl::Buffer m_stripClusterOutputBuffer ATLAS_THREAD_SAFE
Gaudi::Property< bool > m_runSE
Whether to run SE or not.
Gaudi::Property< std::string > m_pixelClusterKernelName
Name of the pixel clustering kernel.
virtual StatusCode finalize() override final
cl::Kernel m_pixelClusteringKernel ATLAS_THREAD_SAFE
Gaudi::Property< std::string > m_insideOutOutputName
cl::Buffer m_edmPixelOutputBuffer ATLAS_THREAD_SAFE
Gaudi::Property< std::string > m_stripL2GKernelName
Name of the strip L2G kernelS.
Gaudi::Property< std::string > m_stripEdmKernelName
Name of the FPGA kernel.
cl::Buffer m_edmStripOutputBuffer ATLAS_THREAD_SAFE
std::atomic< cl_ulong > m_IO_kernelTime
Time for kernel execution.
cl::Kernel m_pixelEdmPrepKernel ATLAS_THREAD_SAFE
cl::Buffer m_pixelClusterInputBuffer ATLAS_THREAD_SAFE
SG::ReadHandleKey< FPGATrackSimHitCollection > m_FPGASlicedHitKey
SG::ReadHandleKey< FPGATrackSimTrackCollection > m_FPGATrackKey
SG::ReadHandleKey< FPGATrackSimHitCollection > m_FPGAHitKey