Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
08bd91f
GPU: Clear some TODOs
davidrohr Dec 1, 2026
2ca56e1
GPU: Fix a data type, missing initialization, dangling reference
davidrohr Dec 1, 2026
d63672f
GPU: Fix some debug / info messages
davidrohr Dec 1, 2026
19d9ff1
GPU: Fix dead code / wrong pragma
davidrohr Dec 1, 2026
c7bdfed
GPU: Use stdspinlock instead of broken manual implementation
davidrohr Dec 1, 2026
a88b9bc
GPU OpenCL: Find best device over all platforms
davidrohr Dec 1, 2026
8a469d6
GPU: Use std::move where possible
davidrohr Dec 1, 2026
3596bb9
GPU: Switch several function arguments to const ref
davidrohr Dec 1, 2026
bc1b28d
GPU: Modernize C++: Use std::format instead of snprintf, to_string, s…
davidrohr Dec 1, 2026
410a276
GPU: Fix mc data dump going to wrong directory
davidrohr Dec 1, 2026
fb146b1
GPU: Fix debug printout of shared memory for CUDA/HIP
davidrohr Dec 1, 2026
cdf64e4
GPU: Fix debug printout of matrices in MatrixSolver
davidrohr Dec 1, 2026
dd263ec
GPU: Modernize C++: Use RAII to close files
davidrohr Dec 1, 2026
e02fedb
GPU: Modernize C++: Improve initialization of some members
davidrohr Dec 1, 2026
9df08e3
GPU: Modernize C++: Use make_unique_for_overwrite where possible
davidrohr Dec 1, 2026
2c813be
GPU: Modernize C++: Use unique_ptr instead of C pointers
davidrohr Dec 1, 2026
5f8c3d8
ITS: Fix double delete
davidrohr Dec 1, 2026
29c49c6
GPU: Modernize C++: Replace template specialization with if constexpr
davidrohr Dec 1, 2026
02a925d
GPU OpenCL: Modernize C++: Simplify code a bit using more elaborate h…
davidrohr Dec 1, 2026
6065706
TPCFastTransform: Fix typo
davidrohr Dec 1, 2026
ea70cfe
GPU Benchmark: Fix invalid string comparisons based on const char* co…
davidrohr Dec 1, 2026
5d06dae
GPU: Fix asserts that never triggered
davidrohr Dec 1, 2026
d871815
GPU TPC: Fix debug code using MC in track merger
davidrohr Dec 1, 2026
56a84ee
GPU OpenCL: Fix 8 / 16 bit work group operations
davidrohr Dec 1, 2026
a9c24c5
GPU Refit: Add option to refit O2 tracks instead of GPU tracks
davidrohr Dec 1, 2026
af6bce7
GPU: Add debugDump option for refitted tracks
davidrohr Dec 1, 2026
db7234e
GPU: Add sanity check to run refit: Tracks must be present
davidrohr Dec 1, 2026
3f9c403
GPU: Fix typo
davidrohr Dec 1, 2026
1ecda2e
GPU: Modernize C++: Simplify code and reduce lines of code
davidrohr Dec 1, 2026
d8241cb
GPU: Modernize C++: Simplify code / remove dead code
davidrohr Dec 1, 2026
f7bd995
GPU: Modernize C++: Use requires instead of std::enable_if
davidrohr Dec 1, 2026
492a1e3
GPU: Code cleanup: use named structs instead of array / tuples
davidrohr Dec 1, 2026
be2942c
GPU: Modernize C++: Use fold expressions / parameter expansion instea…
davidrohr Dec 1, 2026
b3a19b4
GPU: Modernize C++: Use tuple comparators in sort
davidrohr Dec 1, 2026
4703ecd
GPU: Modernize C++: Use std::clamp / popcount / bit_width
davidrohr Dec 1, 2026
53d2c8a
GPU: More C++ modernization
davidrohr Dec 1, 2026
196bfc2
GPU: Modernize C++: Use range-based for loop in many places
davidrohr Dec 1, 2026
2d79b0d
GPU Standalone: Add script for benchmarking
davidrohr Dec 1, 2026
af5f991
GPU: Fix typo
davidrohr Dec 1, 2026
ab8bbdc
GPU: Modernize C++: Use some range-based algorithms
davidrohr Dec 1, 2026
14f9a9d
GPU: Modernize C++: Merge 2 functions in Clusterizer Code
davidrohr Dec 1, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class TrackerDPL : public framework::Task
void updateTimeDependentParams(framework::ProcessingContext& pc);
void storeConfigs(framework::ProcessingContext& pc);
std::unique_ptr<o2::gpu::GPUReconstruction> mRecChain = nullptr;
std::unique_ptr<o2::gpu::GPUChainITS> mChainITS = nullptr;
o2::gpu::GPUChainITS* mChainITS = nullptr; // Owned by mRecChain
std::shared_ptr<o2::base::GRPGeomRequest> mGGCCDBRequest;
ITSTrackingInterface mITSTrackingInterface;
TStopwatch mTimer;
Expand Down
2 changes: 1 addition & 1 deletion Detectors/ITSMFT/ITS/workflow/src/TrackerSpec.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ void TrackerDPL::init(InitContext& ic)
mTimer.Stop();
mTimer.Reset();
o2::base::GRPGeomHelper::instance().setRequest(mGGCCDBRequest);
mChainITS.reset(mRecChain->AddChain<o2::gpu::GPUChainITS>());
mChainITS = mRecChain->AddChain<o2::gpu::GPUChainITS>();
mITSTrackingInterface.setTraitsFromProvider(mChainITS->GetITSVertexerTraits(),
mChainITS->GetITSTrackerTraits(),
mChainITS->GetITSTimeframe());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class TrackerDPL : public framework::Task
private:
void updateTimeDependentParams(framework::ProcessingContext& pc);
std::unique_ptr<o2::gpu::GPUReconstruction> mRecChain = nullptr;
std::unique_ptr<o2::gpu::GPUChainITS> mChainITS = nullptr;
o2::gpu::GPUChainITS* mChainITS = nullptr; // Owned by mRecChain
std::shared_ptr<o2::base::GRPGeomRequest> mGGCCDBRequest;
ITS3TrackingInterface mITS3TrackingInterface;
TStopwatch mTimer;
Expand Down
2 changes: 1 addition & 1 deletion Detectors/Upgrades/ITS3/workflow/src/TrackerSpec.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ void TrackerDPL::init(InitContext& ic)
mTimer.Stop();
mTimer.Reset();
o2::base::GRPGeomHelper::instance().setRequest(mGGCCDBRequest);
mChainITS.reset(mRecChain->AddChain<o2::gpu::GPUChainITS>());
mChainITS = mRecChain->AddChain<o2::gpu::GPUChainITS>();
mITS3TrackingInterface.setTraitsFromProvider(mChainITS->GetITSVertexerTraits(),
mChainITS->GetITSTrackerTraits(),
mChainITS->GetITSTimeframe());
Expand Down
16 changes: 3 additions & 13 deletions GPU/Common/GPUCommonAlgorithm.h
Original file line number Diff line number Diff line change
Expand Up @@ -357,24 +357,14 @@ GPUhdi() I GPUCommonAlgorithm::partitionPoint(I first, I count, const P& pred)
#pragma OPENCL EXTENSION cl_khr_subgroups : enable

