Commit Graph

198 Commits

Author SHA1 Message Date
David Anderson 3b906a191c - client: generalize the GPU framework so that
- new GPU types can be added easily
		- users can specify GPUs in cc_config.xml,
			referred to by app_info.xml,
			and they will be scheduled by BOINC
			and passed --device N options
			Note: the parsing of cc_config.xml is not done yet.
		- RPC protocols (account manager and scheduler)
			can now specify GPU types in separate elements
			rather than embedding them in tag names
			e.g. <no_rsc>NVIDIA</no_rsc> rather than <no_cuda/>
	- client: in account manager replies, parse elements of the form
		<no_rsc>NAME</no_rsc>
		indicating the GPUs of type NAME should not be used.
		This allows account managers to control GPU types
		not hardwired into the client.
		Note: <no_cuda/> and <no_ati/> will continue to be supported.
	- scheduler RPC reply: add
		<no_rsc_apps>NAME</no_rsc_apps>
		(NAME = GPU name)
		to indicate that the project has no jobs for the indicated GPU type.
		<no_cuda_apps> etc. are still supported 
	- client/lib: remove set_debts() GUI RPC
	- client/scheduler RPC
		remove <cuda_backoff> etc. (superceded by no_app)
		Exception: <ip_result> elements in sched request
		still have <ncudas> and <natis>.
		Fix this later.

	Implementation notes:
	- client/lib: change "CUDA" to "NVIDIA" in type/variable names, and in XML
		Continue to recognize "CUDA" for compatibility
	- host_info.coprocs no longer used within the client;
		use a global var (COPROCS coprocs) instead.
		COPROCS now has an array of COPROCs;
		GPUs types are identified by the array index.
		Index zero means CPU.
	- a bunch of other resource-specific structs (like RSC_WORK_FETCH)
		are now stored in arrays, with same indices as COPROCS
		(i.e. index 0 is CPU)
	- COPROCS still has COPROC_NVIDIA and COPROC_ATI structs to hold vendor-specific info
	- APP_VERSION now has a struct GPU_USAGE to describe its GPU usage

svn path=/trunk/boinc/; revision=23253
2011-03-25 03:44:09 +00:00
Charlie Fenton 53e92e0da0 client: Begin adding OpenCL support
svn path=/trunk/boinc/; revision=23251
2011-03-24 12:16:54 +00:00
David Anderson 046dc09202 - client: fix bug in setting GPU peak flops
svn path=/trunk/boinc/; revision=22950
2011-01-27 20:00:42 +00:00
David Anderson 396dc5a8b4 svn path=/trunk/boinc/; revision=22895 2011-01-12 01:17:07 +00:00
David Anderson 4f3d628e29 - client: if detect that system clock has been set backwards
(either at startup or during execution)
    reset a number of "wait until X" variables;
    otherwise we might wait years to contact a project, restart a file xfer, etc.
    Notes:
    - there is no problem setting clocks forward; things just happen prematurely
    - some variables (e.g. task deadlines) are not reset,
        because it's not clear what to set them to
- sched: remove ati_opencl plan class until we understand what it is


svn path=/trunk/boinc/; revision=22842
2010-12-17 01:30:01 +00:00
David Anderson c9be64765c - client: use project STD, rather than arrival time,
as the major criterion in choosing non-EDF GPU jobs.
    GPU scheduling now respects resource share,
    and as a result STD should no longer diverge.
- client simulator: various improvements, most notably
    that we now generate gnuplot graphs of all debt types

NOTE: the client problem was found and fixed using the simulator!


svn path=/trunk/boinc/; revision=22536
2010-10-15 20:16:00 +00:00
David Anderson fb923e7659 - API/client: move CUdevice_attribute_enum out of lib/coproc.h
to fix app build errors

svn path=/trunk/boinc/; revision=22502
2010-10-13 23:33:02 +00:00
David Anderson c7e13eafb3 - client: write GPU info to client_state.xml,
so that it can be input file to the client simulator.

