Skip to content

Commit

Permalink
Fix static warnings detected during cms-sw#43390
Browse files Browse the repository at this point in the history
  • Loading branch information
jfernan2 authored and Zhenbin Wu committed Feb 14, 2024
1 parent 428179a commit 9df2e81
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions L1Trigger/DTTriggerPhase2/src/GlobalCoordsObtainer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -224,12 +224,6 @@ std::vector<double> GlobalCoordsObtainer::get_global_coordinates(uint32_t chid,
int tanpsi_msb = tanpsi >> (TANPSI_SIZE - PHIB_LUT_ADDR_WIDTH);
tanpsi_msb = from_two_comp(tanpsi_msb, PHIB_LUT_ADDR_WIDTH);

x_msb = x >> (X_SIZE - PHI_LUT_ADDR_WIDTH);
x_msb = from_two_comp(x_msb, PHI_LUT_ADDR_WIDTH);

tanpsi_msb = tanpsi >> (TANPSI_SIZE - PHIB_LUT_ADDR_WIDTH);
tanpsi_msb = from_two_comp(tanpsi_msb, PHIB_LUT_ADDR_WIDTH);

// The LSB part can be sliced right away because it must yield a positive integer
int x_lsb = x & (int)(std::pow(2, (X_SIZE - PHI_LUT_ADDR_WIDTH)) - 1);
int tanpsi_lsb = tanpsi & (int)(std::pow(2, (TANPSI_SIZE - PHIB_LUT_ADDR_WIDTH)) - 1);
Expand Down Expand Up @@ -261,4 +255,4 @@ std::vector<double> GlobalCoordsObtainer::get_global_coordinates(uint32_t chid,
double phib_f = (double)phib / pow(2, PHIB_SIZE);

return std::vector({phi_f, phib_f});
}
}

0 comments on commit 9df2e81

Please sign in to comment.