This blog post assumes you have read the introduction to C++ AMP exceptions.
An instance of the unsupported_feature exception type is thrown on invoking a parallel_for_each/allocating an object on an accelerator which doesn’t support certain features needed for the execution to proceed.The table below lists the common scenarios that result in unsupported_feature exception.
Texture object creation on CPU accelerator
Feature not supported on cpu_accelerator
accelerator_view av = a.default_view;
std::cout<< ex.what() << std::endl;
Texture object creation with invalid combination of bits_per_channel and short-vector type
The combination of the short vector type and bits-per-scalar-element for the texture is not supported.
Read and write operations on textures not having bits-per-channel of value 32
Both read and write are detected on a texture with bits-per-scalar-element not equal to 32.
texture<int, 1> tex(ext, 16);
parallel_for_each(tex.extent, [&](index<1> idx) restrict(amp)
auto value = tex[idx] + 1;
My next blog post covers out_of_memory exception.