Forum > LCL

Half precision floating point - wish list

(1/3) > >>

This is a wish list item. I hope that sometime in the future FP/Lazarus will add support for a relatively new half precision floating point data type. This is gaining use in high dynamic range (HDR) graphics and gaming systems. Here are some links.

This is the kind of thing I am interested in working with using FP/Lazarus.


Makes some sense...
submit it as feature request in mantis (under FPC project)

I've bee porting some c++ code to support f16 also testing OpenCL compatible half data type, results & s/c can be found @:, giving:

 half float16 opencl / native pascal ST/MT comparision on complex arithmetics:

  a * b + a - b / a;

  this is for a ryzen 7 5700G w/ embedded radeon graph  2GB RAM

  lap half opencl:    31 ms
  lap half pas   :  1078 ms
  lap half MT    :   172 ms

  ratio ST/CL: 34.7
  ratio MT/CL: 5.5

so using opencl for this kind of data type is clearly the best option,

f16 repo:

That is not really testing if you do not mention the cpu and fpu types for which the pascal code is compiled. The defaults are very conservative. (-Cp, -Cf and -Op settings)

it's on the post: "ryzen 7 5700G w/ embedded radeon graph  2GB RAM",

this is an average cpu with no specific dedicated gpu which i currently don't use, it would be interesting to see some results on some average gpu boards,

target tweaking doesn't change performance in this case.


[0] Message Index

[#] Next page

Go to full version