Microsoft publishes fancy-pants heterogeneous parallel GPGPU C++ AMP specification

Microsoft logoMicrosoft has published the specification for C++ AMP (Accelerated Massive Parallelism), its new system for heterogeneous parallel processing in C++. When Microsoft first announced C++ AMP in June last year, it said that it wanted to make the AMP specification open to all.

AMP has been developed by Microsoft with input from AMD and NVIDIA. Microsoft's implementation allows AMP programs to use both the main CPU and Direct3D video cards (via the company's DirectCompute API), though the specification should also permit OpenGL/OpenCL-based implementations.

Microsoft encourages other compiler developers to implement the technology. The published specification includes within it an irrevocable promise to not assert claims on any patents that Microsoft may hold that are relevant to AMP unless the implementing party sues Microsoft for patent infringement.

AMP is some pretty cool stuff. Programs are written in C++, and blocks that should be computed in parallel (whether on the CPU or the video card) are annotated (and restricted) in various ways but are kept inline with the rest of the C++ program, and so look just like C++.

The closest equivalent to AMP is OpenCL. OpenCL is also designed for heterogeneous parallel computing, and is also not tied to any specific video card manufacturer. OpenCL is based on C rather than C++, with the GPU functions written in a restricted form of C99 rather than a restricted C++.

But OpenCL is a lot more manual and low-level. In OpenCL, the GPU functions are typically (though not always) quite separate, either in special OpenCL source code files or embedded as blocks of text within the program. Instead of calling them just like regular functions, OpenCL functions must be manually compiled at runtime. Data buffers in OpenCL must be explicitly sent to the video card, and both buffer operations and function calls must be explicitly enqueued so that the GPU can run them.

The result is that in OpenCL there's a big divide between the CPU world and the GPU world, and bridging the two requires lots of manual management by the programmer. C++ AMP makes using the GPU a lot more streamlined; the management is performed automatically, allowing developers to write more natural, high-level programs.

For heterogeneous programming to become genuinely widespread and mainstream, the kind of easy-to-use, natural integration with existing programming languages seems like a necessary step. OpenCL was a step in the right direction, but C++ AMP goes far further towards bridging CPU programming and GPU programming. Microsoft's next version of Visual C++ will include support for C++ AMP. With the publishing of the specification, along with the patent promise, the door is open to other implementations.

Source: Ars Technica

Tags: Microsoft

Comments
Add comment

Your name:
Sign in with:
or
Your comment:


Enter code:

E-mail (not required)
E-mail will not be disclosed to the third party


Last news

 
Galaxy Note10 really is built around a 6.7-inch display
 
You may still be able to download your content
 
Facebook, Messenger and Instagram are all going away
 
Minimize apps to a floating, always-on-top bubble
 
Japan Display has been providing LCDs for the iPhone XR, the only LCD model in Apple’s 2018 line-up
 
The 2001 operating system has reached its lowest share level
 
The entire TSMC 5nm design infrastructure is available now from TSMC
 
The smartphone uses a Snapdragon 660 processor running Android 9 Pie
The Samsung Galaxy A5 (2017) Review
The evolution of the successful smartphone, now with a waterproof body and USB Type-C
February 7, 2017 / 2
Samsung Galaxy TabPro S - a tablet with the Windows-keyboard
The first Windows-tablet with the 12-inch display Super AMOLED
June 7, 2016 /
Keyboards for iOS
Ten iOS keyboards review
July 18, 2015 /
Samsung E1200 Mobile Phone Review
A cheap phone with a good screen
March 8, 2015 / 4
Creative Sound Blaster Z sound card review
Good sound for those who are not satisfied with the onboard solution
September 25, 2014 / 2
Samsung Galaxy Gear: Smartwatch at High Price
The first smartwatch from Samsung - almost a smartphone with a small body
December 19, 2013 /
 
 

News Archive

 
 
SuMoTuWeThFrSa
     12
3456789
10111213141516
17181920212223
24252627282930




Poll

Do you use microSD card with your phone?
or leave your own version in comments (16)