ensure that a TRMM function is faster then the respective GEMM one
| 1178 | #if 0 |
| 1179 | // ensure that a TRMM function is faster then the respective GEMM one |
| 1180 | static void |
| 1181 | checkIsTrmmFaster(BlasFunction trmmFn, BlasFunction gemmFn) |
| 1182 | { |
| 1183 | const char *s1, *s2; |
| 1184 | gflops_t gf1, gf2; |
| 1185 | |
| 1186 | gf1 = perfRecorder->clblasAvgPerf(trmmFn); |
| 1187 | gf2 = perfRecorder->clblasAvgPerf(gemmFn); |
| 1188 | |
| 1189 | if (isDoubleZero((double)gf1) || isDoubleZero((double)gf2)) { |
| 1190 | // skip, respective tests has not been run |
| 1191 | return; |
| 1192 | } |
| 1193 | |
| 1194 | s1 = functionToString(trmmFn); |
| 1195 | s2 = functionToString(gemmFn); |
| 1196 | cerr << "Check if the " << s1 << " function is faster than the " << |
| 1197 | s2 << " one" << endl; |
| 1198 | |
| 1199 | if (gf1 * 2 > gf2) { // since TRMM has in twice as less operations as GEMM |
| 1200 | cerr << "PASS" << endl << endl; |
| 1201 | } |
| 1202 | else { |
| 1203 | cerr << "FAIL" << endl << endl; |
| 1204 | } |
| 1205 | } |
| 1206 | #endif |
| 1207 | |
| 1208 | int |
no test coverage detected