Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/pure-cfg/src/lib/cl-target/main.c
ViewVC logotype

Diff of /branches/pure-cfg/src/lib/cl-target/main.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1378, Thu Jun 23 01:24:20 2011 UTC revision 1379, Thu Jun 23 14:48:07 2011 UTC
# Line 57  Line 57 
57      Diderot_OptProcess (opts, argc, argv);      Diderot_OptProcess (opts, argc, argv);
58      Diderot_OptFree (opts);      Diderot_OptFree (opts);
59    
60        if (VerboseFlg)
61            PrintCLInfo (stdout, clInfo);
62    
63    // run the generated global initialization code    // run the generated global initialization code
64      if (VerboseFlg) printf("initializing globals ...\n");      if (VerboseFlg)
65            printf("initializing globals ...\n");
66    
67      Diderot_InitGlobals();      Diderot_InitGlobals();
68    
# Line 254  Line 258 
258      cl_device_id dev;      cl_device_id dev;
259      int i;      int i;
260      for (i = 0;  i < clInfo->platforms[0].numDevices;  i++) {      for (i = 0;  i < clInfo->platforms[0].numDevices;  i++) {
261          if (clInfo->platforms[0].devices[i].ty == CL_DEVICE_TYPE_GPU) {          if ((clInfo->platforms[0].devices[i].ty == CL_DEVICE_TYPE_GPU)
262            &&  clInfo->platforms[0].devices[i].isAvail)
263            {
264              dev = clInfo->platforms[0].devices[i].id;              dev = clInfo->platforms[0].devices[i].id;
265              break;              break;
266          }          }

Legend:
Removed from v.1378  
changed lines
  Added in v.1379

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0