svn path=/trunk/boinc/; revision=22405
2010-09-23 20:54:49 +00:00
David Anderson fac75370a8 - rename cal.h to cal_boinc.h to avoid name conflict
svn path=/trunk/boinc/; revision=22039
2010-07-22 20:08:33 +00:00
David Anderson e34dcc5bdb - client: when selecting the "best" ATI GPU, factors are:
1) double precision support
    2) memory size
    3) speed
    (similar to NVIDIA)

svn path=/trunk/boinc/; revision=21795
2010-06-23 18:16:19 +00:00
David Anderson 81973a9fff - scheduler: fix structural problems with sending user messages.
Old: various redundant and/or misleading messages were sent.
    New:
        - if host w/ no GPU contacts a GPU-only project,
            send high-pri message saying they need a GPU
        - if host w/ GPU has driver too old for all versions,
            send high-pri message saying to update driver
        - if host w/ GPU has driver too old for some versions,
            send low-pri message saying to update driver
        - if host has GPU but too little RAM for any app,
            send low-pri message saying so
- scheduler: revamp GPU plan class functions

svn path=/trunk/boinc/; revision=21760
2010-06-16 22:07:19 +00:00
David Anderson 6511e1f8e8 - client: let fake CUDA specify driver version
- client: restore call to diagnostics_finish() on exit.
	(should print mem info, but doesn't)
- manager: notices display tweak 

svn path=/trunk/boinc/; revision=21759
2010-06-16 21:57:28 +00:00
David Anderson 75e86bff04 - client/server/API: rename cudaDeviceProp to CUDA_DEVICE_PROP to
avoid conflict with nvidia's structure.
    Note: these structures don't have to be the same,
    since we populate our struct one item at a time.


svn path=/trunk/boinc/; revision=21668
2010-06-01 18:36:11 +00:00
David Anderson 1764c6f7d4 - scheduler: preliminary checkin of new limit code
svn path=/trunk/boinc/; revision=21621
2010-05-24 23:14:48 +00:00
David Anderson 49f3c1aa61 client: bug fixes
svn path=/trunk/boinc/; revision=21571
2010-05-18 21:11:35 +00:00
David Anderson 40eebe00af - client/scheduler: in COPROCS, instead of having a vector of
pointers to dynamically allocated COPROC-derived objects,
    just have the objects themselves.
    Dynamic allocation should be avoided at all costs.

svn path=/trunk/boinc/; revision=21564
2010-05-18 19:22:34 +00:00
David Anderson 5a8142a23c - client: don't promote multithread jobs ahead of EDF jobs
svn path=/trunk/boinc/; revision=21563
2010-05-18 16:45:55 +00:00
David Anderson 256c694c96 - client: make GPU available RAM measurement #ifdef-selectable,
and default it to off
- client: if we print available GPU RAM (which we now don't)
    have a separate timer per GPU type
- scheduler: add new plan classes cuda_opencl (sic) and ati_opencl

svn path=/trunk/boinc/; revision=21498
2010-05-13 03:07:33 +00:00
David Anderson 9d8b915cc4 - client: fix crashing bug.
Deleting records in ~COPROCS() was bad,
		since we copy HOST_INFO to APP_INIT_DATA,
		leading to a double deletion.

svn path=/trunk/boinc/; revision=21475
2010-05-12 17:02:57 +00:00
David Anderson 7e9a8e5f98 - client: fix memory leak
svn path=/trunk/boinc/; revision=21464
2010-05-11 20:41:01 +00:00
David Anderson 9619791ad3 - user web: more cleanup of prefs.inc
- client: code cleanup


svn path=/trunk/boinc/; revision=21267
2010-04-23 17:46:57 +00:00
Rom Walton ec04f5dcbd - CC: Reduce how often the client reports the amount of available
VRAM to once every 60 seconds.

    client/
        coproc_detect.cpp
        cpu_sched.cpp
    lib/
        coproc.h

svn path=/trunk/boinc/; revision=21264
2010-04-23 16:47:07 +00:00
David Anderson bede9972b1 - client: fix bug with NVIDIA GPUs.
Some of them allow only 1 CUDA context at a time.
    You need to create a CUDA context to get available VRAM.
    So the client would run a CUDA job, then immediately kill it.
    Solution:
    - If a GPU app is running,
        let it keep running regardless of available VRAM
        (if it's still running, it has enough VRAM).
    - But don't start new apps if there's not enough available VRAM,
        or it the amount is unknown
        (if the client can't create a CUDA context,
        the app won't be able to either)
- client: if <coproc_debug> is set, print available GPU RAM periodically

svn path=/trunk/boinc/; revision=21253
2010-04-22 17:45:33 +00:00
David Anderson 678d880c64 - client: clean up logic related to GPU available memory.
If a driver call to get available mem fail, mark the GPU as unusable.


svn path=/trunk/boinc/; revision=21210
2010-04-19 18:35:10 +00:00
David Anderson d4bb95d5a6 - client: when a GPU job finishes, clear the "schedule backoff"
of other jobs of that type.
		They're waiting for GPU RAM, which may now be available.
	- client: bug fix in GPU RAM availability
	- client: fix testing setup for GPU RAM availability

svn path=/trunk/boinc/; revision=21206
2010-04-18 05:29:29 +00:00
David Anderson 01402bb45a - client: improve GPU scheduling
old: assign GPUs, then check available RAM
        Problem: may cause starvation on multi-GPU systems.
    new: use available RAM info in the assignment process.
        Prevents starvation, also reduces the number of driver calls.

svn path=/trunk/boinc/; revision=21205
2010-04-18 03:00:33 +00:00
David Anderson 02717af2f3 - bug fixes
svn path=/trunk/boinc/; revision=21187
2010-04-15 21:58:44 +00:00
David Anderson 9a06c4164f - client: Fermi compute capability is 2, not 3
svn path=/trunk/boinc/; revision=21036
2010-03-31 18:31:56 +00:00
David Anderson ad9e5bd833 - client: NVIDIA peak FLOPS estimate was wrong for Fermi
(32 cores, not 8)

svn path=/trunk/boinc/; revision=21034
2010-03-31 05:29:37 +00:00
David Anderson a151ad6cb3 - client/scheduler: deal with situation where GPU has enough
RAM to run job, but when we actually run the job
    not enough GPU RAM is free, so the application fails.
    This can cause a large number of jobs to fail.
    Solution:
    - app_plan() can specify the GPU RAM requirements of an app version.
        This is passed to the client in a new field
        <gpu_ram> of the <app_version> element.
    - prior to starting or restarting a GPU app, the client
        checks the amount of free RAM on the particular GPU.
        If it's not enough for the app version,
        the client doesn't start it,
        and arranges for the scheduler to ignore it for 5 minutes
        (by which point there might be more free GPU RAM)
    Notes:
    1) this change will have effect only when
        both client and scheduler are updated.
    2) the check is done in enforce_schedule(),
        rather than schedule_cpus(),
        because only at that point
        have we assigned a specific GPU to the job.
    3) there's another case to deal with:
        a GPU app's malloc of GPU RAM fails in the middle of the job.
        Currently the job fails.
        I plan to add an API call boinc_temporary_exit(x) so
        that the job can exit and potentially restart in x seconds.
        (In principle this mechanism is sufficient for all cases,
        but it could lead to a lot of starting/exiting,
        so the current change is worthwhile).

svn path=/trunk/boinc/; revision=19864
2009-12-11 22:45:59 +00:00
David Anderson e27659858d - result of code shuffle: the HOST_INFO structure returned
by the get_host_info() GUI RPC now contains GPU info

svn path=/trunk/boinc/; revision=19798
2009-12-07 06:13:17 +00:00
David Anderson b70229c093 - code shuffle: move client-specific GPU code to a separate file
svn path=/trunk/boinc/; revision=19794
2009-12-07 00:42:03 +00:00
David Anderson 4bf2ef5198 - client: add new config options:
<ignore_cuda_dev>n</ignore_cuda_dev>
    <ignore_ati_dev>n</ignore_ati_dev>
    to ignore (not use) specific NVIDIA or ATI GPUs.
    You can ignore more than one.

svn path=/trunk/boinc/; revision=19566
2009-11-12 23:44:49 +00:00
David Anderson fe2a18f282 - client/scheduler: standardize the FLOPS estimate between NVIDIA and ATI.
Make them both peak FLOPS,
    according to the formula supplied by the manufacturer.

    The impact on the client is minor:
    - the startup message describing the GPU
    - the weight of the resource type in computing long-term debt

    On the server, I changed the example app_plan() function
    to assume that app FLOPS is 20% of peak FLOPS
    (that's about what it is for SETI@home)

svn path=/trunk/boinc/; revision=19310
2009-10-16 00:13:01 +00:00
David Anderson d6efa7dabb - client: address the situation where GPUs become unusable
for certain periods (e.g. when Remote Desktop is used on Win).
    - add is_usable() member function to COPROC.
        Currently this just calls the respective (CUDA or CAL)
        initialization function.
        We need to check whether this works and/or causes problems.
    - in enforce_schedule(), check whether usability has changed
        for each GPU type.
        If we've gone from usable to unusable,
        flag all jobs for that GPU as coproc_missing
        (so they won't get run, and will quit if they're running).
        If we've gone from unusable to usable, clear the flag.
    This should deal with all cases except where
    the client is started up with GPUs unusable.
- scheduler: more query optimizations for locality scheduling
    (from Oliver Bock)

svn path=/trunk/boinc/; revision=19301
2009-10-14 18:07:49 +00:00
David Anderson fca2cb8016 - client: restore calDeviceGetInfo(), add its info to COPROC_ATI struct
(some plan class might need to know this).
    Code cleanup.

svn path=/trunk/boinc/; revision=19234
2009-10-02 22:58:03 +00:00
Rom Walton ad455ab09d - client: Add support for checking for both amd* prefixed CAL libraries
and ati* prefixed CAL libraries.
    - scheduler: redefine ati class plans again.
        ati: CAL 1.0+, amd* prefixed libraries
        ati13amd: CAL 1.3+, amd* prefixed libraries
        ati13ati: CAL 1.3+, ati* prefixed libraries
        ati14: CAL 1.4+, ati* prefixed libraries

    sched/
        sched_customize.cpp
    lib/
        coproc.cpp, .h

svn path=/trunk/boinc/; revision=19162
2009-09-25 15:40:16 +00:00
David Anderson 39815033a3 - client: in GPU enumeration, separate warning msgs from GPU descriptions.
Show warning msgs only if log_flags.coproc_debug

svn path=/trunk/boinc/; revision=19153
2009-09-24 17:23:33 +00:00
David Anderson f5a6f862bf - client: fix bug in RR simulation:
start only enough jobs to fill CPUs per project,
    not all the CPU jobs at once.
    I'm not sure how much difference this makes,
    but this is how it's supposed to work.
- client: if app_info.xml doesn't specify flops,
    use an estimate that takes GPUs into account.
- client: if it's been more than 2 weeks since time stats update,
    don't decay on_frac at all.

svn path=/trunk/boinc/; revision=19035
2009-09-09 22:18:02 +00:00
David Anderson b129e71f20 - client: add code for faking ATI GPUs
svn path=/trunk/boinc/; revision=19024
2009-09-08 18:42:24 +00:00
David Anderson 2039e67638 - client: NVIDIA offers an API which tells you whether a GPU
is running a graphics application.
    Change the semantics of the "don't use GPU while computer in use" pref
    to "don't use a GPU that's running a graphics app while
    computer is in use".
    This will increase GPU utilization on multi-GPU systems.

svn path=/trunk/boinc/; revision=18942
2009-08-28 22:55:04 +00:00
David Anderson 9a8f91fb1e - client: in parsing <coproc> elements in <app_version>,
use a new type COPROC_REQ for which the count field is a double.
    Otherwise fractional GPU jobs don't work.

svn path=/trunk/boinc/; revision=18906
2009-08-24 23:16:17 +00:00
David Anderson f8977c52e7 - fixes to coproc stuff
svn path=/trunk/boinc/; revision=18881
2009-08-19 23:47:07 +00:00
David Anderson f1360e5971 - client: finish the implementation of fractional coproc jobs.
- different data structure for keeping track of coproc usage;
        instead of COPROC having per-instance pointers to ACTIVE_TASK,
        ACTIVE_TASK now has an array of device number indices
        for each instance that it's using.
    - in enforce_schedule(), we call a new function assign_coprocs()
        that decides what coproc instances each job will use,
        and prunes jobs for which we can't get an assignment.
        This function embodies lots of subtlety.
    - coproc_cmdline() no longer deals with reserving instances;
        it just has to generate the --device X cmdline

svn path=/trunk/boinc/; revision=18880
2009-08-19 23:21:55 +00:00
David Anderson 091dba7a65 svn path=/trunk/boinc/; revision=18874 2009-08-19 20:33:04 +00:00
David Anderson 073e6ded2c - client and scheduler: lay the groundwork for "fractional coproc jobs",
e.g. the Milkyway@home ATI app, of which we can typically run
    2 or 3 instances at once on a GPU.
    Changes include:
    - In APP_VERSION, don't use a COPROCS to represent the GPU
        requirements; just use doubles ncudas and natis.
    - sufficient_coprocs() etc. are no longer members of COPROCS
    - in HOST_USAGE, ncudas and natis are doubles
    - in scheduler request, req_instances is now a double

    This checkin doesn't include the job scheduling logic,
    i.e. assigning jobs to GPUs.  That will follow.

svn path=/trunk/boinc/; revision=18868
2009-08-19 18:41:47 +00:00
David Anderson 152ee20b17 - client: fix calculation of ATI flops
svn path=/trunk/boinc/; revision=18852
2009-08-17 17:27:06 +00:00
David Anderson c3fe504e1d - client: add ATI support to job scheduling and work fetch
svn path=/trunk/boinc/; revision=18850
2009-08-17 16:50:40 +00:00
David Anderson 8df1e1ebb3 - client: ATI tweaks
svn path=/trunk/boinc/; revision=18849
2009-08-16 04:02:11 +00:00
David Anderson 4eb7097653 compile fixes
svn path=/trunk/boinc/; revision=18848
2009-08-15 00:12:51 +00:00
David Anderson 3b03707efa - client: clean up ATI code and make it work (or at least compile)
under Linux

svn path=/trunk/boinc/; revision=18847
2009-08-15 00:00:57 +00:00
David Anderson 602ad0b5b7 - client: ATI GPU detection code (from Crunch3r)
svn path=/trunk/boinc/; revision=18846
2009-08-14 22:54:34 +00:00
David Anderson 94e75fd4b1 svn path=/trunk/boinc/; revision=18770 2009-07-29 21:21:52 +00:00
David Anderson e3a730c334 - client: add <use_all_gpus> config option. If set, use GPUs
even if they're not equivalent to the most capable one.
- Validator: fix one_pass_N_WU option.

svn path=/trunk/boinc/; revision=17896
2009-04-27 23:51:46 +00:00
David Anderson 5adb25381d - client: new approach to handling multiple GPUs.
old: find fastest GPU, and pretend that others are the same.
            Problem: other GPUs might be less capable,
            and not able to handle jobs sent by server.
        new: find the most "capable" GPU, use others that are equivalent,
            don't use those that are not.
            "Capable" is defined by
            - compute capability (i.e., hardware version)
            - driver version
            - memory size
            - FLOPs
            in that priority order.
        See comments in lib/coproc.h

svn path=/trunk/boinc/; revision=17855
2009-04-22 02:09:53 +00:00
David Anderson 90f863f08c - partial checkin so I can edit locally (bad network connection)
svn path=/trunk/boinc/; revision=17852
2009-04-21 08:11:28 +00:00
David Anderson c58136e5bf - client: improve CPU sched debug messages
(say what kind of job and why we're scheduling it)
- client: log messages describing GPUs: one line per GPU; fixes #879

svn path=/trunk/boinc/; revision=17847
2009-04-20 00:00:11 +00:00
David Anderson cd4786166a - client: fix crash
svn path=/trunk/boinc/; revision=17550
2009-03-06 23:27:19 +00:00
David Anderson e1b94a1e53 - client: add a new mechanism for assigning coproc instances to tasks,
and passing them the corresponding --device N cmdline args.
    This fixes a bug introduced in 17402 (Feb 26)
    that broke the --device feature,
    presumably causing problems on systems with multiple GPUs.

svn path=/trunk/boinc/; revision=17549
2009-03-06 23:10:45 +00:00
David Anderson c22b62f25b - scheduler: fix bugs in support for anonymous platform + coprocs
(app versions don't have a <coprocs> around coproc elements,
    may an oversight but let's stick with it).
    Anyway, I think it's working now.
- lib: remove "owner" array from COPROC.
    This was used in client to keep track of assignment of
    coprocessors to tasks, but we got rid of the reserve/free scheme.
    NOTE: this breaks the mechanism for passing --device N to apps;
    I'll have to do this another way.  Stay tuned.

svn path=/trunk/boinc/; revision=17543
2009-03-06 22:21:47 +00:00
David Anderson 16ca7cd359 svn path=/trunk/boinc/; revision=17332 2009-02-22 04:05:34 +00:00
David Anderson 4d1544e579 - client: detect NVIDIA driver version number, show it on startup,
and include it with CUDA coprocessor descriptor in request msgs

svn path=/trunk/boinc/; revision=17275
2009-02-16 23:03:03 +00:00
David Anderson b7a2c227ca - Work fetch / scheduler:
There are two mechanisms to prevent the scheduler from
    sending jobs that won't finish by their deadline.
    Simple mechanism:
        The client sends the interval x for which CPUs are projected
        to be saturated.
        Given a job with estimated duration y,
        the scheduler doesn't send it if x + y exceeds the delay bound.
        If it does send it, x is incremented by y.
    Complex mechanism:
        Client sends workload description.
        Scheduler does EDF simulation, sees if deadlines are missed.
        The only project using this AFAIK is BOINC alpha test.
    Neither of these mechanisms takes coprocessors into account,
    and as a result jobs could be sent that are doomed to
    miss their deadline.
    This checkin adds coprocessor awareness to the Simple mechanism.

    Changes:
    Client:
        compute estimated delay (i.e. time until non-saturation)
        for coprocessors as well as CPU.
        Send them in scheduler request as part of coproc descriptor.
    Scheduler:
        Keep track of estimated delays separately for different resources
- client: fixed bug that computed CPU estimated delay incorrectly
- client: the work request (req_secs) for a resource is the min
    of the project's share and the shortfall.

svn path=/trunk/boinc/; revision=17086
2009-01-30 21:25:24 +00:00
David Anderson 574d1fe087 - client: don't request work for a resource if it has no shortfall.
- client and server: get rid of coproc_cuda global.

svn path=/trunk/boinc/; revision=17019
2009-01-26 05:00:49 +00:00
David Anderson f90dddc9a6 - client: clamp long term debts tp +- 1 week
- client: fix CUDA debt calculation
- client: don't accumulate debt if project->dont_request_more_work
- client: improves messages

svn path=/trunk/boinc/; revision=16909
2009-01-14 23:56:07 +00:00
David Anderson 377545a056 - scheduler: if we're not sending work because of the user's "no GPUs" pref,
tell them so.
- scheduler: fix bug that caused no CUDA jobs to be sent

svn path=/trunk/boinc/; revision=16893
2009-01-12 23:47:52 +00:00
David Anderson 2cc81a97d5 - scheduler: initialize COPROC fields
svn path=/trunk/boinc/; revision=16891
2009-01-12 23:08:16 +00:00
David Anderson 8740ffdc94 - client: more work-fetch stuff.
No more per-project shortfall.
    It's getting pretty close.

svn path=/trunk/boinc/; revision=16765
2009-01-03 06:01:17 +00:00
David Anderson 8c591e31df - client: first whack at new work-fetch logic. Very preliminary.
svn path=/trunk/boinc/; revision=16754
2008-12-31 23:07:59 +00:00
David Anderson fae0903c0f - scheduler: store CUDA total memory as a double,
since it can be 4GB or larger


svn path=/trunk/boinc/; revision=16737
2008-12-22 22:12:57 +00:00
David Anderson 4a65681176 - scheduler: if client has coprocs,
put a textual summary of them in host.serialnum (currently unused)
- web: show coprocs on host detail page
- db_dump: include coproc info in host XML

svn path=/trunk/boinc/; revision=16697
2008-12-16 18:46:28 +00:00
David Anderson b3bc71047e - client, CUDA detection:
1) report all devices found
    2) use the specs of the fastest one

svn path=/trunk/boinc/; revision=16669
2008-12-11 21:44:22 +00:00
David Anderson 63a81014fe - line endings
svn path=/trunk/boinc/; revision=16176
2008-10-09 19:06:01 +00:00
David Anderson 6070af4fea - client: fix bugs in coprocessor scheduling;
add new <coproc_debug> log flag

svn path=/trunk/boinc/; revision=16122
2008-10-03 21:55:34 +00:00
David Anderson a4d5d49b28 - client: attempt to fix CPU sched bug in the presence of GPUs
(if there was an idle GPU, it would run unboundedly many CPU jobs)

svn path=/trunk/boinc/; revision=16043
2008-09-25 01:04:53 +00:00
Eric J. Korpela 40e243412d - Fixed fcgi builds to use an installed version of fcgi_stdio.h rather than
a modified boinc version.
    - Added new header "boinc_fcgi.h" to be used instead of "fcgi_stdio.h".
      This header defines I/O functions in the namespace FCGI rather than using
      redefined functions the way "fcgi_stdio.h" does.  This was causing a lot
      of headaches when both <cstdio> and "fcgi_stdio.h" was called.  Using
      overloaded functions fixes this problem, except when the only difference
      between functions is the return type (for example ::fopen() returns FILE*
      and FCGI::fopen() returns FCGI_FILE*).
    - Fixed some missing "#ifdef _WIN32" blocks in filesys.C



svn path=/trunk/boinc/; revision=15984
2008-09-09 19:10:42 +00:00
Rom Walton 481e45a50a - client: Both Windows x86 and Windows x64 CUDA Runtime libraries
should be 2.0.  This avoids crashes related to data structure
        changes in the Runtime.
        
    coprocs/CUDA/mswin/Win32/Debug/bin/
        cudart.dll
    coprocs/CUDA/mswin/Win32/Release/bin/
        cudart.dll
    coprocs/CUDA/mswin/Win32/ReleaseSigned/bin/
        cudart.dll
    coprocs/CUDA/mswin/x64/Debug/bin/
        cudart.dll
    coprocs/CUDA/mswin/x64/Release/bin/
        cudart.dll
    coprocs/CUDA/mswin/x64/ReleaseSigned/bin/
        cudart.dll
    lib/
        coproc.C, .h

svn path=/trunk/boinc/; revision=15925
2008-08-22 22:15:08 +00:00
David Anderson 87cf35f89b - client: fix CPU scheduling logic related to coprocessors
Old: when checking whether an app can be run,
        check for sufficient coprocessors relative to
        the current coprocessor usage.
        Bug: it there are 2 CUDA jobs,
        the scheduler will decide to run both.
        enforce_scheduler() will only be able to run one,
        and the other CPU will be idle.
    New: include coprocessor usage (along with RAM and CPUs)
        in the check, and do a simulated reservation.
        In the above scenario, the scheduler will select
        one CUDA app and one non-CUDA app.

svn path=/trunk/boinc/; revision=15904
2008-08-20 17:34:18 +00:00
David Anderson 4f66bb4c95 - added copyright and license info to .C, .cpp, .h files
- scheduler: fix bug in adaptive replication:
    if send an unreplicated job to untrusted host,
    set both wu.target_nresults and wu.min_quorum to app.target_nresults.

svn path=/trunk/boinc/; revision=15762
2008-08-06 18:36:30 +00:00
David Anderson 6c0731e82e - client: bug fixes to the above
- client: better messages reporting coprocessors
    - manager: bounds checks to avoid wxwidgets asserts
        when job CPU estimates are absurdly large

svn path=/trunk/boinc/; revision=15644
2008-07-21 19:56:01 +00:00
David Anderson 0496591da2 - client: if an app is using CUDA coprocessors,
pass it additional command line arg(s) "--device X" (X=0,1,...)
    to tell it which GPU(s) to use.

svn path=/trunk/boinc/; revision=15642
2008-07-21 16:25:03 +00:00
David Anderson d0ca745a0b - client, Linux: change CUDA probing.
libcudart{32,64}.so is bundled with client.
    client loads it and if successful calls the device-query functions.
- client, Linux: append the current directory
    (i.e., the BOINC data directory) to the LD_LIBRARY_PATH for apps.
    This goes after the project dir and the slot dir.
    This lets apps link to libcudartX.so.
    NOTE: this is not recommended; better to include it with your app.
- client: allow for multiple messages from coproc probing
- fixed indentation in cs_platforms.C


svn path=/trunk/boinc/; revision=15591
2008-07-10 21:57:18 +00:00
David Anderson fced9b663d - fix gcc warnings
svn path=/trunk/boinc/; revision=15493
2008-06-26 19:27:23 +00:00
David Anderson 48675cea31 - client: print msgs if can't find CUDA libs
svn path=/trunk/boinc/; revision=15446
2008-06-23 02:41:34 +00:00
David Anderson 18d6f5e708 - client: handle coprocs in RR simulation. Not tested.
TODO: handle multithread apps in RR simulation; should be easy now.

svn path=/trunk/boinc/; revision=15288
2008-05-23 22:03:27 +00:00
David Anderson c01e75ec4c - client: shuffle code to abstract coprocessor reservation
svn path=/trunk/boinc/; revision=15287
2008-05-23 21:24:36 +00:00
David Anderson 6ab203081d - client part of the above
svn path=/trunk/boinc/; revision=15169
2008-05-09 21:07:15 +00:00
David Anderson d2a02a5184 - client and server: in coprocessor records, change "name" to "type"
to avoid confusion with "name" field of CUDA.
    This is a bug fix - please port.
- start script: don't error out if run_state.xml file is empty
    (which happens if project runs out of disk space)

svn path=/trunk/boinc/; revision=15168
2008-05-09 20:54:52 +00:00
David Anderson fa6d38a51e - scheduler: fix FCGI compile problem.
FCGI can't use libboinc.a; is needs its own specially-compiled
    versions of everything in lib/


svn path=/trunk/boinc/; revision=15066
2008-04-17 15:43:51 +00:00
David Anderson b33276bee3 - compile fixes for gcc 4.x; fixes #592
svn path=/trunk/boinc/; revision=15007
2008-04-02 19:33:12 +00:00
David Anderson 5b92f66bf9 - client: finish and debug coprocessor support
- manager and GUI RPC: show plan class in app version string

svn path=/trunk/boinc/; revision=14994
2008-04-01 20:46:41 +00:00
David Anderson 9fa202d8f0 - client: add coprocessor support: i.e., parse the list of coprocs
in <app_version>s from the server,
    keep track of the number free of each type of coproc,
    and don't run an app that needs more than are available.
    (not quite working yet)

svn path=/trunk/boinc/; revision=14992
2008-04-01 15:08:47 +00:00
David Anderson 6af9f66b4e - DB/feeder/scheduler: change app_version.xml_doc from blob to mediumblob,
and change the correspending structure field from 64KB to 256KB
    (could increase this if needed).
    This is needed to handle app versions with lots (> 100) of files
- change LARGE_BLOB_SIZE to BLOB_SIZE a bunch of places
- Change COPROCS from vector<COPROC> to vector<COPROC*>.
    Otherwise the right virtual functions of COPROCs don't get called

svn path=/trunk/boinc/; revision=14986
2008-03-31 16:19:45 +00:00
David Anderson b91809d3c4 - try to get API to compile on Cygwin
svn path=/trunk/boinc/; revision=14982
2008-03-29 21:53:45 +00:00
David Anderson 61663b48f9 - client: debug coprocessor code
svn path=/trunk/boinc/; revision=14981
2008-03-28 21:22:48 +00:00
David Anderson ca516450e4 - some debugging code
svn path=/trunk/boinc/; revision=14980
2008-03-28 20:20:10 +00:00
David Anderson cc2f1a20a0 - lib: moved "run program as user" stuff to a separate file,
so it doesn't screw up the linkage of apps that don't use it
- start of server-side support for coprocessors

svn path=/trunk/boinc/; revision=14878
2008-03-10 21:59:27 +00:00
David Anderson c685f66384 - client: preliminary support for detecting and reporting coprocessors
(for now, CUDA devices)

svn path=/trunk/boinc/; revision=14876
2008-03-10 20:40:35 +00:00