message: Move some calculations to common code in SelectCoinsMinConf
  To prepare for KnapsackSolver to use effective values, these
  calculations are moved out of the BnB if block to allow for them to be
  shared with KnapsackSolver in the future.
diff: @@ -2446,7 +2446,9 @@ bool CWallet::SelectCoinsMinConf(const CAmount& nTargetValue, const CoinEligibil
  setCoinsRet.clear();
  nValueRet = 0;
  - if (coin_selection_params.use_bnb) {
  + // Calculate the fees for things that aren't inputs, excluding the change output
  + CAmount not_input_fees = GetMinFee(coin_selection_params.tx_noinputs_size, GetAdjustedTime());
  +
  // Get the feerate for effective value.
  // When subtracting the fee from the outputs, we want the effective feerate to be 0
  CFeeRate effective_feerate{0};
  @@ -2454,16 +2456,15 @@ bool CWallet::SelectCoinsMinConf(const CAmount& nTargetValue, const CoinEligibil
  effective_feerate = coin_selection_params.m_effective_feerate;
  }
  - std::vector<OutputGroup> groups = GroupOutputs(coins, !coin_selection_params.m_avoid_partial_spends, effective_feerate, coin_selection_params.m_long_term_feerate, eligibility_filter, true /* positive_only */);
  -
  - // Calculate cost of change
  CAmount cost_of_change = GetMinFee(coin_selection_params.change_spend_size, GetAdjustedTime()) + GetMinFee(coin_selection_params.change_output_size, GetAdjustedTime());
  - // Calculate the fees for things that aren't inputs
  - CAmount not_input_fees = GetMinFee(coin_selection_params.tx_noinputs_size, GetAdjustedTime());
  + if (coin_selection_params.use_bnb) {
  + std::vector<OutputGroup> positive_groups = GroupOutputs(coins, !coin_selection_params.m_avoid_partial_spends, effective_feerate, coin_selection_params.m_long_term_feerate, eligibility_filter, true /* positive_only */);
  bnb_used = true;
  - return SelectCoinsBnB(groups, nTargetValue, cost_of_change, setCoinsRet, nValueRet, not_input_fees);
  + return SelectCoinsBnB(positive_groups, nTargetValue, cost_of_change, setCoinsRet, nValueRet, not_input_fees);
  } else {
  + // The knapsack solver has some legacy behavior where it will spend dust outputs. We retain this behavior, so don't filter for positive only here.
  + // The knapsack solver currently does not use effective values, so we give GroupOutputs feerates of 0 so it sets the effective values to be the same as the real value.
  std::vector<OutputGroup> groups = GroupOutputs(coins, !coin_selection_params.m_avoid_partial_spends, CFeeRate(0), CFeeRate(0), eligibility_filter, false /* positive_only */);
  bnb_used = false;
  