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

Method AsumPerformanceTest

src/tests/performance/perf-asum.cpp:106–126  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

104
105template <typename ElemType>
106AsumPerformanceTest<ElemType>::AsumPerformanceTest(
107 BlasFunction fn,
108 TestParams *params) : PerformanceTest(fn,(problem_size_t) ( (1 * params->N) * sizeof(ElemType) ) ), params_(*params), mobjX_(NULL), mobjAsum_(NULL)
109{
110
111 blasX_ = NULL;
112 mobjX_ = mobjAsum_= scratchBuff = NULL;
113 lengthX = 1 + (params->N - 1) * abs(params_.incx);
114
115 try
116 {
117 blasX_ = new ElemType[lengthX + params_.offBX];
118 }
119 catch(bad_alloc& ba) {
120 blasX_ = NULL; // areResourcesSufficient() will handle the rest and return
121 mobjX_ = mobjAsum_= scratchBuff = NULL;
122 ba = ba;
123 }
124
125 base_ = ::clMath::BlasBase::getInstance();
126}
127
128template <typename ElemType>
129AsumPerformanceTest<ElemType>::~AsumPerformanceTest()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected