qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 5/8] qemu-queue: really simplify QSIMPLEQ


From: Peter Maydell
Subject: Re: [Qemu-devel] [PATCH 5/8] qemu-queue: really simplify QSIMPLEQ
Date: Fri, 13 Jan 2012 16:04:45 +0000

On 2 January 2012 18:00, Paolo Bonzini <address@hidden> wrote:
> QSIMPLEQ is still relatively heavyweight when used as a free list,
> compared to a simple singly-linked list.  One disadvantage is that
> it requires an initializer macro, unlike for example QLIST.
>
> The patch removes the double links so that there is a "really really
> simple" queue type.

I don't think we should have macros that follow the standard
BSD queue.h naming pattern but don't work the same way...
And as Stefan says, without the INSERT_TAIL operation it isn't
actually a queue any more.

If you actually want a singly linked list I think you should
probably pull in the SLIST macros from BSD queue.h.
(http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/sys/queue.h?rev=1.53)

I think we'll then have the full set of data structures back
again (having added back simple-queues in commit c616bbe1).

-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]