Browse Source

Allow writing of multiple vector sizes to the configuration file.

nfactor-troky
ckolivas 13 years ago
parent
commit
1b1fa5cd89
  1. 4
      cgminer.c
  2. 4
      ocl.c

4
cgminer.c

@ -2304,6 +2304,10 @@ void write_config(FILE *fcfg) @@ -2304,6 +2304,10 @@ void write_config(FILE *fcfg)
fputs("\"intensity\" : \"", fcfg);
for(i = 0; i < nDevs; i++)
fprintf(fcfg, gpus[i].dynamic ? "%sd" : "%s%d", i > 0 ? "," : "", gpus[i].intensity);
fputs("\",\n\"vectors\" : \"", fcfg);
for(i = 0; i < nDevs; i++)
fprintf(fcfg, "%s%d", i > 0 ? "," : "",
gpus[i].vwidth);
#ifdef HAVE_ADL
fputs("\",\n\"gpu-engine\" : \"", fcfg);
for(i = 0; i < nDevs; i++)

4
ocl.c

@ -345,8 +345,10 @@ _clState *initCl(unsigned int gpu, char *name, size_t nameSize) @@ -345,8 +345,10 @@ _clState *initCl(unsigned int gpu, char *name, size_t nameSize)
if (gpus[gpu].vwidth)
clState->vwidth = gpus[gpu].vwidth;
else
else {
clState->vwidth = preferred_vwidth;
gpus[gpu].vwidth = preferred_vwidth;
}
if (gpus[gpu].work_size && gpus[gpu].work_size <= clState->max_work_size)
clState->wsize = gpus[gpu].work_size;

Loading…
Cancel
Save