TestStand Memory Leak Calling New Threads

Updated Jul 11, 2018

Reported In

Software

  • TestStand

Issue Details

When I run my TestStand sequence that calls sub-sequences in new threads, I see a memory leak associated with the TestStand Sequence Editor application. How do I fix this?

Solution

This behavior can occur when you call a large number of sub-sequences using the Use New Thread execution option on the sequence call step. By default, TestStand monitors all new threads created by an execution to ensure they close properly at the end of the execution. If you create a large number of new threads with this option enabled, it can cause memory to build up.

To disable this monitoring:
  1. Open the Sequence Call Advanced Settings window
  2. Uncheck the option Automatically Wait for the Thread to Complete

Additional Information

If you disable this automatic monitoring, you should implement some mechanism in the sequence to ensure the threads are not left running at the end of the execution. You can use the TestStand Wait Step for example to wait until a thread is finished executing.

WAS THIS ARTICLE HELPFUL?

Not Helpful