Skip to content

Commit

Permalink
Merge pull request #11848 from davidlt/constexpr-ringOrder-reco-icc
Browse files Browse the repository at this point in the history
Remove constexpr from ringOrder
  • Loading branch information
cmsbuild committed Oct 19, 2015
2 parents 98490b4 + 9d76170 commit 96377c8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions RecoTracker/TkDetLayers/src/Phase2OTECRingedLayer.cc
Expand Up @@ -128,7 +128,11 @@ Phase2OTECRingedLayer::groupedCompatibleDetsV( const TrajectoryStateOnSurface& s
}

//order is odd rings in front of even rings
#ifdef __INTEL_COMPILER
const int ringOrder[NOTECRINGS]{0,1,0,1,0,1,0,1,0,1,0,1,0,1,0};
#else
constexpr int ringOrder[NOTECRINGS]{0,1,0,1,0,1,0,1,0,1,0,1,0,1,0};
#endif
auto index = [&ringIndices,& ringOrder](int i) { return ringOrder[ringIndices[i]];};

std::vector<DetGroup> closestResult;
Expand Down
4 changes: 4 additions & 0 deletions RecoTracker/TkDetLayers/src/TIDLayer.cc
Expand Up @@ -203,7 +203,11 @@ TIDLayer::groupedCompatibleDetsV( const TrajectoryStateOnSurface& startingState,
std::array<vector<DetGroup>,3> groupsAtRingLevel;
//order is ring3,ring1,ring2 i.e. 2 0 1
// 0 1 2
#ifdef __INTEL_COMPILER
const int ringOrder[3]{1,2,0};
#else
constexpr int ringOrder[3]{1,2,0};
#endif
auto index = [&ringIndices,& ringOrder](int i) { return ringOrder[ringIndices[i]];};

auto & closestResult = groupsAtRingLevel[index(0)];
Expand Down

0 comments on commit 96377c8

Please sign in to comment.