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

Changed statics to thread_local in EgammaTowerIsolation #3550

Conversation

Dr15Jones
Copy link
Contributor

To quickly fix the thread safety problems, the static data members
of EgammaTowerIsolation have been changed to be thread_local.
This avoids disturbing the present behavior and client APIs while
fixing the threading problems crashing jobs.
However, this should not be considered the permanent solution. Instead
the statics should become regular members and client code should
stop making temporary EgammaTowerIsolation objects and instead
keep reusing the one they make.

To quickly fix the thread safety problems, the static data members
of EgammaTowerIsolation have been changed to be thread_local.
This avoids disturbing the present behavior and client APIs while
fixing the threading problems crashing jobs.
However, this should not be considered the permanent solution. Instead
the statics should become regular members and client code should
stop making temporary EgammaTowerIsolation objects and instead
keep reusing the one they make.
@Dr15Jones
Copy link
Contributor Author

NOTE: This problem was missed by the static analyzer since the static analyzer crashed while trying to processes EgammaTowerIsolation.cc.

@Dr15Jones
Copy link
Contributor Author

@davidlange6 This was missed by helgrind in my original run :(. So a clean helgrind does not mean thread safe.

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @Dr15Jones (Chris Jones) for CMSSW_7_1_X.

Changed statics to thread_local in EgammaTowerIsolation

It involves the following packages:

RecoEgamma/EgammaIsolationAlgos

@nclopezo, @cmsbuild, @anton-a, @thspeer, @slava77, @Degano can you please review it and eventually sign? Thanks.
@lgray this is something you requested to watch as well.
You can sign-off by replying to this message having '+1' in the first line of your reply.
You can reject by replying to this message having '-1' in the first line of your reply.
@nclopezo, @ktf you are the release manager for this.
You can merge this pull request by typing 'merge' in the first line of your comment.

@Dr15Jones
Copy link
Contributor Author

@nclopezo was the test for this started?

@anton-a
Copy link

anton-a commented Apr 29, 2014

looks like the comparison job is stuck
@nclopezo can you please restrart

@slava77
Copy link
Contributor

slava77 commented Apr 30, 2014

+1

for #3550 64fb651

tested in CMSSW_7_1_X_2014-04-29-0200
( test area sign361 pulls 3475 3529 3531 3550 3555 together)
no regressions .
Still had to merge manually from Chris' branch

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next CMSSW_7_1_X IBs unless changes (tests are also fine). @nclopezo, @ktf can you please take care of it?

ktf added a commit that referenced this pull request Apr 30, 2014
…ationToThreadLocal

Multithreading -- Changed statics to thread_local in EgammaTowerIsolation
@ktf ktf merged commit 1cd6338 into cms-sw:CMSSW_7_1_X Apr 30, 2014
@Dr15Jones Dr15Jones deleted the changeStaticInEgammaTowerIsolationToThreadLocal branch May 6, 2014 17:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants