DMD is slow for matrix maths?

Etienne Cimon via Digitalmars-d digitalmars-d at puremagic.com
Sun Oct 25 19:37:16 PDT 2015


I've been playing around with perf and my web server and found 
that the bottleneck is by far the math module of Botan: 
https://github.com/etcimon/botan/blob/master/source/botan/math/mp/mp_core.d

I'm probably a bit naive but I was wishing for some inlining to 
happen. I see LOTS of CPU time spent on "pop" instructions to 
return from a simple multiply function, and the pragma(inline, 
true) was refused on all of these. So, should I wait for an 
inline? Should I import another library? Should I rewrite all the 
maths in assembly manually for each processor? Should I write 
another library that must be compiled with LDC/release for maths?

I think the best option would be for an inline feature in DMD 
that works, but I'm wondering what the stance is right now about 
the subject?


More information about the Digitalmars-d mailing list