On Mon, 10 Jul 2017, Felipe Monteiro de Carvalho wrote:

On Mon, Jul 10, 2017 at 12:52 PM, Michael Van Canneyt
<mich...@freepascal.org> wrote:
There is no performance improvement, rather the contrary. The generic list
works slower than the native list.

I meant that C++ templates (and maybe Pascal generics which are very
similar if I am not wrong) are faster than Java generics. Maybe it has
to do with that primitive types in Java cannot be added to generics at
all, but need to be wrapped in an object.

I also don't see why a template list would be slower than a fixed-type
one. It should be the same. Its just a copy of the same code.

The code is definitely not the same. In each case, it was measured. There is a 10% performance loss.

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

Reply via email to