Visible to Intel only — GUID: GUID-E713E28F-24BC-4E0B-A2CC-8C640046C21F
Visible to Intel only — GUID: GUID-E713E28F-24BC-4E0B-A2CC-8C640046C21F
get_mode
Gets the VM mode for a queue.
Description
The get_mode function returns the global VM mode parameter that controls accuracy and VM Strided API behavior for a given queue. The variable value is a combination by bitwise OR ( | ) of the values listed in the following table.
Value of mode |
Description |
---|---|
Accuracy Control |
|
oneapi::mkl::vm::mode::ha |
High accuracy versions of VM functions. (DEFAULT) |
oneapi::mkl::vm::mode::la |
Low accuracy versions of VM functions. |
oneapi::mkl::vm::mode::ep |
Enhanced performance accuracy versions of VM functions. |
Slice Argument Checking |
|
oneapi::mkl::vm::mode::badarg_exception |
Throw a oneapi::mkl::invalid_argument exception on invalid arguments. (DEFAULT) |
oneapi::mkl::vm::mode::badarg_quiet |
Invalid arguments quietly make the call a “no-op”. The VM status is set to vm::status::empty_computation. |
Slice Indexing Controls |
|
oneapi::mkl::vm::mode::slice_normal |
Non-equal slice sizes are considered invalid. (DEFAULT) |
oneapi::mkl::vm::mode::slice_minimum |
The minimum of all slice sizes defines the number of evaluations. |
oneapi::mkl::vm::mode::slice_cyclic |
The output slice(s) size defines the number of evaluations. Input slices wrap around from the start. |
Default Local Mode |
|
oneapi::mkl::vm::mode::not_defined |
VM mode not defined. This has no effect. |
See the example below
API
Syntax
uint64_t get_mode( queue& exec_queue )
get_mode supports the following devices: CPU and GPU.
Input Parameters
- exec_queue
-
The queue where the routine will be executed.
Output Parameters
- return value (old_mode)
-
Specifies the global VM mode.
Examples
accm = get_mode (exec_queue) & mode::accuracy_mask;
denm = get_mode (exec_queue) & mode::ftzdaz_mask;