aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* | event/Loop: try to avoid the WakeFD when adding DeferredMonitorMax Kellermann2014-01-052-2/+24
| | | | | | | | | | | | | | | | | | Add a flag that indicates whether the EventLoop is currently "busy". As long as that flag is set, it does not need to be woken up - we can simply add the DeferredMonitor to the list, and it will be caught by EventLoop very soon. This eliminates nearly all of the DeferredMonitor overhead when compared to IdleMonitor, rendering IdleMonitor mostly obsolete.
* | event/Loop: combine multiple WakeFD::Write() callsMax Kellermann2014-01-051-1/+6
| | | | | | | | Reduce DeferredMonitor overhead.
* | event/Loop: add attribute "again"Max Kellermann2014-01-052-2/+10
| | | | | | | | Improved support for added events.
* | event/Loop: add thread-safety assertionsMax Kellermann2014-01-053-1/+30
| |
* | output/httpd: move the clients.clear() call to the IOThreadMax Kellermann2014-01-051-1/+3
| | | | | | | | This call is not thread-safe.
* | output/httpd: import GetEventLoop()Max Kellermann2014-01-052-3/+5
| |
* | ClientList: use "delete" instead of Client::Close()Max Kellermann2014-01-051-2/+8
| | | | | | | | | | Client::Close() installs a TimeoutMonitor, which is not something we should do during shutdown.
* | event/Loop: remove obsolete assertionMax Kellermann2014-01-051-2/+0
| |
* | event/Loop: move code to HandleDeferred()Max Kellermann2014-01-052-8/+19
| |
* | event/MultiSocketMonitor: add missing <algorithm> includeMax Kellermann2014-01-051-0/+2
| | | | | | | | For std::find_if().
* | event/MultiSocketMonitor: add method ReplaceSocketList()Max Kellermann2014-01-053-18/+43
| | | | | | Move code from AlsaMixerPlugin.
* | event/MultiSocketMonitor: include cleanupMax Kellermann2014-01-052-8/+1
| |
* | event/Loop: remove the GLib implementationMax Kellermann2014-01-0413-722/+22
| | | | | | | | | | Now that the remaining known bugs in poll() implementation are fixed, we can go on without the GLib implementation.
* | output/httpd: move Bind()/Unbind() to the IOThreadMax Kellermann2014-01-041-4/+8
| | | | | | | | Fixes more thread-safety bugs.
* | event/poll: eliminate one vector::size() callMax Kellermann2014-01-041-2/+3
| |
* | output/httpd: move all broadcast operations to the IOThreadMax Kellermann2014-01-042-11/+76
| | | | | | | | | | | | | | Add a Page queue to class HttpdOutput, and use DeferredMonitor to flush this queue inside the IOThread. This fixes a thread-safety issue: much of EventLoop is not thread-safe, and the httpd plugin ignored that problem.
* | output/httpd: use the IOThreadMax Kellermann2014-01-041-2/+2
| | | | | | | | | | Do all I/O in the IOThread and not in the main thread. This solves an upcoming deadlock problem.
* | output/httpd: move queue size check to HttpdClient::PushPage()Max Kellermann2014-01-043-18/+6
| | | | | | | | Don't let the server care for client problems.
* | output/httpd: wrap the std::list in std::queueMax Kellermann2014-01-042-6/+16
| |
* | output/httpd: merge duplicate code to ClearQueue()Max Kellermann2014-01-042-5/+15
| |
* | output/httpd: keep track of queue sizeMax Kellermann2014-01-042-13/+14
| | | | | | | | Don't iterate the std::list each time.
* | event/Loop: remove bogus "!quit" assertionMax Kellermann2014-01-041-5/+3
| | | | | | | | | | | | | | Commit 1f11959 allowed modifying the "quit" attribute from any thread, and thus the assertion may fail spuriously. This assertion is too strict for the relaxed use of "quit". Let's remove it and move the "quit" check to before the SockedMonitor::Dispatch() call.
* | event/Loop: remove unused method AddCall()Max Kellermann2014-01-042-28/+0
| |
* | event/Loop: non-recursive Break() implementationMax Kellermann2014-01-041-4/+2
| | | | | | | | | | | | Simply set the "quit" flag and wake up the thread. This works even if we're inside this thread. Setting "quit" to a new value without mutex protection is usually not safe, but good enough here.
* | mixer/alsa: use DeferredMonitor to update file descriptorsMax Kellermann2014-01-041-14/+7
| | | | | | | | | | EventLoop::AddCall() and EventLoop::AddIdle() are unsafe, because we can't cancel those calls.
* | event/BlockingCall: always use DeferredMonitor internallyMax Kellermann2014-01-041-24/+0
| | | | | | | | | | There is no advantage of using EventLoop::AddCall(), now that DeferredMonitor is thread-safe.
* | event/DeferredMonitor: make fully thread-safeMax Kellermann2014-01-044-54/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | Instead of creating a new eventfd for each DeferredMonitor instance, reuse EventLoop's eventfd, and add a std::list to EventLoop that manages the list of pending DeferredMonitors. This std::list is protected by the same mutex as the "calls" list. The bottom line is: reduced overhead because the per-instance eventfd was eliminated, slightly added overhead due to Mutex usage (but negligible), and we're thread-safe now. This subsystem is now good enough to replace EventLoop::AddCall().
* | Added application key for soundcloud pluginJames McGlashan (DarkFox)2014-01-041-1/+2
| |
* | Added soundcloud documentationJames McGlashan (DarkFox)2014-01-041-0/+41
| |
* | Added user and search paramaters for SoundCloud pluginJames McGlashan (DarkFox)2014-01-041-0/+8
| |
* | http -> https for SoundCloud pluginJames McGlashan (DarkFox)2014-01-022-6/+8
| |
* | output/httpd: change "struct" to "class"Max Kellermann2013-12-313-4/+7
| |
* | output/httpd: move code to methods Delay(), Play(), Cancel()Max Kellermann2013-12-312-22/+46
| |
* | output/httpd: move Cast() into the classMax Kellermann2013-12-312-25/+23
| |
* | output/httpd: add methods Init(), Finish()Max Kellermann2013-12-312-12/+29
| |
* | output/httpd: use reference instead of pointerMax Kellermann2013-12-313-14/+14
| |
* | output/httpd: make the HttpdClient base class "private"Max Kellermann2013-12-311-1/+1
| |
* | event/*Monitor: document as not being thread-safeMax Kellermann2013-12-314-0/+15
| |
* | event/Loop: document that AddCall() is thread-safeMax Kellermann2013-12-311-0/+5
| |
* | command: "lsinfo" and "readcomments" allowed for remote filesMax Kellermann2013-12-296-0/+68
| |
* | SongUpdate: read tags from songs in an archiveMax Kellermann2013-12-295-5/+131
| | | | | | | | | | Add the TagStream.cxx library, similar to TagFile.cxx, and use it to load tags from song files inside archives.
* | InputStream: add static method OpenReady()Max Kellermann2013-12-2911-62/+47
| | | | | | | | Merge some duplicate code.
* | TagFile: rewind the stream before trying the next pluginMax Kellermann2013-12-291-1/+2
| | | | | | | | Got lost in commit c97685fe
* | DecoderList: add "pure" attributeMax Kellermann2013-12-291-0/+1
| |
* | DecoderList: add function decoder_plugins_supports_suffix()Max Kellermann2013-12-294-54/+20
| | | | | | | | Replaces decoder_plugin_from_suffix().
* | DecoderThread: use decoder_plugins_try()Max Kellermann2013-12-291-32/+44
| | | | | | | | | | .. instead of decoder_plugin_from_suffix(). This reduces overhead by walking the array only once.
* | UpdateContainer: pass suffix instead of DecoderPluginMax Kellermann2013-12-293-6/+18
| | | | | | | | | | Instead of using the first DecoderPlugin that supports the suffix, use the first one that actually implements the "container_scan" method.
* | TagFile: pass reference instead of pointerMax Kellermann2013-12-295-9/+6
| |
* | TagFile: use decoder_plugins_try()Max Kellermann2013-12-291-41/+54
| | | | | | | | | | | | .. instead of decoder_plugin_from_suffix(). This reduces overhead by walking the array only once.
* | DecoderList: remove unused function decoder_plugin_from_mime_type()Max Kellermann2013-12-292-25/+0
| |