mirror of https://github.com/BOINC/boinc.git
17a4ab8db9
- Win process control (affects API and wrapper): Since Win doesn't have an API for process suspend/resume, we were suspending processes by 1) enumerating all the threads in the system (typically several thousand) 2) suspending those belonging to the given process The problem: for each thread, the code was calling a function in diagnostics_win.cpp to see if the thread was exempted from suspension. This check (which is unnecessary anyway if we're suspending another process) was surrounded by a semaphore acquire/release. The result: performance problems. It could take a minute to suspend the threads. Solution: 1) do the check for exemption only if we're suspending threads in our own process (i.e. from the API) 2) if we're suspending multiple processes, enumerate the threads only once, and see if each one belongs to any of the processes 3) have the wrapper elevate itself to normal priority. Otherwise it can get preempted for long periods, sometimes in the middle of scanning the threads. Note: post-9x versions of Win have a process group API that includes suspend/resume. We'll switch to this soon. |
||
---|---|---|
.. | ||
ttf/liberation-fonts-ttf-2.00.0 | ||
Makefile.am | ||
Makefile.mingw | ||
boinc_api.cpp | ||
boinc_api.h | ||
boinc_api_fortran.cpp | ||
boinc_gl.h | ||
boinc_glut.h | ||
boinc_opencl.cpp | ||
boinc_opencl.h | ||
graphics2.cpp | ||
graphics2.h | ||
graphics2_unix.cpp | ||
graphics2_util.cpp | ||
graphics2_win.cpp | ||
graphics_api.cpp | ||
graphics_api.h | ||
graphics_data.cpp | ||
graphics_data.h | ||
graphics_impl.cpp | ||
graphics_impl.h | ||
graphics_impl_lib.cpp | ||
graphics_lib.cpp | ||
graphics_lib.h | ||
gutil.cpp | ||
gutil.h | ||
gutil_text.cpp | ||
mac_icon.cpp | ||
macglutfix.m | ||
make_app_icon_h.cpp | ||
reduce.h | ||
reduce_lib.cpp | ||
reduce_main.cpp | ||
static_graphics.cpp | ||
ttfont.cpp | ||
ttfont.h | ||
windows_opengl.cpp | ||
x_opengl.cpp | ||
x_opengl.h |