msched.exe memory keeps growing

General Macro Scheduler discussion

Moderators: Dorian (MJT support), JRL

Post Reply
MikeSr
Junior Coder
Posts: 20
Joined: Sun Feb 07, 2010 8:31 pm
Location: Fort Myers, FL
Contact:

msched.exe memory keeps growing

Post by MikeSr » Fri Feb 12, 2010 3:05 pm

Trying to understand why the memory usage keeps growing in the example below.
Note:
"MainTest" script is running and not calling the "MarcoTwo" script memory growth is nominal.
If "MainTest" is calling "MacroTwo" then the memory usage grows!
I built this quick test program to try to figure out why my actual program that I have been wrighting has been gradually slowing down as the hours pass.

"MainTest"
//*******************************
//** TEST LOOP MAIN MACRO *****
//*******************************
Let>VAREXPLICIT=0


Let>w=1
Label>Startit
If>w=100
goto Endit
Wait>0.01
Else
Let>w=w+1
Message>%w%
Wait>.01
Goto Startit
Endif

Label>Endit
Message>Calling Macro Two!
Wait>0.5
Macro>C:\Users\Mikesr\Documents\Macro Scheduler 11\MacroTwo.scp
Let>w=1
Goto>Startit

"MacroTwo"
//*******************************
//**** Macro Two *****
//*******************************

Message>Got To Macro Two !!

Not sure if I am missing somthing here.

Kind Regards

gdyvig
Automation Wizard
Posts: 447
Joined: Fri Jun 27, 2008 7:57 pm
Location: Seattle, WA

Post by gdyvig » Fri Feb 12, 2010 4:20 pm

Hi MikeSR,

I tried running your script under WindowsXP, both from the script editor and by doubleclicking MainTest.scp in Windows Explorer.

I did not see any increase in memory usage either for msched.exe or for the system overall.

Is either MainTest.scp or Macro.scp doing something besides what you posted?


Gale

MikeSr
Junior Coder
Posts: 20
Joined: Sun Feb 07, 2010 8:31 pm
Location: Fort Myers, FL
Contact:

Post by MikeSr » Fri Feb 12, 2010 4:32 pm

Did you create two seperate macros?
Macro 1 "MainTest"
Macro 2 "MacroTwo"

Macro 1 is calling Macro 2

Running just Macro 1 and commenting out the Call to Macro 2 allows the memory to remain the same.
Running it as I mentioned causes the memory to increase by 2K per program scan.

I monitor the memory usage from Windows Task Manager / Processes.
I am running Vista.

Let me know

gdyvig
Automation Wizard
Posts: 447
Joined: Fri Jun 27, 2008 7:57 pm
Location: Seattle, WA

Post by gdyvig » Fri Feb 12, 2010 4:36 pm

Yes, 2 separate macros.
Macro1 calls Macro2.
I also monitored from Windows Task Manager / Processes.
I checked for msched.exe.
Also looked to see if any other processes were growing.
msched.exe held steady.
Some other processes went up and down but did not seem to be growing long term.


Gale

MikeSr
Junior Coder
Posts: 20
Joined: Sun Feb 07, 2010 8:31 pm
Location: Fort Myers, FL
Contact:

Post by MikeSr » Fri Feb 12, 2010 5:16 pm

I ran the test programs on two differant Vista Machines.
Both yield the same result. msched.exe memory is growing.
Are you using a Vista operating system?

gdyvig
Automation Wizard
Posts: 447
Joined: Fri Jun 27, 2008 7:57 pm
Location: Seattle, WA

Post by gdyvig » Fri Feb 12, 2010 5:21 pm

We are trailing edge around here.
Using Windows XP SP3.

Anyone out there with Vista who can try out Mike's script?


Gale

MikeSr
Junior Coder
Posts: 20
Joined: Sun Feb 07, 2010 8:31 pm
Location: Fort Myers, FL
Contact:

Post by MikeSr » Fri Feb 12, 2010 5:44 pm

I installed on a XP Pro machine that I have. It initially show some memory fluxuation, but then settled down and stayed relatively steady.Some jumps occationally but then it would return to the previous memory usage value.

So..... this looks like a Vista issue!!! What a suprise !!!.

Hope Marcus can take a look at this.

matthiasR
Pro Scripter
Posts: 52
Joined: Tue Jan 20, 2004 3:45 pm
Location: Lübbecke, Germany

Post by matthiasR » Sat Feb 13, 2010 1:25 am

Hi,

i have run your scripts now for about 10 minutes under Windows Vista Ultimate. I cannot see any growing memory usage.

Regards,

Matthias

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Thu Feb 18, 2010 1:35 pm

We were able to trace this issue to a memory leak which has now been fixed in 11.1.20.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

User avatar
jpuziano
Automation Wizard
Posts: 1085
Joined: Sat Oct 30, 2004 12:00 am

Post by jpuziano » Sat Feb 20, 2010 11:52 pm

mtettmar wrote:We were able to trace this issue to a memory leak which has now been fixed in 11.1.20.
Great, thanks Marcus. And thank you very much MikeSr for taking the time to post this issue.

Memory leaks are :twisted: evil :twisted: as they threaten the stability of any macro that must stay running a long time. With this found and fixed, you have helped to improve Macro Scheduler and have benefited us all.

Here's 10 reputation points in appreciation - I hope you win a T-shirt in the next go-round, I think you've earned it.

Some folks here might think that reputation points are only for rewarding someone who has helped you solve a problem.

I think that in addition, folks who report bugs that get fixed... also deserve recognition and thanks.

What do the rest of you think? If you agree, why not show your support by throwing a few more points MikeSr's way.


Who knows, it might encourage others to report bugs they have been "living with" and if they too get fixed, things just get better for us all.

I don't see a down side there. :D
jpuziano

Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post - :-)

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts