accelerator 클래스

가속기는 데이터 병렬 컴퓨팅에 최적화된 하드웨어 기능입니다. 가속기는 PCIe 버스(예: GPU)에 연결된 디바이스이거나 기본 CPU에 설정된 확장 명령일 수 있습니다.

구문

class accelerator;

멤버

공용 생성자

속성 설명
액셀러레이터 생성자 accelerator 클래스의 새 인스턴스를 초기화합니다.
~accelerator 소멸자 개체를 accelerator 삭제합니다.

공용 메서드

이름 설명
create_view 이 가속기에서 개체를 accelerator_view 만들고 반환합니다.
get_all 사용 가능한 모든 가속기를 나타내는 개체의 accelerator 벡터를 반환합니다.
get_auto_selection_view 자동 선택 accelerator_view영역을 반환합니다.
get_dedicated_memory 에 대한 전용 메모리를 accelerator킬로바이트 단위로 반환합니다.
get_default_cpu_access_type 이 가속기에서 만든 버퍼의 기본 access_type 반환합니다.
get_default_view 에 연결된 기본 accelerator_view 개체를 accelerator반환합니다.
get_description 디바이스에 대한 간단한 설명을 반환합니다 accelerator .
get_device_path 디바이스의 경로를 반환합니다.
get_has_display 디스플레이에 accelerator 연결되어 있는지 여부를 확인합니다.
get_is_debug 광범위한 오류 보고를 위해 DEBUG 계층을 사용할 수 있는지 여부를 accelerator 확인합니다.
get_is_emulated 에뮬레이트되는지 여부를 accelerator 결정합니다.
get_supports_cpu_shared_memory 공유 메모리를 accelerator 지원하는지 여부를 결정합니다.
get_supports_double_precision 디스플레이에 accelerator 연결되어 있는지 여부를 확인합니다.
get_supports_limited_double_precision 배정밀도 수학에 accelerator 대한 지원이 제한되는지 여부를 결정합니다.
get_version 의 버전을 반환합니다 accelerator.
set_default 기본 가속기의 경로를 반환합니다.
set_default_cpu_access_type 배열에 대한 기본 CPU access_type설정하며 이에 accelerator대한 암시적 메모리 할당을 설정합니다.

Public 연산자

이름 설명
operator!= accelerator 개체를 다른 개체와 비교하고 같은 경우 반환 false 하고, 그렇지 않으면 반환합니다 true.
operator= 지정된 accelerator 개체의 내용을 이 개체에 복사합니다.
연산자== accelerator 개체를 다른 개체와 비교하고 같은 경우 반환 true 하고, 그렇지 않으면 반환합니다 false.

공용 데이터 멤버

이름 설명
cpu_accelerator CPU accelerator에 대한 문자열 상수입니다.
dedicated_memory 킬로바이트 단위의 accelerator전용 메모리를 가져옵니다.
default_accelerator 기본값 accelerator에 대한 문자열 상수입니다.
default_cpu_access_type 이에 대한 배열 및 암시적 메모리 할당accelerator에 대한 기본 CPU access_type가져오거나 설정합니다.
default_view 에 연결된 기본 accelerator_view 개체를 accelerator가져옵니다.
description 디바이스에 대한 accelerator 간단한 설명을 가져옵니다.
device_path 디바이스의 경로를 가져옵니다.
direct3d_ref Direct3D 참조 accelerator에 대한 문자열 상수입니다.
direct3d_warp 스트리밍 SIMD 확장(SSE)을 사용하는 다중 코어 CPU에서 C++ AMP 코드를 실행하는 데 사용할 수 있는 개체의 문자열 상수 accelerator 입니다.
has_display 디스플레이에 연결되어 있는지 여부를 accelerator 나타내는 부울 값을 가져옵니다.
is_debug 광범위한 오류 보고를 위해 DEBUG 계층을 사용할 수 있는지 여부를 accelerator 나타냅니다.
is_emulated 에뮬레이트되는지 여부를 accelerator 나타냅니다.
supports_cpu_shared_memory 공유 메모리를 accelerator 지원하는지 여부를 나타냅니다.
supports_double_precision 액셀러레이터가 배정밀도 수학을 지원하는지 여부를 나타냅니다.
supports_limited_double_precision 액셀러레이터가 배정밀도 수학에 대한 지원이 제한되어 있는지 여부를 나타냅니다.
version 의 버전을 가져옵니다 accelerator.

상속 계층 구조

accelerator

설명

가속기는 데이터 병렬 컴퓨팅에 최적화된 하드웨어 기능입니다. 가속기는 종종 불연속 GPU이지만 DirectX REF 디바이스, WARP(SSE 명령을 통해 가속되는 CPU 쪽 디바이스) 또는 CPU 자체와 같은 가상 호스트 쪽 엔터티일 수도 있습니다.

사용 가능한 디바이스를 accelerator 열거하거나 기본 디바이스, 참조 디바이스 또는 WARP 디바이스를 가져오면 개체를 생성할 수 있습니다.

요구 사항

헤더: amprt.h

네임스페이스: 동시성

~가속기

개체를 accelerator 삭제합니다.

~accelerator();

Return Value

accelerator

가속기 클래스의 새 인스턴스를 초기화합니다.

accelerator();

explicit accelerator(const std::wstring& _Device_path);

accelerator(const accelerator& _Other);

매개 변수

_Device_path
물리적 디바이스의 경로입니다.

_Other
복사할 가속기입니다.

cpu_accelerator

CPU 엑셀러레이터에 대한 문자열 상수를 가져옵니다.

static const wchar_t cpu_accelerator[];

create_view

지정된 큐 모드를 사용하여 이 액셀러레이터에서 accelerator_view 개체를 만들고 반환합니다. 큐 모드를 지정하지 않으면 새 accelerator_view 사용자는 queuing_mode::immediate 큐 모드를 사용합니다.

accelerator_view create_view(queuing_mode qmode = queuing_mode_automatic);

매개 변수

qmode
큐 모드입니다.

Return Value

지정된 큐 모드를 사용하는 이 액셀러레이터의 새로운 accelerator_view 개체입니다.

dedicated_memory

킬로바이트 단위의 accelerator전용 메모리를 가져옵니다.

__declspec(property(get= get_dedicated_memory)) size_t dedicated_memory;

default_accelerator

기본값 accelerator에 대한 문자열 상수입니다.

static const wchar_t default_accelerator[];

default_cpu_access_type

배열 및 암시accelerator적 메모리 할당에 대한 기본 cpu access_type.

__declspec(property(get= get_default_cpu_access_type)) access_type default_cpu_access_type;

default_view

에 연결된 기본 가속기 뷰를 accelerator가져옵니다.

__declspec(property(get= get_default_view)) accelerator_view default_view;

description

디바이스에 대한 accelerator 간단한 설명을 가져옵니다.

__declspec(property(get= get_description)) std::wstring description;

device_path

액셀러레이터의 경로를 가져옵니다. 이 경로는 시스템에서 고유합니다.

__declspec(property(get= get_device_path)) std::wstring device_path;

direct3d_ref

Direct3D 참조 엑셀러레이터에 대한 문자열 상수를 가져옵니다.

static const wchar_t direct3d_ref[];

direct3d_warp

스트리밍 SIMD 확장(SSE)을 사용하여 다중 코어 CPU에서 C++ AMP 코드를 실행하는 데 사용할 수 있는 개체의 문자열 상수 accelerator 입니다.

static const wchar_t direct3d_warp[];

get_all

사용 가능한 모든 가속기를 나타내는 개체의 accelerator 벡터를 반환합니다.

static inline std::vector<accelerator> get_all();

Return Value

사용할 수 있는 액셀러레이터의 벡터

get_auto_selection_view

자동 선택 accelerator_view 반환합니다. parallel_for_each 대상으로 지정하면 런타임에서 자동으로 선택되도록 parallel_for_each 커널을 실행하기 위한 대상 accelerator_view 발생합니다. 다른 모든 용도로 이 메서드에서 반환되는 accelerator_view 기본 가속기의 기본 accelerator_view 동일합니다.

static accelerator_view __cdecl get_auto_selection_view();

Return Value

자동 선택 accelerator_view.

get_dedicated_memory

에 대한 전용 메모리를 accelerator킬로바이트 단위로 반환합니다.

size_t get_dedicated_memory() const;

Return Value

accelerator를 위해 전용된 메모리(킬로바이트)입니다.

get_default_cpu_access_type

이 가속기에서 만든 버퍼에 대한 기본 cpu access_type 가져옵니다.

access_type get_default_cpu_access_type() const;

Return Value

이 가속기에서 만든 버퍼의 기본 cpu access_type.

get_default_view

에 연결된 기본 accelerator_view 개체를 accelerator반환합니다.

accelerator_view get_default_view() const;

Return Value

accelerator_view와 연결된 기본 accelerator 개체입니다.

get_description

디바이스에 대한 간단한 설명을 반환합니다 accelerator .

std::wstring get_description() const;

Return Value

accelerator 디바이스에 대한 간단한 설명입니다.

get_device_path

액셀러레이터의 경로를 반환합니다. 이 경로는 시스템에서 고유합니다.

std::wstring get_device_path() const;

Return Value

시스템 전체의 고유한 디바이스 인스턴스 경로입니다.

get_has_display

표시에 출력할 수 있는지 여부를 accelerator 나타내는 부울 값을 반환합니다.

bool get_has_display() const;

Return Value

true 디스플레이에 출력할 수 있으면 accelerator 이고, false그렇지 않으면 .입니다.

get_is_debug

광범위한 오류 보고를 위해 DEBUG 계층을 사용할 수 있는지 여부를 accelerator 확인합니다.

bool get_is_debug() const;

Return Value

trueaccelerator 광범위한 오류 보고를 위해 DEBUG 계층이 활성화되어 있으면 false입니다.

get_is_emulated

에뮬레이트되는지 여부를 accelerator 결정합니다.

bool get_is_emulated() const;

Return Value

trueaccelerator 뮬레이트된 경우 그렇지 않으면 false입니다.

get_supports_cpu_shared_memory

가속기가 가속기와 CPU 모두에서 액세스할 수 있는 메모리를 지원하는지 여부를 나타내는 부울 값을 반환합니다.

bool get_supports_cpu_shared_memory() const;

Return Value

true가속기가 CPU 공유 메모리를 지원하면 이고, 그렇지 않으면 . false

get_supports_double_precision

FMA(융합 곱하기 추가), 나누기, 상호 및 사이 캐스팅 int 을 포함하여 액셀러레이터가 배정밀도 수학을 지원하는지 여부를 나타내는 부울 값을 반환합니다. double

bool get_supports_double_precision() const;

Return Value

true액셀러레이터가 배정밀도 수학을 지원하면 이고, 그렇지 않으면 . false

get_supports_limited_double_precision

액셀러레이터가 이중 정밀도 수치를 제한적으로 지원하는지 여부를 나타내는 부울 값을 반환합니다. 액셀러레이터에서 제한적으로만 지원하는 경우 FMA(Fused Multiply Add), 나누기, 역수 및 intdouble 사이의 캐스팅은 지원되지 않습니다.

bool get_supports_limited_double_precision() const;

Return Value

true액셀러레이터가 배정밀도 수학에 대한 지원이 제한되어 있으면 이고, 그렇지 않으면 . false

get_version

의 버전을 반환합니다 accelerator.

unsigned int get_version() const;

Return Value

의 버전입니다 accelerator.

has_display

표시에 출력할 수 있는지 여부를 accelerator 나타내는 부울 값을 가져옵니다.

__declspec(property(get= get_has_display)) bool has_display;

is_debug

