[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] r11506 - gnuradio/branches/features/msg-passing/gruel/
From: |
jcorgan |
Subject: |
[Commit-gnuradio] r11506 - gnuradio/branches/features/msg-passing/gruel/src/lib/msg |
Date: |
Mon, 27 Jul 2009 01:34:52 -0600 (MDT) |
Author: jcorgan
Date: 2009-07-27 01:34:52 -0600 (Mon, 27 Jul 2009)
New Revision: 11506
Modified:
gnuradio/branches/features/msg-passing/gruel/src/lib/msg/msg_queue.cc
Log:
Optimize performance for the common case.
Modified: gnuradio/branches/features/msg-passing/gruel/src/lib/msg/msg_queue.cc
===================================================================
--- gnuradio/branches/features/msg-passing/gruel/src/lib/msg/msg_queue.cc
2009-07-27 04:36:37 UTC (rev 11505)
+++ gnuradio/branches/features/msg-passing/gruel/src/lib/msg/msg_queue.cc
2009-07-27 07:34:52 UTC (rev 11506)
@@ -69,7 +69,10 @@
pmt_t m(d_msgs.front());
d_msgs.pop_front();
- d_not_full.notify_one();
+
+ if (d_limit > 0) // Unlimited length queues never block on write
+ d_not_full.notify_one();
+
return m;
}
@@ -83,8 +86,10 @@
pmt_t m(d_msgs.front());
d_msgs.pop_front();
- d_not_full.notify_one();
+ if (d_limit > 0) // Unlimited length queues never block on write
+ d_not_full.notify_one();
+
return m;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Commit-gnuradio] r11506 - gnuradio/branches/features/msg-passing/gruel/src/lib/msg,
jcorgan <=