[riot-notifications] [RIOT] core: priority_queue_add hangs on duplicate adds (#3132)

Kaspar Schleiser notifications at github.com
Mon Jun 1 11:47:29 CEST 2015


@gebart I share @OlegHahm's concerns regarding the hotness of this code. This priority queue is used in the scheduler. A context switch is 500 instructions. 5 instructions more lower our context switch speed by 1%.

IMHO we need more specific conventions for this. My preferred solution here would be a simple ```assert(node->next == new_obj)```, with asserts (or -DNDEBUG) coupled to DEVELHELP.

---
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/3132#issuecomment-107383361
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20150601/f942f661/attachment.html>


More information about the notifications mailing list