]>
Commit | Line | Data |
---|---|---|
c63539ff ML |
1 | .. |
2 | Copyright 1988-2022 Free Software Foundation, Inc. | |
3 | This is part of the GCC manual. | |
4 | For copying conditions, see the copyright.rst file. | |
5 | ||
6 | .. _acc_copyout: | |
7 | ||
8 | acc_copyout -- Copy device memory to host memory. | |
9 | ************************************************* | |
10 | ||
11 | Description | |
12 | This function copies mapped device memory to host memory which is specified | |
13 | by host address :samp:`{a}` for a length :samp:`{len}` bytes in C/C++. | |
14 | ||
15 | In Fortran, two (2) forms are supported. In the first form, :samp:`{a}` specifies | |
16 | a contiguous array section. The second form :samp:`{a}` specifies a variable or | |
17 | array element and :samp:`{len}` specifies the length in bytes. | |
18 | ||
19 | C/C++: | |
20 | .. list-table:: | |
21 | ||
22 | * - *Prototype*: | |
23 | - ``acc_copyout(h_void *a, size_t len);`` | |
24 | * - *Prototype*: | |
25 | - ``acc_copyout_async(h_void *a, size_t len, int async);`` | |
26 | * - *Prototype*: | |
27 | - ``acc_copyout_finalize(h_void *a, size_t len);`` | |
28 | * - *Prototype*: | |
29 | - ``acc_copyout_finalize_async(h_void *a, size_t len, int async);`` | |
30 | ||
31 | Fortran: | |
32 | .. list-table:: | |
33 | ||
34 | * - *Interface*: | |
35 | - ``subroutine acc_copyout(a)`` | |
36 | * - | |
37 | - ``type, dimension(:[,:]...) :: a`` | |
38 | * - *Interface*: | |
39 | - ``subroutine acc_copyout(a, len)`` | |
40 | * - | |
41 | - ``type, dimension(:[,:]...) :: a`` | |
42 | * - | |
43 | - ``integer len`` | |
44 | * - *Interface*: | |
45 | - ``subroutine acc_copyout_async(a, async)`` | |
46 | * - | |
47 | - ``type, dimension(:[,:]...) :: a`` | |
48 | * - | |
49 | - ``integer(acc_handle_kind) :: async`` | |
50 | * - *Interface*: | |
51 | - ``subroutine acc_copyout_async(a, len, async)`` | |
52 | * - | |
53 | - ``type, dimension(:[,:]...) :: a`` | |
54 | * - | |
55 | - ``integer len`` | |
56 | * - | |
57 | - ``integer(acc_handle_kind) :: async`` | |
58 | * - *Interface*: | |
59 | - ``subroutine acc_copyout_finalize(a)`` | |
60 | * - | |
61 | - ``type, dimension(:[,:]...) :: a`` | |
62 | * - *Interface*: | |
63 | - ``subroutine acc_copyout_finalize(a, len)`` | |
64 | * - | |
65 | - ``type, dimension(:[,:]...) :: a`` | |
66 | * - | |
67 | - ``integer len`` | |
68 | * - *Interface*: | |
69 | - ``subroutine acc_copyout_finalize_async(a, async)`` | |
70 | * - | |
71 | - ``type, dimension(:[,:]...) :: a`` | |
72 | * - | |
73 | - ``integer(acc_handle_kind) :: async`` | |
74 | * - *Interface*: | |
75 | - ``subroutine acc_copyout_finalize_async(a, len, async)`` | |
76 | * - | |
77 | - ``type, dimension(:[,:]...) :: a`` | |
78 | * - | |
79 | - ``integer len`` | |
80 | * - | |
81 | - ``integer(acc_handle_kind) :: async`` | |
82 | ||
83 | Reference: | |
84 | :openacc:`2.6`, section | |
3ed1b4ce | 85 | 3.2.22. |