[fpc-devel] x86 TEST instruction
Stefan Glienke
sglienke at dsharp.org
Thu Jun 30 19:07:18 CEST 2022
Both clang and gcc seem to do this
> On 30/06/2022 17:28 CEST J. Gareth Moreton via fpc-devel <fpc-devel at lists.freepascal.org> wrote:
>
>
> This was what I was working on:
>
> https://gitlab.com/freepascal.org/fpc/source/-/merge_requests/252
>
> The same question applies regarding the TEST instruction, but it's a
> little more restrictive in this instance in that it's determined that
> the program doesn't care about the upper bytes of the register once the
> optimisation is made, so "testl $1,%ebx" is indeed the same as "testb
> $1,%bl" due to previous logic, but I am wondering if a penalty might be
> incurred due to the partial read or if this is only a concern for
> partial writes.
>
> Gareth aka. Kit
>
>
> --
> This email has been checked for viruses by Avast antivirus software.
> https://www.avast.com/antivirus
>
> _______________________________________________
> fpc-devel maillist - fpc-devel at lists.freepascal.org
> https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
More information about the fpc-devel
mailing list