> Is there any way to figure out that a cq does not have any pending > completion entries and thus > is safe to call ibv_destroy_cq. Or is it ok to call destroy > regardless of whether there are completion > entries? I am seeing a seg fault in ibv_poll_cq if I adopt the > latter approach.
The only way to know that a CQ has no entries is to poll the CQ and not see any entries. However, it is fine to destroy a CQ if there are entries present. I don't understand how destroying a CQ could be connected to a seg fault in ibv_poll_cq, unless you are polling the CQ after calling ibv_destroy_cq() for that same CQ, which is a use-after-free bug in your code. - R. _______________________________________________ general mailing list [email protected] http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general
