September 03, 2008 Re: Array append performance 2 | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Dave | Dave: > There have been quite a few examples of contributors modifying the D runtime to improve things like array concatenation. This requires three fields in the dynamic array struct, so maybe it requires changes in several points of the front-end. >If it generally performs better and is demonstrably correct, I'm pretty sure Walter and the Tango crew would incorporate it.< It seems to work, it speeds up the code where I have used it (I'm using it more and more in my libs, it has speed up the select() two times, it contains an array append because in general you don't know how many items you filter away from the input iterable) but I am not able to demostrate it correct. Its main fault so far is that it causes MemoryOverflow if you try to add something like 200 million size_t to it. > In other words, have a go at improving the arraycat code in internal/gc/gc.d if you have the time. It's simple enough to modify and build. I'll take a look, but I presume it's not easy as you say :-) Bye, bearophile | |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply