[fpc-devel] Plans for 2022
J. Gareth Moreton
gareth at moreton-family.com
Tue Jan 11 09:34:01 CET 2022
In regards to vectorisation, one of my first targets is the uComplex
unit, which uses a record type consisting of 2 Doubles to hold a complex
number and whose operator procedures are good candidates for the
'vectorcall' calling convention under Win64 (it's a little more flexible
at creating vectors than Microsoft Visual C++ is). I'll have to
double-check how good the System V ABI is for x86_64-linux when it comes
It will be interesting to see how well this unit can be vectorised under
AArch64 as well, since I'm not sure if its calling conventions can be
adapted or if we have to make a new one.
Gareth aka. Kit
On 10/01/2022 09:23, J. Gareth Moreton via fpc-devel wrote:
> I have a passion for games programming so this one really rings close
> for me. The tricky thing is that early SSE and AVX instructions have
> to fill and use the entire register - it's only AVX512 that starts to
> allow partial filling, so things like packed 3-dimensional vectors are
> a little difficult to manage. One can't just add a dummy 4th
> component because then storage won't behave as expected.
> Gareth aka. Kit
> On 10/01/2022 03:08, Ryan Joseph via fpc-devel wrote:
>>> On Jan 9, 2022, at 2:09 PM, J. Gareth Moreton via fpc-devel
>>> <fpc-devel at lists.freepascal.org> wrote:
>> Your plans are vectorization are an important gain for linear algebra
>> and games.
>> Could you detect things like:
>> a, b, c: TVec2;
>> c := a + b * V2(10, 10);
>> where the vec2 type has operator overloads for common operations?
>> This kind of thing is very common in graphics math and I bet there's
>> some clever ways you could compress that operation down. Curious how
>> the C++ compilers do this also...
>> Ryan Joseph
>> fpc-devel maillist - fpc-devel at lists.freepascal.org
This email has been checked for viruses by Avast antivirus software.
More information about the fpc-devel