accelerator::set_default Method

Returns the path to the default accelerator.

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

Parameters

  • _Path
    The path to the accelerator.

Return Value

The path to the default accelerator.

Remarks

The C++ AMP runtime picks a default accelerator, unless you write code to pick a specific accelerator. For more information, see Using accelerator and accelerator_view Objects.

You can specify the default accelerator object in these ways:

  1. Call the constructor that takes a device path parameter.

  2. Set the default accelerator using the accelerator::set_default Method and pass the value of accelerator::default_accelerator Data Member to the constructor.

Requirements

Header: amprt.h

Namespace: Concurrency

See Also

Reference

accelerator Class

Concepts

Using accelerator and accelerator_view Objects