How many cqe will create while using ib_write_bw test with qp number set to 8k? Will it be affected by the eth dev ring size?

Currently my eth dev rx depth(ring size) set to 1024 (using ethtool -g get).


Once I use ib_write_bw with -qp 8096, as client side(which ib_write_bw -d mlx5_0 -q 8096 1.1.1.1) how many cqe will create? Will it be affected by the ring size?

Is it Num.cqe = Num.qp = 8096 or Num.cqe = Num.qp * Ringsize = 8k*1k=8M or other size?
Some one help me to explain it? ths~

Hi,
perftest (ib_write_bw) is creating one CQ for all QP-s. In case of send/receive (ibv_send_bw) - 2 CQs: one for send_cq and other for recv_cq. The maximum number of CQEs is QP_tx_buffer_depth * num_of_qps.
For your question, the answer is Num.cqe = Num.qp * Ringsize = 8k*1k=8M

From perftest code,
int create_reg_cqs(struct pingpong_context *ctx,
struct perftest_parameters *user_param,
int tx_buffer_depth, int need_recv_cq)
{
ctx->send_cq = ibv_create_cq(ctx->context,tx_buffer_depth *
user_param->num_of_qps, NULL, ctx->send_channel, user_param->eq_num);
if (!ctx->send_cq) {
fprintf(stderr, “Couldn’t create CQ\n”);
return FAILURE;
}

    if (need_recv_cq) {
            ctx->recv_cq = ibv_create_cq(ctx->context,user_param->rx_depth *
                                            user_param->num_of_qps, NULL, ctx->recv_channel, user_param->eq_num);
            if (!ctx->recv_cq) {
                    fprintf(stderr, "Couldn't create a receiver CQ\n");
                    return FAILURE;
            }
    }

    return SUCCESS;

}

Best regards,
Michael