Skip to content

Commit 91d21df

Browse files
committed
apply indentation standard
1 parent 0d4bec3 commit 91d21df

File tree

57 files changed

+4882
-3958
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+4882
-3958
lines changed

include/DataTypeOverloads.h

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
namespace dftfe
2323
{
2424
namespace utils
25-
{
25+
{
2626
inline double
2727
realPart(const double x)
2828
{
@@ -49,27 +49,27 @@ namespace dftfe
4949

5050
inline double
5151
imagPart(const double x)
52-
{
53-
return 0;
52+
{
53+
return 0;
5454
}
5555

5656

5757
inline float
5858
imagPart(const float x)
59-
{
60-
return 0;
59+
{
60+
return 0;
6161
}
6262

6363
inline double
6464
imagPart(const std::complex<double> x)
65-
{
66-
return x.imag();
65+
{
66+
return x.imag();
6767
}
6868

6969
inline float
7070
imagPart(const std::complex<float> x)
71-
{
72-
return x.imag();
71+
{
72+
return x.imag();
7373
}
7474

7575
inline double
@@ -95,7 +95,7 @@ namespace dftfe
9595
{
9696
return std::conj(x);
9797
}
98-
}
98+
} // namespace utils
9999
} // namespace dftfe
100100

101101
#endif

include/DeviceAPICalls.h

Lines changed: 41 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# define dftfeDeviceAPICalls_H
55

66
# include <TypeConfig.h>
7-
# include <DeviceTypeConfig.h>
7+
# include <DeviceTypeConfig.h>
88
namespace dftfe
99
{
1010
namespace utils
@@ -13,7 +13,7 @@ namespace dftfe
1313
deviceReset();
1414

1515
deviceError_t
16-
deviceMemGetInfo(size_t* free, size_t* total);
16+
deviceMemGetInfo(size_t *free, size_t *total);
1717

1818
deviceError_t
1919
getDeviceCount(int *count);
@@ -28,7 +28,7 @@ namespace dftfe
2828
deviceMalloc(void **devPtr, size_type size);
2929

3030
deviceError_t
31-
deviceMemset(void *devPtr,int value, size_type count);
31+
deviceMemset(void *devPtr, int value, size_type count);
3232

3333
/**
3434
* @brief
@@ -75,21 +75,36 @@ namespace dftfe
7575
* @param count The memory size in bytes of the array
7676
*/
7777
deviceError_t
78-
deviceMemcpyD2H_2D(void* dst, size_type dpitch, const void* src, size_type spitch, size_type width, size_type height);
78+
deviceMemcpyD2H_2D(void * dst,
79+
size_type dpitch,
80+
const void *src,
81+
size_type spitch,
82+
size_type width,
83+
size_type height);
7984

8085
/**
8186
* @brief Copy 2D array from device to device
8287
* @param count The memory size in bytes of the array
8388
*/
8489
deviceError_t
85-
deviceMemcpyD2D_2D(void* dst, size_type dpitch, const void* src, size_type spitch, size_type width, size_type height);
90+
deviceMemcpyD2D_2D(void * dst,
91+
size_type dpitch,
92+
const void *src,
93+
size_type spitch,
94+
size_type width,
95+
size_type height);
8696

8797
/**
8898
* @brief Copy 2D array from host to device
8999
* @param count The memory size in bytes of the array
90100
*/
91101
deviceError_t
92-
deviceMemcpyH2D_2D(void* dst, size_type dpitch, const void* src, size_type spitch, size_type width, size_type height);
102+
deviceMemcpyH2D_2D(void * dst,
103+
size_type dpitch,
104+
const void *src,
105+
size_type spitch,
106+
size_type width,
107+
size_type height);
93108

94109
/**
95110
* @brief HOST-DEVICE synchronization
@@ -102,43 +117,54 @@ namespace dftfe
102117
* @param count The memory size in bytes of the array
103118
*/
104119
deviceError_t
105-
deviceMemcpyAsyncD2H(void *dst, const void *src, size_type count,deviceStream_t stream = 0 );
120+
deviceMemcpyAsyncD2H(void * dst,
121+
const void * src,
122+
size_type count,
123+
deviceStream_t stream = 0);
106124

107125
/**
108126
* @brief Copy array from device to device
109127
* @param count The memory size in bytes of the array
110128
*/
111129
deviceError_t
112-
deviceMemcpyAsyncD2D(void *dst, const void *src, size_type count,deviceStream_t stream = 0 );
130+
deviceMemcpyAsyncD2D(void * dst,
131+
const void * src,
132+
size_type count,
133+
deviceStream_t stream = 0);
113134

114135
/**
115136
* @brief Copy array from host to device
116137
* @param count The memory size in bytes of the array
117138
*/
118139
deviceError_t
119-
deviceMemcpyAsyncH2D(void *dst, const void *src, size_type count,deviceStream_t stream = 0 );
140+
deviceMemcpyAsyncH2D(void * dst,
141+
const void * src,
142+
size_type count,
143+
deviceStream_t stream = 0);
120144

121145

122146
deviceError_t
123-
deviceStreamCreate(deviceStream_t* pStream);
147+
deviceStreamCreate(deviceStream_t *pStream);
124148

125149
deviceError_t
126150
deviceStreamDestroy(deviceStream_t stream);
127151

128152
deviceError_t
129-
deviceEventCreate(deviceEvent_t* pEvent);
153+
deviceEventCreate(deviceEvent_t *pEvent);
130154

131155
deviceError_t
132-
deviceEventDestroy(deviceEvent_t event);
156+
deviceEventDestroy(deviceEvent_t event);
133157

134158
deviceError_t
135-
deviceEventRecord(deviceEvent_t event,deviceStream_t stream=0);
159+
deviceEventRecord(deviceEvent_t event, deviceStream_t stream = 0);
136160

137161
deviceError_t
138-
deviceEventSynchronize(deviceEvent_t event);
162+
deviceEventSynchronize(deviceEvent_t event);
139163

140164
deviceError_t
141-
deviceStreamWaitEvent(deviceStream_t stream,deviceEvent_t event,unsigned int flags=0);
165+
deviceStreamWaitEvent(deviceStream_t stream,
166+
deviceEvent_t event,
167+
unsigned int flags = 0);
142168

143169
} // namespace utils
144170
} // namespace dftfe

0 commit comments

Comments
 (0)