Skip to content
Snippets Groups Projects
Commit 1cb65b75 authored by Felix Weiglhofer's avatar Felix Weiglhofer
Browse files

algo: Add common device image for all GPU code.

parent 9862baf4
No related branches found
No related tags found
1 merge request!1151algo: Add common device image for all GPU code.
Pipeline #22174 passed
......@@ -2,6 +2,7 @@ add_subdirectory(data)
add_subdirectory(test)
set(DEVICE_SRCS
base/gpu/DeviceImage.cxx
detectors/sts/UnpackStsXpu.cxx
)
......@@ -28,6 +29,7 @@ add_library(Algo SHARED ${SRCS})
target_include_directories(Algo
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/base
${CMAKE_CURRENT_SOURCE_DIR}/evbuild
${CMAKE_CURRENT_SOURCE_DIR}/trigger
${CMAKE_CURRENT_SOURCE_DIR}/evselector
......@@ -43,6 +45,9 @@ target_compile_definitions(Algo PUBLIC NO_ROOT)
xpu_attach(Algo ${DEVICE_SRCS})
install(TARGETS Algo DESTINATION lib)
install(DIRECTORY base/gpu TYPE INCLUDE
FILES_MATCHING PATTERN "*.h"
)
install(FILES ca/simd/CaSimd.h
ca/simd/CaSimdVc.h
......
/* Copyright (C) 2023 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer] */
#include "DeviceImage.h"
XPU_IMAGE(cbm::algo::GPUReco);
/* Copyright (C) 2023 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer] */
#ifndef CBM_ALGO_BASE_GPU_DEVICEIMAGE_H
#define CBM_ALGO_BASE_GPU_DEVICEIMAGE_H
#include <xpu/device.h>
namespace cbm::algo
{
struct GPUReco {
};
} // namespace cbm::algo
#endif
......@@ -15,8 +15,6 @@
using std::unique_ptr;
using std::vector;
XPU_IMAGE(cbm::algo::UnpackStsXpu::StsXpuUnpack); // Call exactly once per library
XPU_BLOCK_SIZE_1D(cbm::algo::UnpackStsXpu::Unpack, 32);
namespace cbm::algo
......
......@@ -5,7 +5,6 @@
#ifndef CBM_ALGO_UNPACKSTSXPU_H
#define CBM_ALGO_UNPACKSTSXPU_H 1
#include "CbmStsDigi.h"
#include "MicrosliceDescriptor.hpp"
......@@ -22,6 +21,7 @@
#include "StsReadoutConfig.h"
#include "StsXyterMessage.h"
#include "gpu/DeviceImage.h"
namespace cbm::algo
......@@ -107,7 +107,7 @@ namespace cbm::algo
// Run unpacker for each microslice
XPU_EXPORT_KERNEL(StsXpuUnpack, Unpack, UnpackStsXpuPar* params, UnpackStsXpuElinkPar* elinkParams,
XPU_EXPORT_KERNEL(GPUReco, Unpack, UnpackStsXpuPar* params, UnpackStsXpuElinkPar* elinkParams,
stsxyter::Message* content, uint64_t* msMessCount, uint64_t* msMessOffset, uint64_t* msStartTime,
uint32_t* msCompIdx, CbmStsDigi* digisOut, const uint64_t currentTsTime, int NElems);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment