Idiomatic GPGPU from .NET

BGU 1 Reputation point
2022-06-11T07:56:35.463+00:00

I've been reviewing the available OpenCL wrappers for .NET & found nothing to rejoice about. These "low-level" helpers are very non-idiomatic to the .NET programmer, e.g., from the OpenTK Compute package,

public static CLResultCode GetPlatformIds(out CLPlatform[] platformIds);  

The return type is in the wrong place & there is obviously no structured exception handling here.

Will there be a time in the foreseeable future when the compiler and/or the runtime is smart enough to run straight .NET code on the right hardware resource (CPU/GPU)? Surely someone out there must be working on this. We got the auto-parallelizing (TPL) features from Microsoft some years back so I'm sure they can pull it off.

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,221 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.