This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

atomic singly linked lists


Another enhancement suggestion for eCos: one data structure I've found very
useful when writing drivers on NT is the atomic singly linked list.  This
is a list that allows you to push/pop an item at the front of the list, and
on CPUs that support an atomic exchange instruction (like P3), to do it
without having to acquire and release a spinlock.  This is extremely useful
when maintaining a list of free items that get allocated at thread level
and freed at DSR level.  Using the atomic list means you don't have to
block DSRs while the thread is allocating an item.  Its a nice optimization
on uniprocessor systems, and on SMP systems, the benefits are even greater.

Andre Asselin
IBM ServeRAID Software Development
Research Triangle Park, NC


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]