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

Remove constexpr from ringOrder #11848

Merged
merged 1 commit into from
Oct 19, 2015

Conversation

davidlt
Copy link
Contributor

@davidlt davidlt commented Oct 16, 2015

ICC segfaults due to to constexpr on ringOrder. This is reported and
due to be fixed in forthcoming ICC releases (2016).

Removal of constexpr did not change assembly in any significant,
actually compiler generated 5 instructions less for this function.

Signed-off-by: David Abdurachmanov David.Abdurachmanov@cern.ch

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @davidlt for CMSSW_7_6_X.

Remove constexpr from ringOrder

It involves the following packages:

RecoTracker/TkDetLayers

@cmsbuild, @cvuosalo, @slava77 can you please review it and eventually sign? Thanks.
@ghellwig, @makortel, @GiacomoSguazzoni, @rovere, @VinInn, @mschrode, @istaslis, @gpetruc, @cerati, @dgulhan 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.
If you are a L2 or a release manager you can ask for tests by saying 'please test' in the first line of a comment.
@Degano you are the release manager for this.
You can merge this pull request by typing 'merge' in the first line of your comment.

@@ -128,7 +128,7 @@ Phase2OTECRingedLayer::groupedCompatibleDetsV( const TrajectoryStateOnSurface& s
}

//order is odd rings in front of even rings
constexpr int ringOrder[NOTECRINGS]{0,1,0,1,0,1,0,1,0,1,0,1,0,1,0};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we keep "const" here?
This is logically what it was before the change proposed here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I don't know how that got away from me.

@VinInn
Copy link
Contributor

VinInn commented Oct 16, 2015

Can we stop modifying production code to support development platform used only for R&D?
We need a policy here. I strongly oppose to change any code with the only purpose to support R&D on HW/Software that has close to negligible chance to become a production platform in the medium future.

@davidlt
Copy link
Contributor Author

davidlt commented Oct 16, 2015

@VinInn I am happy to add ifdef here if required. It's L2 decision. But technically there seems to be no gain in constexpr here.

@davidlt davidlt force-pushed the constexpr-ringOrder-reco-icc branch from fbc685a to 4de09f0 Compare October 16, 2015 10:56
@cmsbuild
Copy link
Contributor

Pull request #11848 was updated. @cmsbuild, @cvuosalo, @slava77 can you please check and sign again.

@davidlange6
Copy link
Contributor

if I understand correctly that we are patching around an ICC bug (which indeed is not likely a production cms platform..) - an ifdef sounds like the best approach.

@davidlt davidlt force-pushed the constexpr-ringOrder-reco-icc branch from 4de09f0 to 5e567c0 Compare October 16, 2015 13:09
ICC segfaults due to to `constexpr` on `ringOrder`. This is reported and
due to be fixed in forthcoming ICC releases (2016).

Removal of `constexpr` did not change assembly in any significant,
actually compiler generated 5 instructions less for this function.

Signed-off-by: David Abdurachmanov <David.Abdurachmanov@cern.ch>
@davidlt davidlt force-pushed the constexpr-ringOrder-reco-icc branch from 5e567c0 to 9d76170 Compare October 16, 2015 13:10
@cmsbuild
Copy link
Contributor

Pull request #11848 was updated. @cmsbuild, @cvuosalo, @slava77 can you please check and sign again.

@davidlt
Copy link
Contributor Author

davidlt commented Oct 16, 2015

I added ifdefs, but again constexpr aren't giving any benefits here.

@slava77
Copy link
Contributor

slava77 commented Oct 16, 2015

@cmsbuild please test

@cmsbuild
Copy link
Contributor

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-any-integration/8958/console

@cmsbuild
Copy link
Contributor

@cmsbuild
Copy link
Contributor

@cvuosalo
Copy link
Contributor

+1

For #11848 9d76170

Adding #ifdef for a special R&D compiler that has a bug with constexpr to allow it to compile CMSSW. This compiler bug might get fixed in 2016.

There should be no change in run-time behavior.

The code changes are satisfactory, and standard compilation is successful. Jenkins tests against baseline CMSSW_7_6_X_2015-10-16-1100 show no significant differences, as expected.

@cvuosalo
Copy link
Contributor

@davidlt:
It would be nice if you could remove these #ifdefs next year when you get a new version of ICC without the bug.

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next CMSSW_7_6_X IBs (tests are also fine). This pull request requires discussion in the ORP meeting before it's merged. @davidlange6, @Degano, @smuzaffar

@davidlange6
Copy link
Contributor

+1

cmsbuild added a commit that referenced this pull request Oct 19, 2015
@cmsbuild cmsbuild merged commit 96377c8 into cms-sw:CMSSW_7_6_X Oct 19, 2015
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.

6 participants