These are chat archives for ChaiScript/ChaiScript

Mar 2015
Andreas Reischuck
Mar 21 2015 21:17
Got ChaiScript to work with my Twofold project, unfortunately it's like 10x slower than Javascript
function invocation seems horribly complicated... constructing a std::multimap for every call seems very inefficient
Jason Turner
Mar 21 2015 22:11
hmm... I'm surprised it's 10x slower. The multimap isn't as slow as you'd think it would be. The profiling I've run doesn't show any particular hot spots right now. I do need to make another round of performance work though.
Andreas Reischuck
Mar 21 2015 23:25
I did some more testing... it seems that the QVariant handling was the source of the slowdown
Now I just use the Boxed_Value with QObjects (properties return a QVariant)... this gives a 40x speedup against Javascript
During debugging I found out, that the type conversion is called multiple times
Andreas Reischuck
Mar 21 2015 23:36
Is it possible to store converted types? eg. string x = object.value; (object value would normally give a QVariant)