Wow OrderCalcMargin() takes a long time! Might be slowing your backtests down more than you think...

 

I was calling it nearly every tick (just wanted the potential lot-size reported in a comment) and after removing it my EA back-tests about 5x faster.  Just a heads up. Thank you profiler!

Reason: