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
thread safety statics work #1283
thread safety statics work #1283
Conversation
Various arrays of constants set and then assigned to other arrays of constants. Make the static arrays const for thread safety. Make the arrays these are copied to const.
@Dr15Jones can you take a look. |
A new Pull Request was created by @gartung (Patrick Gartung) for CMSSW_7_0_X. thread safety statics work It involves the following packages: L1Trigger/CSCTrackFinder @nclopezo, @mulhearn can you please review it and eventually sign? Thanks. |
It appears that the arrays were just changed to const. If so, that is definitely thread safe. |
In the main body of the code, I had to change double to const double in the initialization statements. I also had to change the variables the array were copied/assigned to from double to const double. |
Maybe I'm sleep deprived, but shouldn't this simply remove the variables? Who sets those variables? |
The static arrays are copied to other arrays multiple times. Not sure why they wanted static as the savings in memory can't be that much. |
Nevermind. It's indeed sleep deprivation… I did not notice the arrays were initialised in the CC... |
Multithreading fixes -- Make statics const in L1Trigger/CSCTrackFinder
Various arrays of constants set and then assigned to other arrays of constants.
Make the static arrays const for thread safety.
Make the arrays these are copied to const.