Optimization of TFPReaderBMP.CountBits
Original Reporter info from Mantis: Bi0T1N @Bi0T1N
-
Reporter name: Bi0T1N
Original Reporter info from Mantis: Bi0T1N @Bi0T1N
- Reporter name: Bi0T1N
Description:
- The optimization is taken from the forum (see below for link reference) as it is a good idea to use the PopCnt instrinsic of the compiler.
- It also doesn't make sense to define the return value as shortint as the count can never be negative.
Additional information:
https://forum.lazarus.freepascal.org/index.php/topic,53774.msg399371.html#msg399371