consolidate thread local storage (#915)

* all thread local access now through single struct

* clean up old commented-out code, more use of GET_TLS()

* fewer calls to GET_TLS by passing tls as a funtion argument

* revert unnecessary change to printf

* fix failing tests due to TLS change

* fix merge conflicts in ihipOccupancyMaxActiveBlocksPerMultiprocessor


[ROCm/hip commit: 1eb3dbf065]
Tento commit je obsažen v:
Jeff Daily
2019-08-05 02:51:02 -07:00
odevzdal Maneesh Gupta
rodič 3fe8568377
revize 9b44993343
14 změnil soubory, kde provedl 172 přidání a 158 odebrání
+3 -3
Zobrazit soubor
@@ -33,8 +33,8 @@ hipError_t hipGetLastError() {
HIP_INIT_API(hipGetLastError);
// Return last error, but then reset the state:
hipError_t e = ihipLogStatus(tls_lastHipError);
tls_lastHipError = hipSuccess;
hipError_t e = ihipLogStatus(tls->lastHipError);
tls->lastHipError = hipSuccess;
return e;
}
@@ -42,7 +42,7 @@ hipError_t hipPeekAtLastError() {
HIP_INIT_API(hipPeekAtLastError);
// peek at last error, but don't reset it.
return ihipLogStatus(tls_lastHipError);
return ihipLogStatus(tls->lastHipError);
}
const char* hipGetErrorName(hipError_t hip_error) {