neural-api icon indicating copy to clipboard operation
neural-api copied to clipboard

Delphi AVX enhancements

Open mikerabat opened this issue 2 years ago • 6 comments

This request would be twofold... First it would be great if there are AVX functions for the Delphi community too. I actually started to implement the DotProduct for Delphi2010 and upwards but I have no clue how to get that back to you.

The second suggestion is to get rid of the AVX defines and let the class decide which path would be the fastest to use. E.g. the unit I wrote once on https://github.com/mikerabat/mrmath/blob/master/CPUFeatures.pas is perfectly suited for that ;)

Let me know what you think of this idea.

mikerabat avatar May 13 '22 13:05 mikerabat

I like having IFDEFS...

I'll probably be too busy to code AVX support on Delphi for the next 7 months. Open source code can always be forked... With the proper IFDEFs, it could work.

joaopauloschuler avatar May 14 '22 04:05 joaopauloschuler

If you are interested in that I can provide you Delphi units and contribute a bit to your great work. Actually I already created one that computes the dot product (as far as I can see the working horse...) for Delphi 32 and 64 bit (+Unix ABI).

And... these units include A LOT of Ifdefs ;) :D

mikerabat avatar May 16 '22 08:05 mikerabat

I actually managed to fork the repository and add the Delphi AVX enhancements... though I wasn't able to create a pull request...

anyway if you are interested in the changes check out: https://github.com/mikerabat/neural-api

mikerabat avatar Aug 01 '22 11:08 mikerabat

@mikerabat , I'm certainly interested. I'll try to figure why the pull request didn't work.

joaopauloschuler avatar Aug 02 '22 00:08 joaopauloschuler

@mikerabat , I can see plenty of coding. It will take me some time to test it in all supported environments. Most likely, I'll ask you to create a new branch with smaller commits that are easier to merge. We'll see. I'll FUP in few months from now.

joaopauloschuler avatar Aug 08 '22 17:08 joaopauloschuler

sure thing :) I'll try my best to help out.

mikerabat avatar Aug 10 '22 09:08 mikerabat