Skip to content

Commit

Permalink
fixed include formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
Dando18 committed Jul 25, 2019
1 parent e21db70 commit bcccdf7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion include/mdnn_device_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,13 @@
*/
#pragma once

/* Named mdnn_device_types.h so as not to interfere with cuda's device_types.h
/* Named mdnn_device_types.h so as not to interfere with cuda's device_types.h
TODO -- refactor/rename this file
*/

#include <cstdint>
#include <iostream>

#include "types.h"

namespace magmadnn {
Expand All @@ -37,8 +38,10 @@ struct GetDeviceType {};
}

combine(HOST, CPU);
#if defined(_HAS_CUDA_)
combine(DEVICE, GPU);
combine(MANAGED, COMBINED);
#endif

#undef combine

Expand Down Expand Up @@ -69,8 +72,10 @@ inline DeviceType getDeviceType(memory_t mem_type) {

switch (mem_type) {
CASE(HOST)
#if defined(_HAS_CUDA_)
CASE(DEVICE)
CASE(MANAGED)
#endif
default:
return CPU;
}
Expand Down

0 comments on commit bcccdf7

Please sign in to comment.