[openib-general] [PATCH] [libibverbs] Adding acks to all of the CQ events in the pingpong examples

Roland Dreier rdreier at cisco.com
Sun Jan 14 19:19:53 PST 2007


 > > OK, this is correct -- but since the examples don't destroy the CQ, is
 > > there any point in acking the events?

 > I think that the answer is yes, those tests are being used as a code
 > reference for new users, and this code should give a good example to them.

I guess my point was really that if people are using the code as a
reference, and you want to make it a better reference, then a patch
should actually make the code more correct.  And if the code never
destroys the CQ, then acking CQ events is actually worse than useless,
since it is just pointless overhead.

I would accept a patch that actually destroys all the IB objects, in
which case acking CQ events is necessary.  But I think I would prefer
a patch that calls ibv_ack_cq_events() only once by keeping a count of
the # of events to ack, since that style is likely to perform better.

 - R.




More information about the general mailing list