-
Notifications
You must be signed in to change notification settings - Fork 1
/
float_intrinsic.h
132 lines (88 loc) · 4.42 KB
/
float_intrinsic.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
#pragma once
#include "cuda_runtime.h"
#if defined (__INTELLISENSE__) | defined (__RESHARPER__)
template<class T1, class T2>
void surf2Dwrite(T1 data, T2 surfObj, int x, int y, cudaSurfaceBoundaryMode boundaryMode = cudaBoundaryModeTrap);
// Calculate the fast approximate cosine of the input argument.
__device__ float __cosf (float x);
// Calculate the fast approximate base 10 exponential of the input argument.
__device__ float __exp10f (float x);
// Calculate the fast approximate base e exponential of the input argument.
__device__ float __expf (float x);
// Add two floating point values in round-down mode.
__device__ float __fadd_rd (float x, float y);
// Add two floating point values in round-to-nearest-even mode.
__device__ float __fadd_rn (float x, float y);
// Add two floating point values in round-up mode.
__device__ float __fadd_ru (float x, float y);
// Add two floating point values in round-towards-zero mode.
__device__ float __fadd_rz (float x, float y);
// Divide two floating point values in round-down mode.
__device__ float __fdiv_rd (float x, float y);
// Divide two floating point values in round-to-nearest-even mode.
__device__ float __fdiv_rn (float x, float y);
// Divide two floating point values in round-up mode.
__device__ float __fdiv_ru (float x, float y);
// Divide two floating point values in round-towards-zero mode.
__device__ float __fdiv_rz (float x, float y);
// Calculate the fast approximate division of the input arguments.
__device__ float __fdividef (float x, float y);
// Compute x × y + z as a single operation, in round-down mode.
__device__ float __fmaf_rd (float x, float y, float z);
// Compute x × y + z as a single operation, in round-to-nearest-even mode.
__device__ float __fmaf_rn (float x, float y, float z);
// Compute x × y + z as a single operation, in round-up mode.
__device__ float __fmaf_ru (float x, float y, float z);
// Compute x × y + z as a single operation, in round-towards-zero mode.
__device__ float __fmaf_rz (float x, float y, float z);
// Multiply two floating point values in round-down mode.
__device__ float __fmul_rd (float x, float y);
// Multiply two floating point values in round-to-nearest-even mode.
__device__ float __fmul_rn (float x, float y);
// Multiply two floating point values in round-up mode.
__device__ float __fmul_ru (float x, float y);
// Multiply two floating point values in round-towards-zero mode.
__device__ float __fmul_rz (float x, float y);
// Compute 1/x in round-down mode.
__device__ float __frcp_rd (float x);
// Compute 1/x in round-to-nearest-even mode.
__device__ float __frcp_rn (float x);
// Compute 1/x in round-up mode.
__device__ float __frcp_ru (float x);
// Compute 1/x in round-towards-zero mode.
__device__ float __frcp_rz (float x);
// Compute x^(-1/2) in round-to-nearest-even mode.
__device__ float __frsqrt_rn (float x);
// Compute x^(1/2) in round-down mode.
__device__ float __fsqrt_rd (float x);
// Compute x^(1/2) in round-to-nearest-even mode.
__device__ float __fsqrt_rn (float x);
// Compute x^(1/2) in round-up mode.
__device__ float __fsqrt_ru (float x);
// Compute x^(1/2) in round-towards-zero mode.
__device__ float __fsqrt_rz (float x);
// Subtract two floating point values in round-down mode.
__device__ float __fsub_rd (float x, float y);
// Subtract two floating point values in round-to-nearest-even mode.
__device__ float __fsub_rn (float x, float y);
// Subtract two floating point values in round-up mode.
__device__ float __fsub_ru (float x, float y);
// Subtract two floating point values in round-towards-zero mode.
__device__ float __fsub_rz (float x, float y);
// Calculate the fast approximate base 10 logarithm of the input argument.
__device__ float __log10f (float x);
// Calculate the fast approximate base 2 logarithm of the input argument.
__device__ float __log2f (float x);
// Calculate the fast approximate base e logarithm of the input argument.
__device__ float __logf (float x);
// Calculate the fast approximate of x y .
__device__ float __powf (float x, float y);
// Clamp the input argument to [+0.0, 1.0].
__device__ float __saturatef (float x);
// Calculate the fast approximate of sine and cosine of the first input argument.
__device__ void __sincosf (float x, float* sptr, float* cptr);
// Calculate the fast approximate sine of the input argument.
__device__ float __sinf (float x);
// Calculate the fast approximate tangent of the input argument.
__device__ float __tanf (float x);
#endif