[openib-general] DAPL for openib

Sean Hefty mshefty at ichips.intel.com
Wed Aug 25 14:25:17 PDT 2004


On Thu, 26 Aug 2004 01:13:38 +0300
"Michael S. Tsirkin" <mst at mellanox.co.il> wrote:

> Hello!
> Quoting r. Roland Dreier (roland at topspin.com) "Re: [openib-general] DAPL for openib":
> >     Michael> What was the data structure you had in mind for this?  On
> >     Michael> linux tree is the easiest I think , but thats not O(1).
> >     Michael> If you want to, a tree can keep mutiple identical items I
> >     Michael> think.
> > 
> > I think the O(1) data structure Sean has in mind is a dispatch table :)
> 
> Wouldnt it be a bit big? For 8 bit values for class/version and
> 128 methods 256*256*128 * sizeof(void*) --> 32 MByte on a 32 bit machine?

If you use separate tables for version, class, and method, and let them grow dynamically, they can be substantially smaller.  E.g. the version table would likely be a single entry referencing a class table.  The class table is about 8 entries long, but requires remapping class 0x81 to index 0.  The method array is only needed if a client doesn't register to receive all unsolicited MADs for a specific class.

Something like this should let you dispatch to a single client.  To support a client viewing the MAD, you'd just need linked lists at any point along the dispatch path.



More information about the general mailing list