From 82c8581965d0c6ef872b3217e88f57603bf20c78 Mon Sep 17 00:00:00 2001 From: Martin Date: Mon, 29 Aug 2022 18:00:42 +0200 Subject: [PATCH] fix assert --- L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc | 4 +--- L1Trigger/CSCTriggerPrimitives/src/CSCCathodeLCTProcessor.cc | 4 +--- L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc | 4 +--- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc index 9d02793416a61..9c22a47e1ad11 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCAnodeLCTProcessor.cc @@ -136,7 +136,6 @@ void CSCAnodeLCTProcessor::setConfigParameters(const CSCDBL1TPParameters* conf) } minbx_readout_ = CSCConstants::LCT_CENTRAL_BX - l1a_window_width / 2; maxbx_readout_ = CSCConstants::LCT_CENTRAL_BX + l1a_window_width / 2; - assert(minbx_readout_ > 0); } void CSCAnodeLCTProcessor::checkConfigParameters() { @@ -174,8 +173,7 @@ void CSCAnodeLCTProcessor::checkConfigParameters() { CSCBaseboard::checkConfigParameters(accel_mode, max_accel_mode, def_accel_mode, "accel_mode"); CSCBaseboard::checkConfigParameters(l1a_window_width, max_l1a_window_width, def_l1a_window_width, "l1a_window_width"); - minbx_readout_ = CSCConstants::LCT_CENTRAL_BX - l1a_window_width / 2; - maxbx_readout_ = CSCConstants::LCT_CENTRAL_BX + l1a_window_width / 2; + assert(l1a_window_width / 2 <= CSCConstants::LCT_CENTRAL_BX); } void CSCAnodeLCTProcessor::clear() { diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCCathodeLCTProcessor.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCCathodeLCTProcessor.cc index 6e2658a4e58c1..95a13e5a767bb 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCCathodeLCTProcessor.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCCathodeLCTProcessor.cc @@ -140,7 +140,6 @@ void CSCCathodeLCTProcessor::setConfigParameters(const CSCDBL1TPParameters* conf } minbx_readout_ = CSCConstants::LCT_CENTRAL_BX - tmb_l1a_window_size / 2; maxbx_readout_ = CSCConstants::LCT_CENTRAL_BX + tmb_l1a_window_size / 2; - assert(minbx_readout_ > 0); } void CSCCathodeLCTProcessor::setESLookupTables(const CSCL1TPLookupTableCCLUT* conf) { cclut_->setESLookupTables(conf); } @@ -173,8 +172,7 @@ void CSCCathodeLCTProcessor::checkConfigParameters() { CSCBaseboard::checkConfigParameters(min_separation, max_min_separation, def_min_separation, "min_separation"); CSCBaseboard::checkConfigParameters( tmb_l1a_window_size, max_tmb_l1a_window_size, def_tmb_l1a_window_size, "tmb_l1a_window_size"); - minbx_readout_ = CSCConstants::LCT_CENTRAL_BX - tmb_l1a_window_size / 2; - maxbx_readout_ = CSCConstants::LCT_CENTRAL_BX + tmb_l1a_window_size / 2; + assert(tmb_l1a_window_size / 2 <= CSCConstants::LCT_CENTRAL_BX); } void CSCCathodeLCTProcessor::clear() { diff --git a/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc b/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc index dab96a97c5c4d..5348036f90e26 100644 --- a/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc +++ b/L1Trigger/CSCTriggerPrimitives/src/CSCMotherboard.cc @@ -127,7 +127,6 @@ void CSCMotherboard::setConfigParameters(const CSCDBL1TPParameters* conf) { } minbx_readout_ = CSCConstants::LCT_CENTRAL_BX - tmb_l1a_window_size / 2; maxbx_readout_ = CSCConstants::LCT_CENTRAL_BX + tmb_l1a_window_size / 2; - assert(minbx_readout_ > 0); } void CSCMotherboard::setESLookupTables(const CSCL1TPLookupTableCCLUT* conf) { lookupTableCCLUT_ = conf; } @@ -572,8 +571,7 @@ void CSCMotherboard::checkConfigParameters() { match_trig_window_size, max_match_trig_window_size, def_match_trig_window_size, "match_trig_window_size"); CSCBaseboard::checkConfigParameters( tmb_l1a_window_size, max_tmb_l1a_window_size, def_tmb_l1a_window_size, "tmb_l1a_window_size"); - minbx_readout_ = CSCConstants::LCT_CENTRAL_BX - tmb_l1a_window_size / 2; - maxbx_readout_ = CSCConstants::LCT_CENTRAL_BX + tmb_l1a_window_size / 2; + assert(tmb_l1a_window_size / 2 <= CSCConstants::LCT_CENTRAL_BX); } void CSCMotherboard::dumpConfigParams() const {