MCPcopy Create free account
hub / github.com/clMathLibraries/clBLAS / findBestPattern

Function findBestPattern

src/library/blas/generic/solution_seq_make.c:1069–1102  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1067}
1068
1069static cl_bool
1070findBestPattern(SolutionStep *step)
1071{
1072 cl_uint maxImages;
1073
1074 maxImages = getQueueMaxImages(step->cmdQueue);
1075
1076 do {
1077 /* It may be non first attempt. Ensure that there are not
1078 * hold images for this step
1079 */
1080 releaseStepImgs(step);
1081
1082 step->patternID = selectPattern( step, maxImages );
1083
1084 assert(step->patternID != (unsigned int)-1);
1085
1086 #ifdef DEBUG_2
1087 printf("select Pattern Done\n");
1088 #endif
1089
1090 getStepGranulation(step);
1091 #ifdef DEBUG_2
1092 printf("getStepGranulation done \n");
1093 #endif
1094
1095 assertGranulation(step->subdims, mempat->nrLevels,
1096 &step->pgran, mempat->thLevel);
1097 if (getStepResources(step))
1098 break;
1099 } while (maxImages-- != 0);
1100
1101 return (maxImages != (cl_uint)-1) ? CL_TRUE : CL_FALSE;
1102}
1103
1104void
1105detectProblemTails(SolutionStep *step)

Callers 1

makeSolutionSeqFunction · 0.85

Calls 6

getQueueMaxImagesFunction · 0.85
releaseStepImgsFunction · 0.85
selectPatternFunction · 0.85
getStepGranulationFunction · 0.85
assertGranulationFunction · 0.85
getStepResourcesFunction · 0.85

Tested by

no test coverage detected