Skip to content

Commit f816ad8

Browse files
committed
Please consider the following formatting changes
1 parent ce1131b commit f816ad8

File tree

2 files changed

+21
-14
lines changed

2 files changed

+21
-14
lines changed

GPU/GPUTracking/Merger/GPUTPCGMMerger.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2228,7 +2228,7 @@ GPUd() void GPUTPCGMMerger::ResolveHitWeights(int32_t nBlocks, int32_t nThreads,
22282228
if (candidates[0].best > 0) {
22292229
auto& outCl = mClusters[iOut + (reverse ? (written) : (nHits - 1 - written))];
22302230
const auto& best = candidates[candidates[0].best - 1];
2231-
const ClusterNative& GPUrestrict() cl = GetConstantMem()->ioPtrs.clustersNative->clustersLinear[best.id - 2];
2231+
const ClusterNative& GPUrestrict() cl = GetConstantMem() -> ioPtrs.clustersNative->clustersLinear[best.id - 2];
22322232
outCl = {.num = best.id - 2, .sector = best.sector, .row = (uint8_t)j, .state = (uint8_t)(cl.getFlags() & GPUTPCGMMergedTrackHit::clustererAndSharedFlags)};
22332233
written++;
22342234
CADEBUG(printf("REBUILD: iTrk %d Assigned Cluster Row %d Hit %d\n", i, j, best.id - 2));

GPU/GPUTracking/Merger/GPUTPCGMTrackParam.cxx

Lines changed: 20 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ GPUd() bool GPUTPCGMTrackParam::Fit(GPUTPCGMMerger* GPUrestrict() merger, int32_
263263

264264
if (dy * dy < sy2 && dz * dz < sz2) {
265265
float err2YA, err2ZA;
266-
const ClusterNative& GPUrestrict() cl = merger->GetConstantMem()->ioPtrs.clustersNative->clustersLinear[idOffset + ids[ih]];
266+
const ClusterNative& GPUrestrict() cl = merger -> GetConstantMem()->ioPtrs.clustersNative->clustersLinear[idOffset + ids[ih]];
267267
const auto clflags = cl.getFlags() & GPUTPCGMMergedTrackHit::clustererAndSharedFlags;
268268
const float time = cl.getTime();
269269
const float invSqrtCharge = CAMath::InvSqrt(cl.qMax);
@@ -297,15 +297,22 @@ GPUd() bool GPUTPCGMTrackParam::Fit(GPUTPCGMMerger* GPUrestrict() merger, int32_
297297
}
298298
}
299299
}
300-
CADEBUG(const auto* dbgCand = &merger->ClusterCandidates()[(iTrk * GPUCA_ROW_COUNT + cluster.row) * param.rec.tpc.rebuildTrackInFitClusterCandidates]; for (int dbgi = 0; dbgi < nCandidates; dbgi++) { if (dbgCand[dbgi].id > 1) printf("iTrk %d Row %d Hit %d Candidate %d hit %d err %f\n", iTrk, (int)cluster.row, cluster.num, dbgi, dbgCand[dbgi].id - 2, dbgCand[dbgi].error); else break; }});
301-
}
302-
if (nCandidates == 0) {
303-
merger->ClusterCandidates()[(iTrk * GPUCA_ROW_COUNT + cluster.row) * param.rec.tpc.rebuildTrackInFitClusterCandidates + 0].id = 1;
304-
}
300+
CADEBUG(const auto* dbgCand = &merger->ClusterCandidates()[(iTrk * GPUCA_ROW_COUNT + cluster.row) * param.rec.tpc.rebuildTrackInFitClusterCandidates]; for (int dbgi = 0; dbgi < nCandidates; dbgi++) {
301+
if (dbgCand[dbgi].id > 1)
302+
printf("iTrk %d Row %d Hit %d Candidate %d hit %d err %f\n", iTrk, (int)cluster.row, cluster.num, dbgi, dbgCand[dbgi].id - 2, dbgCand[dbgi].error);
303+
else
304+
break; }
305+
});
306+
}
307+
if (nCandidates == 0) {
308+
merger->ClusterCandidates()[(iTrk * GPUCA_ROW_COUNT + cluster.row) * param.rec.tpc.rebuildTrackInFitClusterCandidates + 0].id = 1;
305309
}
306-
} else if (allowChangeClusters) {
307-
uncorrectedY = AttachClusters(merger, cluster.sector, cluster.row, iTrk, track.Leg() == 0, prop);
308310
}
311+
}
312+
else if (allowChangeClusters)
313+
{
314+
uncorrectedY = AttachClusters(merger, cluster.sector, cluster.row, iTrk, track.Leg() == 0, prop);
315+
}
309316

310317
const bool sinPhiErr = mNDF > 0 && CAMath::Abs(prop.GetSinPhi0()) >= maxSinForUpdate;
311318
if (mNDF >= 0 && (mC[0] > param.rec.tpc.trackFitCovLimit || mC[2] > param.rec.tpc.trackFitCovLimit)) {
@@ -423,11 +430,11 @@ GPUd() bool GPUTPCGMTrackParam::Fit(GPUTPCGMMerger* GPUrestrict() merger, int32_
423430
} else {
424431
break; // bad chi2 for the whole track, stop the fit
425432
}
426-
}
427-
if (finalOutInFit && !(param.rec.tpc.disableRefitAttachment & 4) && lastRow != 255 && lastSector != 255) {
428-
StoreLoopPropagation(merger, lastSector, lastRow, iTrk, lastRow > clusters[(iWay & 1) ? (maxN - 1) : 0].row, prop.GetAlpha());
429-
CADEBUG(printf("\t\tSTORING %d lastRow %d row %d out %d\n", iTrk, (int)lastRow, (int)clusters[(iWay & 1) ? (maxN - 1) : 0].row, lastRow > clusters[(iWay & 1) ? (maxN - 1) : 0].row));
430-
}
433+
}
434+
if (finalOutInFit && !(param.rec.tpc.disableRefitAttachment & 4) && lastRow != 255 && lastSector != 255) {
435+
StoreLoopPropagation(merger, lastSector, lastRow, iTrk, lastRow > clusters[(iWay & 1) ? (maxN - 1) : 0].row, prop.GetAlpha());
436+
CADEBUG(printf("\t\tSTORING %d lastRow %d row %d out %d\n", iTrk, (int)lastRow, (int)clusters[(iWay & 1) ? (maxN - 1) : 0].row, lastRow > clusters[(iWay & 1) ? (maxN - 1) : 0].row));
437+
}
431438
if (!(iWay & 1) && !finalFit && !track.CCE() && !track.Looper()) {
432439
deltaZ = ShiftZ(clusters, merger, maxN);
433440
} else {

0 commit comments

Comments
 (0)