From: Roberto Spadim [mailto:roberto@spadim.com.br]
Sent: Sonntag, 22. September 2013 07:46
To: Vladislav Vaintroub
Cc: maria-developers@lists.launchpad.net
Subject: Re: [Maria-developers] MDEV-5019 - THREADPOOL - Create Information
Schema Table for Threadpool
Hi guys! new doubts...
1)
threadpool.h don't have information about threadpool_unix.cc
structures/interactors
Why should it? The structs were only used in threadpool_unix.cc itself.
maybe we should rewrite the threadpool_unix.cc to a .cc file and a .h header
file?
You can if you wish, but I see no need. If you plan to write I_S plugin that
works only with unix threadpool, you can define it in the same file
threadpool_unix.cc , right?
samething to windows threadpool
As already discussed, MariaDB on Windows relies on OS to manage threadpool,
and there is no simple way to get threadpool diagnostics ( apart from
learning kernel debugging , and equipping yourself with "Windows Internals"
book that describes the structures). There are no interesting structures
either, the pool is represented by opaque PTP_POOL
2)
other doubt... how i know what threadpoll it's being used? windows/unix?
there's a #define that i could use with #ifdef XXX #else #endif ?
On Windows, Windows threadpool is used. Otherwise, Unix threadpool is used
. CMake will conditionally compile either threadpool_win.cc or
threadpool_unix.cc, dependent on OS. See sql/CMakeLists.txt
thanks!
2013/9/21 Roberto Spadim