TypeFunction example: ImplictConvTargets

H. S. Teoh hsteoh at quickfur.ath.cx
Wed Oct 7 14:41:18 UTC 2020


On Wed, Oct 07, 2020 at 10:10:56AM -0400, Steven Schveighoffer via Digitalmars-d wrote:
[...]
> memchr is also the secret sauce to how iopipe was able to beat Phobos
> byLine and getline.
> 
> I would like to go back to it at some point and see if it can be
> improved.
> 
> I know that part of the difference would be due to the opaque function
> call (this cannot be inlined), though perhaps memchr is an intrinsic?
[...]

I wouldn't be surprised if optimizing compilers like ldc treated it as
an intrinsic.  IIRC, ldc already recognizes memcpy as an intrinsic and
therefore knows how to inline it / substitute it with suitable
instructions in special cases, even though it's supposed to be "opaque".


T

-- 
Жил-был король когда-то, при нём блоха жила.


More information about the Digitalmars-d mailing list