D on next-gen consoles and for game development

Marco Leise Marco.Leise at gmx.de
Thu May 23 21:11:02 PDT 2013


Am Thu, 23 May 2013 20:21:47 -0400
schrieb "Jonathan M Davis" <jmdavisProg at gmx.com>:

> At some point, we're probably going to need to 
> benchmark stuff more agressively and optimize Phobos in general more, because 
> it's the standard library. And eliminating unnecessary memory allocations 
> definitely goes along with that.
> 
> - Jonathan M Davis

On a related note, a while back I benchmarked the naive Phobos
approach to create a Windows API (wchar) string from a D
string with using alloca to convert the string on a piece of
stack memory like this: http://dpaste.1azy.net/b60d37d4
IIRC it was 13(!) times faster for ~100 chars of English text
and 5 times for some multi-byte characters.
I think this approach is too hackish for Phobos, but it
demonstrates that there is much room.

-- 
Marco



More information about the Digitalmars-d mailing list