Op 24-1-2025 om 13:10 schreef Hairy Pixels via fpc-pascal:

The FPC implementation inlines if the unit-with-function-to-be-inlined
was compiled before the unit that references the inline function. That
is within the /same/ (single) build, but also has as disadvantage afaik
that if it is NOT like that, it won't be inlined.

I think that’s right. LTO is much slower too so there’s  that. I think Jonas once said in the LLVM backend it was 15% faster because of aggressive inlining.

Note that one strategy doesn't inhibit the other.

I in theory FPC could do the double build strategy to improve inlining performance further, but that would be a considerable feature of course. Both more mandatory inlining and resolving more complicated mutual inlining patterns.

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to