text
stringlengths
129
1.02k
or was added to the data clauses, new attach anddetach clauses were added, and matchingacc_attach andacc_detach runtime API routines were added; see Sections 264, 2712-2713 and 3229 The Intel Coprocessor Offload Interface target and API routine sec tions were removed from the Section A Recommendations for Implementers,...
mber a nd configuration of gangs of workers and vector length may be different for each kernel If theasync clause does not appear, there is an implicit barrier at the end of the kerne ls region, and the local thread execution will not proceed until the entire sequence o f kernels has completed execution Thecopy ,copyin...
have completed Errors Anacc_error_invalid_async error is issued if wait_arg is not a valid async- argument value Anacc_error_device_unavailable error is issued if dev_num is not a valid device number See Section 522 3210 acc wait Summary Theacc_wait routines wait for completion of all associated asynchronous operati...
, the host thread may orchestrate the execution by allocating memory o n the accelerator de- vice, initiating data transfer, sending the code to the accelerator, passing a rguments to the compute region, queuing the accelerator code, waiting for completion, transferrin g results back to the host, and deallocating memo...
Only the read and write of the location designated by xare performed mutually atomically The evaluation of expr orexpr-list need not be atomic with respect to the read or write of the location designated by x Anatomic construct with the capture clause forces an atomic update of the location designated byxusing the desi...
n Section 216 and count is a nonneg- ative integer indicating the array length If there is no dev_num argument, it is treated as if dev_num is the current device number Otherwise, dev_num must be a valid device number of the current device type A call to any of these routines returns an inde xiassociated with await_arg...
d from acc_malloc oracc_deviceptr The behavior of the acc_memcpy_device routines is: Ifbytes is zero, no action is taken Ifdata_dev_dest anddata_dev_src have the same value, no action is taken If the memory regions referred to by data_dev_dest anddata_dev_src overlap, the behavior is undefined If the data referred ...
ry as necessary Some accelerators implement a weak memory model In particular, they do not su pport memory coherence between operations executed by different threads; even on the same execution unit, mem- ory coherence is only guaranteed when the memory operations are separ ated by an explicit memory fence Otherwise, i...
uted in parallel across the gangs The dim argument is not allowed An argument with no keyword or with the num keyword is allowed only when the num_gangs does not appear on the kernels construct If an argument with no keyword or an argument after the num keyword appears, it specifies how many gangs to use to execute the ...
the pointer When the device pointer target is deallocated, the pointer in device memory sho uld be restored to the host value, so it can be safely copied back to host memory A detach action updates the pointer in device memory to have the same value as the corresponding pointer in lo cal memory; see Section 272 The att...
gh environment variables and through calls to OpenACC API r outines The program can retrieve values through calls to OpenACC API routines The ICVs are: acc-current-device-type-var - controls which type of device is used acc-current-device-num-var - controls which device of the selected type is used acc-default-async...
then the original directive is nonconforming The supported device types are implementation-defined Depending on the imp lementation and the compiling environment, an implementation may support only a single device type, or may support multiple device types but only one at a time, or may support multiple device types in ...
roperty will return 0 and acc_get_property_string will return a null pointer (in C or C++) or a blank string (in Fortran) in the following cases: If device type dev_type is not supported or no device of dev_type is available If the value of dev_num is not a valid device number for device type dev_type If the val...
in the current device memory and not in local memory The host may n ot be able to access variables in a device_resident clause The accelerator data lifetime of global variables or common blocks that appear in a device_resident clause is the entire execution of the program In Fortran, if the variable has the Fortran al...
arg appears as an actual argument in a procedure call in a compute construc t or an accelerator routine, and the associated dummy argument subarg also has the optional attribute, then PRESENT(subarg) returns the same value as PRESENT(subarg) would when executed on the host 2172 Do Concurrent Construct This section refe...
clause behaves as follows: At entry to a region, the structured reference counter is used On an enterdata directive, the dynamic reference counter is used Ifvaris present and is not a null pointer, a present increment action with the appropriate reference counter is performed Ifvaris not present, a copyin action...
attributes may appear in a data clause that overrides the imp licit attribute Variables with explicitly determined data attributes are those which appear in a da ta clause on a data construct, a compute construct, or a declare directive See Section A33 for recommended diagnostics related to data attributes OpenACC supp...
urrent-device-num-var for the cur- rent thread If there are no devices of device type dev_type or if device type dev_type is not supported, this routine returns -1 326 acc getproperty Summary Theacc_get_property andacc_get_property_string routines return the value of a device-property for the specified device Format C ...
by the compiler The implementatio n may use a different value than specified based on limitations imposed by the target arch itecture 2513 private clause Theprivate clause is allowed on the parallel andserial constructs; it declares that a copy of each item on the list will be created for each gang in all dimensions Re...
point in the execution of the program Calls may appear in the library itself, during the processing o f an event The OpenACC runtime must allow for this case, where the callback list for an even t is modified while that event is being processed Dynamic Registration and Unregistration Calls toacc_register andacc_unregist...
tive At least one copyout ,delete , ordetach clause must appear on an exitdata direc- tive if clause Theifclause is optional; when there is no ifclause, the compiler will generate code to allocate or deallocate space in the current device memory and move data from and to loca l memory When an ifclause appears, the pr...
t starts at the routine directive #pragma acc routine(f) gang void scopeB() { #pragma acc parallel f();// conforming } void f() {} // conforming C++ classes permit forward references from member function bodies to o ther members de- clared later For example, immediately within classA below,g’s scope does not start unt...
ost, wh en collecting performance statistics If no device type appears all devices will be initialize d Aninit directive may be used in place of a call to the acc_init oracc_init_device runtime API routine, as described in Section 327 Syntax In C and C++, the syntax of the init directive is: #pragma acc init [clause-li...
each array element of the array or subarray individually I f the reduction varis a com- posite variable, the reduction operation is logically equivalent to applying tha t reduction operation to each member of the composite variable individually If a variable is involved in a reduction that spans multiple nested loops w...
eans that code within the parallel region, but outside of a loop construct with gang-level worksharing, will be executed redu ndantly by all gangs One worker in each gang begins executing the code in the structured block of the construct Note: Unless there is a loop construct within the parallel region, all gangs will ...
re specified using special comments that are identifie d by a unique sentinel Compilers will typically ignore OpenACC directives if support is disabled or n ot provided 21 Directive Format In C and C++, OpenACC directives are specified with the #pragma mechanism The syntax of an OpenACC directive is: #pragma acc directive...
ed or disabled from a callback routine, either the same routine or another routine, for a different event or the same event for which the callback was invoked If a callback routine is enabled for an event wh ile that event is being processed, then the new callback routine will be immediately enabled If it app ears on t...
is used when there is an error condition issued from code executing on the device acc_error_device_init is used for any error initializing a device acc_error_device_shutdown is used for any error shutting down a device acc_error_device_unavailable is used when there is an error where the se- lected device is una...
immediate detach action on the pointer referred to by ptr_addr ; see Section 272 These routines may issue a data transfer from local memory to device memory The_async ver- sions of these routines will perform the data transfers asynchronously on the async queue associated withasync_arg These routines may return before...
e code on the device 519 Enqueue Data Update (Upload and Download) Thedata update profiling event names are acc_ev_enqueue_upload_start acc_ev_enqueue_upload_end acc_ev_enqueue_download_start acc_ev_enqueue_download_end The_start events are triggered just before each upload (data copy from local memo ry to device memory...
o one whenever the pointer is attached to new target address, and incremented whenever an attach action for that pointer is performed for the same target address The attachment counter is decremented whenever a detach action occurs for the pointer, and the pointer is detached when the attachment counter reaches zero Th...
om device Summary Theacc_memcpy_from_device routine copies data from device memory to local memory Format C or C++: void acc_memcpy_from_device(h_void *data_host_dest, d_void*data_dev_src, size_t bytes); void acc_memcpy_from_device_async(h_void *data_host_dest, d_void*data_dev_src, size_t bytes, int async_arg); Fortran...
argument value Anacc_error_device_unavailable error is issued if dev_num is not a valid device number See Section 522 3211 acc wait async Summary Theacc_wait_async routines enqueue a wait operation on one async queue of the current device or a specified device for the operations previously enqueued on a single specifie...
dimens ions For instance, after entering a loop partitioned for gang-level work-sharing at dimensio n 3, the program will be in GP3, GR2, GR1 mode When only one worker is active, in any gang-level execution mode, the pr ogram is in worker-single mode (WS mode) When only one vector lane is active, the program is in vec...
pointer otherwise For events that are neither _start or_end events, this field will be a null pointer Data Events For a data event, as noted in the event descriptions, the second argument will be a pointer to the acc_data_event_info struct typedef struct acc_data_event_info { acc_event_t event_type; int valid_bytes; acc...
rules apply to the directive line In itial directive lines must have whitespace after the sentinel Continued directive lines must have an ampersand ( &) as the last nonblank character on the line, prior to any comment placed in the dire ctive Continuation directive lines must begin with the sentinel (possibly preceded...
t of one or more integer expressions, and a var-list is a comma-separated list of one or more vars The one exception isclause-list , which is a list of one or more clauses optionally separated by commas #pragma acc directive-name [clause-list ]new-line For C/C++, unless otherwise specified, each expression inside of the...
lback from a thread T2 while it’s still processing a callback, from the same event type or from a different ev ent type, from another thread T1 Theacc_callback_info struct has a thread_id field, which the runtime must set to a unique value for each host thread If the tool library uses dynamic callback registration and ...
Any data clause on the compute construct, a lexically containing data construct, or a visible declare directive Exposed variable access : Any access to the data or address of a variable at a point within the compute construct where the variable is not private to a scope lexically enc losed within the compute construc...
issued; see Sections 2161 and 2162 See Section 522 256 if clause Theifclause is optional When the condition in theifclause evaluates to true, the region will execute on the current device When the condition in theifclause evaluates to false , the local thread will execute the region 257 self clause Theself clause is ...
as if it app ears in ano_create clause on the current construct If the variable is defined as global or fi le or function static, it must appear in a declare directive 263 Data Regions and Data Lifetimes Data in shared memory is accessible from the current device as well as to the local thread Such data is available to t...
In the case of combined directives, the outermost construct of the combined con struct should be specified as theparent_construct If the event was emitted as the result of the application making a call to the runtime api, the value will be acc_construct_runtime_api typedef enum acc_construct_t { acc_construct_paralle...
to an acc_create API routine (Section 3218) See those sections for details Acreate action for a varoccurs only when varis not already present in device memory Acreate action for a var: allocates device memory for var; and sets the structured or dynamic reference counter to one Copyin Action Acopyin action is one of...
vice memory for var Attach Action Anattach action is one of the actions that may be performed for a present (Section 275), copy (Section 276), copyin (Section 277), copyout (Section 278), create (Section 279), no_create (Section 2710), or attach (Section 2711) clause, or for a call to an acc_attach API routine (Section...
acc_register_library , passing the addresses of the reg- istration routines acc_callback_register andacc_callback_unregister , in case that routine comes from a dynamic library In the third argument it passes the address of the lookup routineacc_prof_lookup to obtain the addresses of inquiry functions No inquiry funct...
oss implementations and interoperability with other accelerator API s 18 References Each language version inherits the limitations that remain in previous versions o f the language in this list American National Standard Programming Language C , ANSI X3159-1989 (ANSI C) ISO/IEC 9899:1999, Information Technology – Pr...
library that will be invoked in the normal case where there is no LD_PRELOAD setting If an implementation only supports static linking, or if the application is linked without dynamic library support, this feature will not be av ailable Bash: export LD_PRELOAD=/home/user/lib/myprofso /myapp or LD_PRELOAD=/home/user/lib...
c variables are not supported in functions to wh ich aroutine directive applies In Fortran, variables with the save attribute, either explicitly or implicitly, are not supported in subprograms to which a routine directive applies A call to a procedure with a nohost clause must not appear in a compute construct that ...
pended to the tail of the callback list for that event Unregistering A matching call to acc_callback_unregister will remove that routine from the list of call- back routines for that event acc_callback_register(acc_ev_enqueue_upload_start, prof_data, acc_reg); // prof_data is on the callback list for acc_ev_enqueue_upl...
ot_host , andacc_device_current For other val- ues, look at the appropriate files included with the implementation, or read the do cumentation for the implementation The value acc_device_default will never be returned by any function; its use as an argument will tell the runtime library to use the default device type f...
ne directive for the procedure must include the nohost clause If the data ap- pears in alink clause, that data must have an active accelerator data lifetime by virtue of ap pearing in a data clause for a data construct, compute construct, or enterdata directive 216 Asynchronous Behavior This section describes the async...
urrent 291 collapse clause Thecollapse clause is used to specify how many nested loops are associated with the loop construct The argument to the collapse clause must be a constant positive integer expression If nocollapse clause appears, only the immediately following loop is associated with the loop construct If mor...
tion or automatic offloading, or paralle lizing across multiple accelerators of the same type, or across multiple accelerators of diffe rent types, these pos- sibilities are not addressed in this document 12 Execution Model The execution model targeted by OpenACC API-enabled implementations is hos t-directed execu- tion...
is created for each gang in all dimensions and shared across the set of thr eads associated with all the vector lanes of all the workers of that gang Restrictions See Section 2171 Optional Arguments for discussion of Fortran optional a rguments in private clauses /triangledownsld /triangledownsld Examples In the exa...
launch additional compute regions, allowing for nested parallelism In that case, the OpenACC directives may be executed by a host thread or a device thread This specification uses the term local thread orlocal memory to mean the thread that executes the directive, or the memory associated with that thread , whether tha...
scussion of Fortran optional a rguments in reduction clauses See Section 262 Variables with Implicitly Determined Data Attributes for a restriction re- quiring certain loop reduction variables to have explicit data clauses on their parent compute constructs Areduction clause may not appear on a loop directive that ha...
lerator 264 Data Structures with Pointers This section describes the behavior of data structures that contain pointer s A pointer may be a C or C++ pointer (eg, float*), a Fortran pointer or array pointer (eg, real, pointer, dimension(:) ), or a Fortran allocatable (eg, real,allocatable,dimension(:) ) When a data objec...
e strongly rec- ommended to use the names in this section The first subsection describes dev ices, such as NVIDIA GPUs The second subsection describes additional API routines for tar get platforms, such as CUDA and OpenCL The third subsection lists several recommended options for imp lementations A1 Target Devices A11 N...
the worker The iterations of the loop or loops will be partitioned across the v ector lanes using vector or SIMD operations Again, a single loop may be marked for one, two, or all three of gang, worker, and vector parallelism, and the iterations of that loop will be spread across th e gangs, workers, and vector lanes ...
xpr is not a valid device number or that device is not available Anacc_error_device_shutdown error is issued if there is an error shutting down the device See Section 522 2143 Set Directive Summary Theset directive provides a means to modify internal control variables using direc tives Each form of theset directive is...
edownsld /triangledownsld Examples On the following directive, worker appears as a device-specific clause for devices of type foo, butgang appears as a default clause and so applies to all device types, including foo #pragma acc loop gang device_type(foo) worker The first directive below is identical to the previous d...
for more information 215 Procedure Calls in Compute Regions This section describes how routines are compiled for an accelerator and h ow procedure calls are compiled in compute regions See Section 2171 Optional Arguments for discus sion of Fortran optional arguments in procedure calls inside compute regions 2151 Routi...
ed data attribu tes or otherwise implicitly by the compiler the implicit field in the event structure will be set to 1 5110 Wait Thewait profiling event names are acc_ev_wait_start acc_ev_wait_end Anacc_ev_wait_start event will be triggered for each relevant queue before the local threa d waits for that queue to be empt...
ent is acc_async_sync ifasync-argument has a value equal to the special value acc_async_sync , the value of acc-default-async-var ifasync-argument has a value equal to the special value acc_async_noval , the value of the async-argument , if it is nonnegative, implementation-defined, otherwise Theasync-value is used...
dynamic reference counters for vars appearing in copyout anddelete clauses, and will decrement the attachment counters for point- ers appearing in detach clauses If a finalize clause appears, the exitdata directive will set the dynamic reference counters to zero for vars appearing in copyout anddelete clauses, and will...
ion outside the loop int x = 0; #pragma acc parallel copy(x) { // gang-shared x undefined #pragma acc loop gang worker vector reduction(+:x) for (int i = 0; i < I; ++i) x += 1; // vector-private x modified // gang-shared x undefined }// gang-shared x updated for gang/worker/vector reduction // x = I xis private at eac...
the OpenACC runtime shuts down, either bec ause all devices have been shutdown by calls to the acc_shutdown API routine, or at the end of the program 512 Device Initialization and Shutdown Thedevice initialization profiling event names are acc_ev_device_init_start acc_ev_device_init_end These events are triggered when...
81, async queue, async-argument , 88, asynchronous execution, 11, atomic construct, attach action, 45, attach clause, attachment counter, auto clause, portability, autoscoping, barrier synchronization, 11, 32, 34, bind clause, block construct, cache directive, capture clause, collapse clause, common block, 45, 73, 74,...
ng-private y modified }// gang-shared x and y updated for gang reduction // x = I; y = I * /trianglesolid /trianglesolid 210 Cache Directive Summary Thecache directive may appear at the top of (inside of) a loop It specifies array e lements or subarrays that should be fetched into the highest level of the cache for the...
*acc_callback) (acc_callback_info *,acc_event_info *,acc_api_info *); The third argument is an enum type: typedef enum acc_register_t { acc_reg = 0, acc_toggle = 1, acc_toggle_per_thread = }acc_register_t; This is usually acc_reg , but see Section 542 Disabling and Enabling Callbacks for cases where different values ar...
hen executing accelerator regions The value of this environment variable mus t be a nonnegative integer between zero and the number of devices of the desired type attached to the h ost If the value is greater than or equal to the number of devices attached, the behavior is imple mentation-defined Example: setenv ACC_DEV...
tains, may contain, or may call another pr ocedure that contains a loop with a gang clause associated with dimension dor less worker clause Theworker clause specifies that the procedure contains, may contain, or may call ano ther pro- cedure that contains a loop with a worker clause, but does not contain nor does it cal...
on before starting to execute other gangs T his means that trying to implement synchronization between gangs is likely to fail In particular, a bar rier across gangs cannot be implemented in a portable fashion, since all gangs may not ever be active at the same time Similarly, the execution model allows for an implemen...
ype – a derived type in Fortran, or a struct orunion type in C, or a class , struct , orunion type in C++ (This is different from the use of the term composite data type in the C and C++ languages) Composite variable – a variable of composite datatype In Fortran, a composite variable must not have allocatable or pointe...
ive-name For C and C++, new-line means the newline character at the end of a line: #pragma acc directive-name new-line Optional syntax is enclosed in square brackets; an option that may be repe ated more than once is followed by ellipses: #pragma acc directive-name [clause [[,]clause ] ] new-line In this spec, a var(...
ion defines the number of workers within each gang that will be active after a gang transitions from worker-single mode to worker-partitioned mode If the clause does not appear, an implementation-defined default will be used; the default value ma y be 1, and may be different for each parallel construct or for each kernel...
552 OpenACC Events During Event Processing 553 Multiple Host Threads 6 Glossary A Recommendations for Implementers A1 Target Devices A11 NVIDIA GPU Targets A12 AMD GPU Targets ...
e 513 Enter Data and Exit Data Theenter data profiling event names are acc_ev_enter_data_start acc_ev_enter_data_end These events are triggered at enterdata directives, entry to data constructs, and entry to implicit data regions such as those generated by compute constructs The acc_ev_enter_data_start event is triggere...
outines copy the data to that device memory Format C or C++: d_void*acc_copyin(h_void *data_arg, size_t bytes); d_void*acc_create(h_void *data_arg, size_t bytes); void acc_copyin_async(h_void *data_arg, size_t bytes, int async_arg); void acc_create_async(h_void *data_arg, size_t bytes, int async_arg); Fortran: subrou...
handle; const void *context_handle; const void *async_handle; }acc_api_info; The fields are described below: acc_device_api device_api - The API in use for this device The data type is the enumeration acc_device_api , which is described later in this section intvalid_bytes - The number of valid bytes in this struct Se...
loops, and the element loops will all be inside the tileloops If thevector clause appears on the loop construct, the vector clause is applied to the element loops If the gang clause appears on the loop construct, the gang clause is applied to the tile loops If the worker clause appears on the loop construct, the worker...
plementa tion of this tools interface must also be thread-safe All threads use the same set of c allbacks for all events, so registering a callback from one thread will cause all threads to execute tha t callback This means that managing the callback lists for each event must be protected from multiple simultan eous up...
routine returns the value of acc-default-async-var for the cur- rent thread Format C or C++: int acc_get_default_async(void); Fortran: function acc_get_default_async() integer(acc_handle_kind) :: acc_get_default_async Description Theacc_get_default_async routine returns the value of acc-default-async-var for the cur-...
_arg is a null pointer and bytes is nonzero Anacc_error_not_present error is issued if the data section is not in shared memory and is not present in the current device memory Anacc_error_invalid_data_section error is issued if data_arg is an array sec- tion that is not contiguous (in Fortran) Anacc_error_partly_pre...
ointer varto one If the pointer is a null pointer, the pointer in device memory is updated to have the same value The update may complete asynchronously, depending on other clauses on the directive The implementation schedules pointer updates after any data copie s due to copyin actions that are performed for the same ...
down, which effectively s ets structured and dynamic reference counters to zero Format C or C++: void acc_shutdown(acc_device_t dev_type); void acc_shutdown_device(int dev_num, acc_device_t dev_ type); Fortran: subroutine acc_shutdown(dev_type) subroutine acc_shutdown_device(dev_num, dev_type) integer :: dev_num intege...
be used by tools f or profile or trace data collection Currently, this interface does not support tools that employ asy nchronous sampling Error events can be used to release resources or cleanly shut down a large parallel application when the OpenACC runtime detects an error condition from which it cannot recov er Thi...
r and bytes is nonzero Anacc_error_invalid_async error is issued if async_arg is not a valid async- argument value See Section 522 3228 acc memcpy device Summary Theacc_memcpy_device routine copies data from one memory location to another memory location on the current device Format C or C++: void acc_memcpy_device(d...
acc_is_present acc_memcpy_to_device ,acc_memcpy_from_device acc_update_device ,acc_update_self defined behavior with multiple host threads, such as with OpenMP recommendations for specific implementations clarified that no arguments are allowed on the vector clause in a parallel region 110 Corrections in the Aug...
truct A kernels region is a structured block which is compiled for the accelerator The code in the kernels region will be d ivided by the compiler into a sequence of kernels; typically each loop nest will become a single ker nel A kernels region may require space in device memory to be allocated and data to be copied f...
tine will get resolved by the dynamic loader 535 Application-Controlled Initialization An alternative to default initialization is to have the application itself call the library initialization routine, which then calls acc_callback_register for each appropriate event The library may be statically linked to the applica...
r execution on the current device Syntax In C and C++, the syntax of the OpenACC kernels construct is #pragma acc kernels [clause-list ]new-line structured block and in Fortran, the syntax is !$acc kernels [clause-list ] structured block !$acc end kernels or !$acc kernels [clause-list ] block construct [!$acc end kern...
*apiinfo) { acc_data_event_info *datainfo; datainfo = (acc_data_event_info *)eventinfo; switch( datainfo->event_type ) { case acc_ev_enqueue_upload_start : } } Multiple Callbacks Multiple callback routines can be registered on the same event: acc_callback_register(acc_ev_enqueue_upload_start, prof_data, acc_reg); a...
for the current thread to tell the program what type of device will be used to run th e next compute region, if one has been selected The device type may have been selected by the pro gram with a runtime API call or a directive, by an environment variable, or by the default behav ior of the implementation; see the tabl...
grams, which can pass arguments b y name See Section 32 Replaced composite variable by aggregate variable in reduction ,default , andprivate clauses and in implicitly determined data attributes; the new wording also includes F ortran character and allocatable/pointer variables See glossary in Section 6 116 Changes fr...
ment for varwill deallocate memory from both local memory as well as the current device memory, for a non-shared memory device, and the d ynamic reference counter will be set to zero If the structured reference counter is not z ero, a runtime error is issued In Fortran, if a variable varinvar-list has the Fortran point...
creates a data region When the program encounters a compute construct with explicit data clause s or with implicit data allocation added by the compiler, it creates a data region that has a duration o f the compute construct When the program enters a procedure, it creates an implicit data region tha t has a duration o...
reats auto asseq, the gangs redundantly compute arr’s maximum, but the combined result is still arr’s maximum Either way, because xis not private at the loop directive, the reduction updates xby the end of the parallel region int x = 0; const int *arr =/*array of I values */; #pragma acc parallel copy(x) { // gang-shar...
stem issues The default error callback routine may print an error message and halt p rogram execution The ap- plication can register one or more additional error callback routines, to allow a failing application to release resources or to cleanly shut down a large parallel runtime with many threads and processes See Ch...
n 522 274 deviceptr clause Thedeviceptr clause may appear on structured data and compute constructs and declare directives Thedeviceptr clause is used to declare that the pointers in var-list are device pointers, so the data need not be allocated or moved between the host and device for this po inter In C and C++, the ...