summaryrefslogtreecommitdiffstats
path: root/xmrstak/backend/amd/amd_gpu/gpu.cpp
diff options
context:
space:
mode:
authorpsychocrypt <psychocrypt@users.noreply.github.com>2017-11-16 12:21:38 +0100
committerpsychocrypt <psychocrypt@users.noreply.github.com>2017-11-16 12:21:38 +0100
commitd0b99bb4c69565b2a53f783f88314a1a1955e999 (patch)
tree6ef9b5be97ee0171af88c16886b5c34766e0521e /xmrstak/backend/amd/amd_gpu/gpu.cpp
parent1dc874c542a23c36dd65ea0f5b9cb65e3c3a572a (diff)
downloadxmr-stak-d0b99bb4c69565b2a53f783f88314a1a1955e999.zip
xmr-stak-d0b99bb4c69565b2a53f783f88314a1a1955e999.tar.gz
remove space indention with tabs
- removed all space indention in `*.hpp` and `*.cpp` files
Diffstat (limited to 'xmrstak/backend/amd/amd_gpu/gpu.cpp')
-rw-r--r--xmrstak/backend/amd/amd_gpu/gpu.cpp62
1 files changed, 31 insertions, 31 deletions
diff --git a/xmrstak/backend/amd/amd_gpu/gpu.cpp b/xmrstak/backend/amd/amd_gpu/gpu.cpp
index 22ce5d0..135cac0 100644
--- a/xmrstak/backend/amd/amd_gpu/gpu.cpp
+++ b/xmrstak/backend/amd/amd_gpu/gpu.cpp
@@ -386,42 +386,42 @@ size_t InitOpenCLGpu(cl_context opencl_ctx, GpuContext* ctx, const char* source_
}
const cl_platform_info attributeTypes[5] = {
- CL_PLATFORM_NAME,
- CL_PLATFORM_VENDOR,
- CL_PLATFORM_VERSION,
- CL_PLATFORM_PROFILE,
- CL_PLATFORM_EXTENSIONS
+ CL_PLATFORM_NAME,
+ CL_PLATFORM_VENDOR,
+ CL_PLATFORM_VERSION,
+ CL_PLATFORM_PROFILE,
+ CL_PLATFORM_EXTENSIONS
};
const char* const attributeNames[] = {
- "CL_PLATFORM_NAME",
- "CL_PLATFORM_VENDOR",
- "CL_PLATFORM_VERSION",
- "CL_PLATFORM_PROFILE",
- "CL_PLATFORM_EXTENSIONS"
+ "CL_PLATFORM_NAME",
+ "CL_PLATFORM_VENDOR",
+ "CL_PLATFORM_VERSION",
+ "CL_PLATFORM_PROFILE",
+ "CL_PLATFORM_EXTENSIONS"
};
#define NELEMS(x) (sizeof(x) / sizeof((x)[0]))
void PrintDeviceInfo(cl_device_id device)
{
- char queryBuffer[1024];
- int queryInt;
- cl_int clError;
- clError = clGetDeviceInfo(device, CL_DEVICE_NAME, sizeof(queryBuffer), &queryBuffer, NULL);
- printf(" CL_DEVICE_NAME: %s\n", queryBuffer);
- queryBuffer[0] = '\0';
- clError = clGetDeviceInfo(device, CL_DEVICE_VENDOR, sizeof(queryBuffer), &queryBuffer, NULL);
- printf(" CL_DEVICE_VENDOR: %s\n", queryBuffer);
- queryBuffer[0] = '\0';
- clError = clGetDeviceInfo(device, CL_DRIVER_VERSION, sizeof(queryBuffer), &queryBuffer, NULL);
- printf(" CL_DRIVER_VERSION: %s\n", queryBuffer);
- queryBuffer[0] = '\0';
- clError = clGetDeviceInfo(device, CL_DEVICE_VERSION, sizeof(queryBuffer), &queryBuffer, NULL);
- printf(" CL_DEVICE_VERSION: %s\n", queryBuffer);
- queryBuffer[0] = '\0';
- clError = clGetDeviceInfo(device, CL_DEVICE_MAX_COMPUTE_UNITS, sizeof(int), &queryInt, NULL);
- printf(" CL_DEVICE_MAX_COMPUTE_UNITS: %d\n", queryInt);
+ char queryBuffer[1024];
+ int queryInt;
+ cl_int clError;
+ clError = clGetDeviceInfo(device, CL_DEVICE_NAME, sizeof(queryBuffer), &queryBuffer, NULL);
+ printf(" CL_DEVICE_NAME: %s\n", queryBuffer);
+ queryBuffer[0] = '\0';
+ clError = clGetDeviceInfo(device, CL_DEVICE_VENDOR, sizeof(queryBuffer), &queryBuffer, NULL);
+ printf(" CL_DEVICE_VENDOR: %s\n", queryBuffer);
+ queryBuffer[0] = '\0';
+ clError = clGetDeviceInfo(device, CL_DRIVER_VERSION, sizeof(queryBuffer), &queryBuffer, NULL);
+ printf(" CL_DRIVER_VERSION: %s\n", queryBuffer);
+ queryBuffer[0] = '\0';
+ clError = clGetDeviceInfo(device, CL_DEVICE_VERSION, sizeof(queryBuffer), &queryBuffer, NULL);
+ printf(" CL_DEVICE_VERSION: %s\n", queryBuffer);
+ queryBuffer[0] = '\0';
+ clError = clGetDeviceInfo(device, CL_DEVICE_MAX_COMPUTE_UNITS, sizeof(int), &queryInt, NULL);
+ printf(" CL_DEVICE_MAX_COMPUTE_UNITS: %d\n", queryInt);
}
uint32_t getNumPlatforms()
@@ -449,8 +449,8 @@ std::vector<GpuContext> getAMDDevices(int index)
uint32_t numPlatforms = getNumPlatforms();
- platforms = (cl_platform_id *) malloc(sizeof(cl_platform_id) * numPlatforms);
- clStatus = clGetPlatformIDs(numPlatforms, platforms, NULL);
+ platforms = (cl_platform_id *) malloc(sizeof(cl_platform_id) * numPlatforms);
+ clStatus = clGetPlatformIDs(numPlatforms, platforms, NULL);
clStatus = clGetDeviceIDs( platforms[index], CL_DEVICE_TYPE_GPU, 0, NULL, &num_devices);
device_list = (cl_device_id *) malloc(sizeof(cl_device_id)*num_devices);
@@ -500,7 +500,7 @@ int getAMDPlatformIdx()
cl_int clStatus;
platforms = (cl_platform_id *) malloc(sizeof(cl_platform_id) * numPlatforms);
- clStatus = clGetPlatformIDs(numPlatforms, platforms, NULL);
+ clStatus = clGetPlatformIDs(numPlatforms, platforms, NULL);
int platformIndex = -1;
@@ -554,7 +554,7 @@ size_t InitOpenCL(GpuContext* ctx, size_t num_gpus, size_t platform_idx)
uint32_t numPlatforms = getNumPlatforms();
platforms = (cl_platform_id *) malloc(sizeof(cl_platform_id) * numPlatforms);
- clStatus = clGetPlatformIDs(numPlatforms, platforms, NULL);
+ clStatus = clGetPlatformIDs(numPlatforms, platforms, NULL);
size_t infoSize;
clGetPlatformInfo(platforms[platform_idx], CL_PLATFORM_VENDOR, 0, NULL, &infoSize);
OpenPOWER on IntegriCloud