[openib-general] CQ peek

Kevin Reilly kjreilly at us.ibm.com
Fri Jul 8 15:08:41 PDT 2005





Peeks are often used to determine what processing to perform next in code
that doesn't want to do the processing itself.
A simple example would be if your in a send thread was sending lots on
packets every so often it may peek at a CQ used for receive completions and
if their are receives ready  then either signal the receive thread or just
put a marker on the wall and exit to allow receive
processing to happen. Usually ULP that support polling modes give priority
to receives over sends so peek is an easy way for the send
thread to cool it and switch gears to received.

Peek may also be useful to batch together completion processing into a
bigger therefore potentially more efficient unit. For example,
you have a send fifo where the completions are steered into a completion
queue.  You may only want to process the send completions
after some number of send fifo slots have completed therefore batching up
the processing into big units.

My last and least convincing reason for peek is if we want the gen2 user
space libraries to have a broad set of ULP layer ontop of
it.  Some of those ULPs may have implemented peek in their interface and
not having it in the lower layer makes it difficult.

Kevin J. Reilly
STSM, HPC Architecture
-Federation/HPS  Chief Engineer
-HPC interconnect architect
(office) 845-433-7976  (tieline) 8-293-7976



                                                                           
             Roland Dreier                                                 
             <rolandd at cisco.co                                             
             m>                                                         To 
                                       Kevin Reilly/Poughkeepsie/IBM at IBMUS 
             07/08/2005 04:48                                           cc 
             PM                        "openib-general at openib.org"         
                                       <openib-general at openib.org>         
                                                                   Subject 
                                       Re: [openib-general] CQ peek        
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           




    Kevin> Does gen2 user access lib have a way to peek at the CQ to
    Kevin> see if it has entries on it like VAPI did? All i see is
    Kevin> ways to pop an entry off the CQ.

No, I never implemented that API.  What is it useful for?

 - R.





More information about the general mailing list