광범위한 오류 보고를 위해 DEBUG 계층이 활성화되어 있는지 여부를 accelerator 나타내는 부울 값을 가져옵니다.

__declspec(property(get= get_is_debug)) bool is_debug;

is_emulated

에뮬레이트되는지 여부를 accelerator 나타내는 부울 값을 가져옵니다.

__declspec(property(get= get_is_emulated)) bool is_emulated;

operator!=

accelerator 개체를 다른 개체와 비교하고 같은 경우 반환 false 하고, 그렇지 않으면 반환합니다 true.

bool operator!= (const accelerator& _Other) const;

매개 변수

_Other
이것과 비교할 accelerator 개체입니다.

Return Value

falseaccelerator 개체가 같으면 true그렇지 않으면 .입니다.

operator=

지정된 accelerator 개체의 내용을 이 개체에 복사합니다.

accelerator& operator= (const accelerator& _Other);

매개 변수

_Other
accelerator 복사할 개체입니다.

Return Value

accelerator 개체에 대한 참조입니다.

연산자==

accelerator 개체를 다른 개체와 비교하고 같은 경우 반환 true 하고, 그렇지 않으면 반환합니다 false.

bool operator== (const accelerator& _Other) const;

매개 변수

_Other
이것과 비교할 accelerator 개체입니다.

Return Value

true 다른 accelerator 개체가 이 개체와 같으면 .이 accelerator 고, false그렇지 않으면 .입니다.

set_default

기본 가속기를 암시적으로 사용하는 모든 작업에 사용할 기본 가속기를 설정합니다. 이 메서드는 런타임에서 선택한 기본 가속기가 기본 가속기를 암시적으로 사용하는 작업에 아직 사용되지 않은 경우에만 성공합니다.

static inline bool set_default(std::wstring _Path);

매개 변수

_경로
액셀러레이터의 경로입니다.

Return Value

true 기본 가속기 설정 시 호출이 성공하면 입니다. 그렇지 않으면 false입니다.

set_default_cpu_access_type

이 가속기에서 만든 배열 또는 이 가속기에서 액세스하는 array_views 일부로 암시적 메모리 할당에 대한 기본 cpu access_type 설정합니다. 이 메서드는 이 메서드에 대한 이전 호출에 의해 가속기 default_cpu_access_type 아직 재정의되지 않았으며 이 가속기에서 선택한 런타임 default_cpu_access_type 배열을 할당하거나 이 가속기에서 액세스한 array_view 지원하는 암시적 메모리 할당에 아직 사용되지 않은 경우에만 성공합니다.

bool set_default_cpu_access_type(access_type _Default_cpu_access_type);

매개 변수

_Default_cpu_access_type
이 가속기에서 배열/array_view 메모리 할당에 사용할 기본 cpu access_type.

Return Value

가속기 기본 cpu access_type 성공적으로 설정되었는지 여부를 나타내는 부울 값입니다.

supports_cpu_shared_memory

공유 메모리를 지원하는지 여부를 accelerator 나타내는 부울 값을 가져옵니다.

__declspec(property(get= get_supports_cpu_shared_memory)) bool supports_cpu_shared_memory;

supports_double_precision

액셀러레이터가 배정밀도 수치를 지원하는지 여부를 나타내는 부울 값을 가져옵니다.

__declspec(property(get= get_supports_double_precision)) bool supports_double_precision;

supports_limited_double_precision

액셀러레이터가 배정밀도 수학에 대한 지원이 제한되어 있는지 여부를 나타내는 부울 값을 가져옵니다. 액셀러레이터에서 제한적으로만 지원하는 경우 FMA(Fused Multiply Add), 나누기, 역수 및 intdouble 사이의 캐스팅은 지원되지 않습니다.

__declspec(property(get= get_supports_limited_double_precision)) bool supports_limited_double_precision;

version

의 버전을 가져옵니다 accelerator.

__declspec(property(get= get_version)) unsigned int version;

참고 항목

Concurrency 네임스페이스(C++ AMP)