template <class T>
GPUdi() T warp_scan_inclusive_add_FUNC(T v)
GPUdi() auto warp_scan_inclusive_add_FUNC(T v) -> decltype(+v) // OpenCL has no 8 / 16 bit subgroup operations: widen, and return the sum promoted (callers pass !!pred, a bool would truncate it)
{
return sub_group_scan_inclusive_add(v);
}
template <> // FIXME: It seems OpenCL does not support 8 and 16 bit subgroup operations
GPUdi() uint8_t warp_scan_inclusive_add_FUNC<uint8_t>(uint8_t v)
{
return sub_group_scan_inclusive_add((uint32_t)v);
return sub_group_scan_inclusive_add(+v);
}
template <class T>
GPUdi() T warp_broadcast_FUNC(T v, int32_t i)
{
return sub_group_broadcast(v, i);
}
template <>
GPUdi() uint8_t warp_broadcast_FUNC<uint8_t>(uint8_t v, int32_t i)
{
return sub_group_broadcast((uint32_t)v, i);
return (T)sub_group_broadcast(+v, i);
}

#define warp_scan_inclusive_add(v) warp_scan_inclusive_add_FUNC(v)
Expand Down
22 changes: 10 additions & 12 deletions GPU/GPUTracking/Base/GPUConstantMem.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,20 +60,18 @@ struct GPUConstantMem {
GPUTPCNNClusterizer tpcNNClusterer[GPUTPCGeometry::NSECTORS];
#endif
template <int32_t I>
GPUd() auto& getTRDTracker();
GPUdi() auto& getTRDTracker()
{
if constexpr (I == 0) {
return trdTrackerGPU;
} else if constexpr (I == 1) {
return trdTrackerO2;
} else {
static_assert(I == 0 || I == 1, "Invalid TRD tracker version");
}
}
};

template <>
GPUdi() auto& GPUConstantMem::getTRDTracker<0>()
{
return trdTrackerGPU;
}
template <>
GPUdi() auto& GPUConstantMem::getTRDTracker<1>()
{
return trdTrackerO2;
}

union GPUConstantMemCopyable {
#if !defined(__OPENCL__) || defined(__OPENCL_HOST__)
GPUh() GPUConstantMemCopyable() {} // NOLINT: We want an empty constructor, not a default one
Expand Down
14 changes: 6 additions & 8 deletions GPU/GPUTracking/Base/GPUMemoryResource.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,7 @@ class GPUMemoryResource
ALLOCATION_INDIVIDUAL = 1, // Individual memory allocations with malloc (host only)
ALLOCATION_GLOBAL = 2 }; // Allocate memory blocks from large preallocated memory range with internal allocator (host and GPU)

GPUMemoryResource(GPUProcessor* proc, void* (GPUProcessor::*setPtr)(void*), MemoryType type, const char* name = "") : mProcessor(proc), mPtr(nullptr), mPtrDevice(nullptr), mSetPointers(setPtr), mName(name), mSize(0), mOverrideSize(0), mReuse(-1), mType(type)
{
}
GPUMemoryResource(GPUProcessor* proc, void* (GPUProcessor::*setPtr)(void*), MemoryType type, const char* name = "") : mProcessor(proc), mSetPointers(setPtr), mName(name), mType(type) {}
GPUMemoryResource(const GPUMemoryResource&) = default;

void* SetPointers(void* ptr) const;
Expand All @@ -94,13 +92,13 @@ class GPUMemoryResource

private:
GPUProcessor* mProcessor;
void* mPtr;
void* mPtrDevice;
void* mPtr = nullptr;
void* mPtrDevice = nullptr;
void* (GPUProcessor::*mSetPointers)(void*);
const char* mName;
size_t mSize;
size_t mOverrideSize;
int32_t mReuse;
size_t mSize = 0;
size_t mOverrideSize = 0;
int32_t mReuse = -1;
MemoryType mType;
};
} // namespace o2::gpu
Expand Down
Loading
Loading