From 1fd7b765dc70023e9ad27f08405791187be5687b Mon Sep 17 00:00:00 2001 From: David Rohr Date: Wed, 11 Mar 2026 09:48:20 +0100 Subject: [PATCH] GPU Workflow: Avoid duplicated variable --- GPU/Workflow/src/GPUWorkflowITS.cxx | 11 ++++------- GPU/Workflow/src/GPUWorkflowSpec.cxx | 11 ++++------- 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/GPU/Workflow/src/GPUWorkflowITS.cxx b/GPU/Workflow/src/GPUWorkflowITS.cxx index 587b85df98952..46e1b1578285c 100644 --- a/GPU/Workflow/src/GPUWorkflowITS.cxx +++ b/GPU/Workflow/src/GPUWorkflowITS.cxx @@ -37,13 +37,10 @@ int32_t GPURecoWorkflowSpec::runITSTracking(o2::framework::ProcessingContext& pc LOGP(debug, "GPUChainITS is giving me device propagator: {}", (void*)mGPUReco->GetDeviceO2Propagator()); mITSTrackingInterface->run(pc); static bool first = true; - if (first) { - first = false; - if (pc.services().get().inputTimesliceId == 0) { - o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, o2::its::VertexerParamConfig::Instance().getName()), o2::its::VertexerParamConfig::Instance().getName()); - o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, o2::its::TrackerParamConfig::Instance().getName()), o2::its::TrackerParamConfig::Instance().getName()); - o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, o2::its::ITSGpuTrackingParamConfig::Instance().getName()), o2::its::ITSGpuTrackingParamConfig::Instance().getName()); - } + if (mNTFs == 1 && pc.services().get().inputTimesliceId == 0) { + o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, o2::its::VertexerParamConfig::Instance().getName()), o2::its::VertexerParamConfig::Instance().getName()); + o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, o2::its::TrackerParamConfig::Instance().getName()), o2::its::TrackerParamConfig::Instance().getName()); + o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, o2::its::ITSGpuTrackingParamConfig::Instance().getName()), o2::its::ITSGpuTrackingParamConfig::Instance().getName()); } return 0; } diff --git a/GPU/Workflow/src/GPUWorkflowSpec.cxx b/GPU/Workflow/src/GPUWorkflowSpec.cxx index f7fc760b99125..dbb554a14cea4 100644 --- a/GPU/Workflow/src/GPUWorkflowSpec.cxx +++ b/GPU/Workflow/src/GPUWorkflowSpec.cxx @@ -517,13 +517,6 @@ int32_t GPURecoWorkflowSpec::runMain(o2::framework::ProcessingContext* pc, GPUTr if (retVal == 0 && mSpecConfig.runITSTracking) { retVal = runITSTracking(*pc); } - static bool first = true; - if (first) { - first = false; - if (pc && pc->services().get().inputTimesliceId == 0) { // TPC ConfigurableCarams are somewhat special, need to construct by hand - o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc->services().get().name, "rec_tpc"), "GPU_rec_tpc,GPU_rec,GPU_proc_param,GPU_proc,GPU_global,trackTuneParams"); - } - } } if (!mSpecConfig.enableDoublePipeline) { // TODO: Why is this needed for double-pipeline? @@ -819,6 +812,10 @@ void GPURecoWorkflowSpec::run(ProcessingContext& pc) mNTFDumps++; } } + if (mNTFs == 1 && pc.services().get().inputTimesliceId == 0) { // TPC ConfigurableCarams are somewhat special, need to construct by hand + o2::conf::ConfigurableParam::write(o2::base::NameConf::getConfigOutputFileName(pc.services().get().name, "rec_tpc"), "GPU_rec_tpc,GPU_rec,GPU_proc_param,GPU_proc,GPU_global,trackTuneParams"); + } + std::unique_ptr ptrsDump; if (mConfParam->dumpBadTFMode == 2) { ptrsDump.reset(new GPUTrackingInOutPointers);