• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to improve performance for GetBars and RemoveUnreferencedPoolbarsNow

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to improve performance for GetBars and RemoveUnreferencedPoolbarsNow

    I've been using a code performance profiler to help optimize the run time of my strategies, especially in Strategy Analyzer. When I run Strategy Analyzer (Optimizer), my CPU cores get pegged >90% - which is fine, but I'd like to make sure that they are not doing any unnecessary work.

    I've squeezed all I can out of my code and now the bottlenecks are NT system code. In particular GetBars and RemoveUnreferencedPoolbarsNow. Since these are necessary tasks in order to get data and garbage collect, I assume that nothing can be done to optimize them.

    However, I have been researching using a RAMDisk and/or SSD and was wondering if either of these would help the problem. I used a very small data set in my profile testing and Windows Task Manager does not show that the HDD is being hit when I run Strategy Analyzer and so I believe that it is pulling/cleaning data from RAM, not the disk.

    Any thoughts are appreciated whether related to RAMDisk/SSD or other ideas. Thanks.

    Side Note: A small simple piece of advice that I can offer from my work is that CurrentDayOHL is a CPU hog. It can easily be replaced by simply storing an array of Opens[x][0] for the first bar each day.

    #2
    Hi,

    I do not have any information on how to improve the performance of the methods you mentioned.

    We have not done any particular benchmarks using RAMDisk, however I know quite a few users have experimented with these sorts of tools to help improve performance. We'll leave this thread open for these users to comment on their thoughts and share any ideas they may have that will help you here.
    MatthewNinjaTrader Product Management

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Da vinci, Today, 04:19 PM
    0 responses
    8 views
    0 likes
    Last Post Da vinci  
    Started by brunoviveiros, Today, 09:36 AM
    1 response
    20 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Started by GARZONJ, Today, 11:22 AM
    1 response
    10 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by KonalGondal, Today, 10:18 AM
    1 response
    19 views
    0 likes
    Last Post NinjaTrader_Kate  
    Started by Jorge.andres.o, Today, 09:24 AM
    4 responses
    24 views
    0 likes
    Last Post NinjaTrader_PaulH  
    Working...
    X