Skip to content
Snippets Groups Projects
Commit 6b480570 authored by Christos Anastopoulos's avatar Christos Anastopoulos
Browse files

Add ATLAS_CHECK_THREAD_SAFETY to TrkParametersIdentificationHelpers,TrkRIO_OnTrack,TrkTrackLink

parent 971046f5
No related branches found
No related tags found
No related merge requests found
Showing
with 22 additions and 17 deletions
Tracking/TrkEvent/TrkParametersIdentificationHelpers
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
*/
#ifndef TRK_TRACKPARAMETERSIDHELPER_H
......@@ -45,13 +45,13 @@ namespace Trk {
/** set version bits */
void setVersion( TrackParametersIdentifier& id ) const;
static unsigned int m_version;
static BitField<unsigned int> m_validField;
static BitField<unsigned int> m_versionField;
static BitField<unsigned int> m_technologyField;
static const unsigned int m_version;
static const BitField<unsigned int> m_validField;
static const BitField<unsigned int> m_versionField;
static const BitField<unsigned int> m_technologyField;
static BitField<unsigned int> m_isEntryToLayerField;
static BitField<unsigned int> m_caloSamplingField;
static const BitField<unsigned int> m_isEntryToLayerField;
static const BitField<unsigned int> m_caloSamplingField;
};
......
......@@ -24,7 +24,7 @@ namespace Trk {
private:
static TrackParametersIdHelper m_helper;
static const TrackParametersIdHelper m_helper;
};
inline TrackParametersIdentifier TrackParametersIdentificationHelper::getIdentifier( const CurvilinearParameters& pars ) {
......
......@@ -6,14 +6,14 @@
namespace Trk {
unsigned int TrackParametersIdHelper::m_version = 0;
BitField<unsigned int> TrackParametersIdHelper::m_validField( 31, 1 );
const unsigned int TrackParametersIdHelper::m_version = 0;
const BitField<unsigned int> TrackParametersIdHelper::m_validField( 31, 1 );
BitField<unsigned int> TrackParametersIdHelper::m_versionField( 28, 3 );
BitField<unsigned int> TrackParametersIdHelper::m_technologyField( 23, 5 );
const BitField<unsigned int> TrackParametersIdHelper::m_versionField( 28, 3 );
const BitField<unsigned int> TrackParametersIdHelper::m_technologyField( 23, 5 );
BitField<unsigned int> TrackParametersIdHelper::m_isEntryToLayerField( 5, 2 );
BitField<unsigned int> TrackParametersIdHelper::m_caloSamplingField( 0, 5 );
const BitField<unsigned int> TrackParametersIdHelper::m_isEntryToLayerField( 5, 2 );
const BitField<unsigned int> TrackParametersIdHelper::m_caloSamplingField( 0, 5 );
}
......@@ -6,7 +6,7 @@
namespace Trk {
TrackParametersIdHelper TrackParametersIdentificationHelper::m_helper;
const TrackParametersIdHelper TrackParametersIdentificationHelper::m_helper;
TrackParametersIdentifier TrackParametersIdentificationHelper::getIdentifier( const Trk::TrackParameters& pars ) {
const CurvilinearParameters* cpars = dynamic_cast<const CurvilinearParameters*>(&pars);
......
Tracking/TrkEvent/TrkRIO_OnTrack
......@@ -19,6 +19,8 @@
#include "Identifier/Identifier.h"
#include "Identifier/IdentifierHash.h"
#include <ostream>
#include <atomic>
class MsgStream;
class RIO_OnTrackCnv_p1;
class RIO_OnTrackCnv_p2;
......@@ -125,7 +127,7 @@ namespace Trk {
Identifier m_identifier;
/** number of objects of this type in memory */
static unsigned int s_numberOfInstantiations;
static std::atomic<unsigned int> s_numberOfInstantiations;
};
inline Identifier RIO_OnTrack::identify() const
......
......@@ -17,7 +17,7 @@
#include <string>
#include <typeinfo>
unsigned int Trk::RIO_OnTrack::s_numberOfInstantiations=0;
std::atomic<unsigned int> Trk::RIO_OnTrack::s_numberOfInstantiations{0};
// Constructor with parameters:
Trk::RIO_OnTrack::RIO_OnTrack( const Trk::LocalParameters& locpars,
......
Tracking/TrkEvent/TrkTrackLink
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