Author Topic: considerable CPU use when idle - mac os  (Read 10299 times)

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
considerable CPU use when idle - mac os
« on: August 18, 2009, 03:49:27 PM »
using PM 4.6.1 on macbook pro 2.4 ghz, mac os 10.5.8 (was the same on 10.5.7) I have noticed that it is prone to eating quite a bit of CPU time (up to 10-15%) when sitting idle, when it's supposed to do nothing. This is not due to initial caching from freshly opened tab. It goes on all  the time PM is being run. What could be the issue, and can it be rectified somehow? Most other apps when idle fall down to decimals of one percent CPU use, so I guess something is wrong with PM here.

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: considerable CPU use when idle - mac os
« Reply #1 on: August 18, 2009, 04:43:37 PM »
using PM 4.6.1 on macbook pro 2.4 ghz, mac os 10.5.8 (was the same on 10.5.7) I have noticed that it is prone to eating quite a bit of CPU time (up to 10-15%) when sitting idle, when it's supposed to do nothing. This is not due to initial caching from freshly opened tab. It goes on all  the time PM is being run. What could be the issue, and can it be rectified somehow? Most other apps when idle fall down to decimals of one percent CPU use, so I guess something is wrong with PM here.

So far everyone that has mentioned this was not interested in running a debug logging version for us to find out what PM is doing in this case.   Are you willing to test?

-Kirk

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #2 on: August 19, 2009, 01:32:57 AM »
Kirk, thanks for prompt reply,
does your answer imply that you can not reproduce the issue on your test macs? I thought that would be easy, since it is there 99% of the running time. It is only seldom that I observed that PM drops to below 10% CPU when idle (not discussing CPU times at busy operations here). In that case sure, I am willing to help. Please provide me with info and instructions, I can run the test build for you.
thanks
Alex

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #3 on: August 19, 2009, 01:41:55 AM »
I have attached the sample of the process, and also open files and ports tab (from activity monitor) - may be it would be useful, at the time when PM was just sitting with NO contact sheets open, and happily eating 10% CPU at that.
What are those
/Applications/Photo Mechanic.app/Contents/ruby/lib/ruby/1.8/powerpc-darwin8.3.0/digest/md5.bundle
things? name of directory suggests its some sort of power pc thing? the app itself runs as intel.
thanks
alex

[attachment deleted by admin]

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: considerable CPU use when idle - mac os
« Reply #4 on: August 19, 2009, 07:13:01 AM »
Alex,

does your answer imply that you can not reproduce the issue on your test macs? I thought that would be easy, since it is there 99% of the running time. It is only seldom that I observed that PM drops to below 10% CPU when idle (not discussing CPU times at busy operations here). In that case sure, I am willing to help. Please provide me with info and instructions, I can run the test build for you.

Right, mine is sitting here using 1.00% and I have three Contact Sheet tabs open at once (all have finished loading).  However, I am running 10.4.11 instead of a Leopard version like you are.  That may be the difference.

I will work up a test build and get a link to it to you in a private message.

-Kirk

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #5 on: August 19, 2009, 07:18:06 AM »
its a bit strange that you have such old mac os version to test the current PM, and, instead of getting a current leopard box, to offload the testing tasks to customers,  :-[
but anyway, I am waiting for the logging build instructions, to do the work of quality engineers of your company.

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: considerable CPU use when idle - mac os
« Reply #6 on: August 19, 2009, 07:20:18 AM »
Alex,

I have attached the sample of the process, and also open files and ports tab (from activity monitor) - may be it would be useful, at the time when PM was just sitting with NO contact sheets open, and happily eating 10% CPU at that.
What are those
/Applications/Photo Mechanic.app/Contents/ruby/lib/ruby/1.8/powerpc-darwin8.3.0/digest/md5.bundle
things? name of directory suggests its some sort of power pc thing? the app itself runs as intel.

They're part of the scripting language that we use in Photo Mechanic for Exporters and Uploaders.  They're 'Fat Binaries' in that they have both PPC and Intel code in them.  Their pathname was originally .../powerpc-darwin8.3.0 for some reason and there was no reason to change it.  The code executing is native.

From your sample, I can see that nearly all of the threads are idle except for the main thread which appears to be doing a lot of drawing.  Do you have any of the Developer Tools installed on your system?  If so, run the Quartz Debug application and have it flash screen updates.  Then switch to PM and watch for any regions that flash yellow.

-Kirk

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: considerable CPU use when idle - mac os
« Reply #7 on: August 19, 2009, 07:22:22 AM »
Alex,

its a bit strange that you have such old mac os version to test the current PM, and, instead of getting a current leopard box, to offload the testing tasks to customers,  :-[
but anyway, I am waiting for the logging build instructions, to do the work of quality engineers of your company.

Is that really necessary?  Do you think that no one else in the company runs Leopard?

I'll try to find and reproduce this issue on my own.

-Kirk

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #8 on: August 19, 2009, 07:37:42 AM »
yes please give it a try.
and if you can not reproduce, and you feel need to investigate further, I will be happy to run the logging build on my system.
alex

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #9 on: August 19, 2009, 07:39:57 AM »
Sorry, I don't have developer tools, but I will install them if you find that you cannot reproduce the issue on your leopard mac.
alex

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: considerable CPU use when idle - mac os
« Reply #10 on: August 19, 2009, 07:42:39 AM »
Alex,

Sorry, I don't have developer tools, but I will install them if you find that you cannot reproduce the issue on your leopard mac.

No need.  I am able to reproduce it on a Leopard system.  I will debug and fix on my end.

-Kirk

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #11 on: August 19, 2009, 07:44:51 AM »
Kirk,
please keep me posted in this thread on the progress, will you?
Thanks
Alex

Offline rjp

  • Member
  • **
  • Posts: 93
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #12 on: August 19, 2009, 08:59:59 AM »
Alex,

Sorry, I don't have developer tools, but I will install them if you find that you cannot reproduce the issue on your leopard mac.

No need.  I am able to reproduce it on a Leopard system.  I will debug and fix on my end.

-Kirk


Thanks Kirk. I have also noticed this significant idle CPU activity.
btw, if would also be happy to run a test build on my mac anytime.

Rich

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: considerable CPU use when idle - mac os
« Reply #13 on: August 19, 2009, 11:47:17 AM »
Rich,

Sorry, I don't have developer tools, but I will install them if you find that you cannot reproduce the issue on your leopard mac.

No need.  I am able to reproduce it on a Leopard system.  I will debug and fix on my end.

Thanks Kirk. I have also noticed this significant idle CPU activity.
btw, if would also be happy to run a test build on my mac anytime.

I've fixed the problem in the upcoming 4.6.2 release.

Thanks.

-Kirk

Offline sunlit

  • Newcomer
  • *
  • Posts: 19
    • View Profile
Re: considerable CPU use when idle - mac os
« Reply #14 on: August 19, 2009, 11:49:43 AM »
Kirk,
that was fantastically fast!
thank you,
can you hint as to when we can expect the upcoming 4.6.2?
Alex