Bug #58759 | Unnecessary poll before write | ||
---|---|---|---|
Submitted: | 6 Dec 2010 15:01 | Modified: | 15 Jan 2013 14:00 |
Reporter: | Olaf van der Spek (Basic Quality Contributor) | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server: C API (client library) | Severity: | S5 (Performance) |
Version: | 5.1.49 | OS: | Any |
Assigned to: | Matthew Lord | CPU Architecture: | Any |
Tags: | qc |
[6 Dec 2010 15:01]
Olaf van der Spek
[15 Jan 2013 14:00]
Matthew Lord
I can only assume that you're referring to libmysql when you say the C API? We are not explicitly making each poll call in libmysql, but rather with strace you are seeing lower level syscalls. The poll is done to ensure that the FD is available/ready for I/O and that nothing has changed (permissions, file was changed/extended/etc., file was deleted/unlinked, etc.). The poll call is also actually necessary in order to do (or at least attempt) non-blocking IO. One of the flags used/set (also seen in your example output) is POLLIN or "Data other than high priority data may be read without blocking.". I will close this for now as Not a Bug. If you feel that I'm somehow mistaken, please let me know. Thank you for the bug report, and for using MySQL!