[pacman-dev] alpm_list: missing quick access to last element
aaronmgriffin at gmail.com
Mon Mar 5 14:13:30 EST 2007
On 3/5/07, Jürgen Hötzel <juergen at hoetzel.info> wrote:
> I'm quite impressed by the simple and elegant "Linux Kernel Linked Lists"
> (http://isis.poly.edu/kulesh/stuff/src/klist/ proposed by Dan) and
> currently merge them with ALPM's code into a new implementation using
> sentinel nodes. I will post details soon.
Yes the kernel implementation is REALLY nice. I always loved it. I
like that this guy actually took the extra step to remove the hardware
prefetching from the actual kernel header.
I also like the type safety it provides. That is a list of "pmpkg_t"
structs enforces the type. It does not require void* aliasing.
While it's unimportant really, the kernel implementation only uses 2
pointers per node, whereas a typical implementation of the same thing
(like ours) requires two. I find it neat that they were able to do
that. Go go kernel efficiency.
This would, however, require some hefty changes but would make the
code better in the long run (we will ALWAYS know the type of the
More information about the pacman-dev