Eugene Loh wrote:

In  mca_btl_sm_get_sync(), I see this:
      /* Use the DMA flag if knem supports it *and* the segment length
       is greater than the cutoff.  Note that if the knem_dma_min
       value is 0 (i.e., the MCA param was set to 0), the segment size
       will never be larger than it, so DMA will never be used. */
    icopy.flags = 0;
    if (mca_btl_sm_component.knem_dma_min <= dst->seg_len) {
        icopy.flags = mca_btl_sm_component.knem_dma_flag;
    }

I'm going to poke around some more, but this doesn't on the surface make sense to me. If knem_dma_min==0, it would seem as though the segment size will *always* be at least that large and DMA will *always* be used (if supported).

Answering my own question (or guessing, in any case), maybe the code is okay but the comment is misleading. If knem_dma_min==0, then mca_btl_sm_component_init() sets knem_dma_flag to 0. So, the seg_len test passes, but it has no effect.

Reply via email to