Even though the individual getInstance functions of the timer classes return references, we convert those to pointers before returning from here so that the clients can initialize their local variables to NULL, which references do not allow.
| 25 | // we convert those to pointers before returning from here so that the clients can initialize |
| 26 | // their local variables to NULL, which references do not allow. |
| 27 | clsparseTimer* clsparseGetTimer(const clsparseTimerType type) |
| 28 | { |
| 29 | if (type == CLSPARSE_CPU) |
| 30 | return &clsparseHostTimer::getInstance(); |
| 31 | |
| 32 | return &clsparseDeviceTimer::getInstance(); |
| 33 | } |
nothing calls this directly
no outgoing calls
no test coverage detected