Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Declare members of InputTag as thread safe #9180

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions FWCore/Utilities/interface/InputTag.h
Expand Up @@ -11,6 +11,7 @@
#include "FWCore/Utilities/interface/TypeID.h"
#include "FWCore/Utilities/interface/BranchType.h"
#include "FWCore/Utilities/interface/ProductHolderIndex.h"
#include "FWCore/Utilities/interface/thread_safety_macros.h"

namespace edm {

Expand Down Expand Up @@ -63,16 +64,16 @@ namespace edm {
std::string instance_;
std::string process_;

mutable TypeID typeID_;
mutable void const* productRegistry_;
CMS_THREAD_GUARD(index_) mutable TypeID typeID_;
CMS_THREAD_GUARD(index_) mutable void const* productRegistry_;

#ifndef __GCCXML__
mutable std::atomic<unsigned int> index_;
#else
unsigned int index_;
#endif

mutable char branchType_;
CMS_THREAD_GUARD(index_) mutable char branchType_;

bool skipCurrentProcess_;
};
Expand Down