itunes, and all mac audio players, are processor hungry becuase macs don't use a separate sound card (like peecees do). so the encoding/decoding of the music files is done on the proc and that takes cycles. if you find itunes is overstepping its bounds, you can alter its nice value [nice values tell the kernel what priority to give processes]. in terminal, type: `ps aux | grep iTunes.app`. (note, you may have to widen the terminal window a bit for that command). the first number printed is the "process id". the next command to type is `renice +1 PROCESSID`, replacing "PROCESSID" with the number you found in the first command. if you repeat the renice step several times, iTunes will gain a high nice value (up to positive 20), and consequently will use less proc time. unfortunately, you have to do this everytime you quit/relaunch iTunes. if you want to return iTunes to its normal nice-ness, use `sudo renice 0 PROCESSID` (note: sudo may require you to type in an administrator's password).
copy and paste that into a text editor (make sure, if you use textedit, that its not saved as an rtf and that no formatting is added). save the file as "iTunesFix.command" inside your home directory. Open up terminal, and do the following command: `chmod +x ~/iTunesFix.command`. now you can move the .command file anywhere you'd like, and even add it to the login items (in sys prefs). The unfortunate part (for people who don't regularly keep terminal open) is that 2x clicking that file will open up terminal. If you wrap it inside an applescript, i think you can avoid that, but i'm not very familiar with applescript.
itunes, and all mac audio players, are processor hungry becuase macs don't use a separate sound card (like peecees do). so the encoding/decoding of the music files is done on the proc and that takes cycles. if you find itunes is overstepping its bounds, you can alter its nice value [nice values tell the kernel what priority to give processes]. in terminal, type: `ps aux | grep iTunes.app`. (note, you may have to widen the terminal window a bit for that command). the first number printed is the "process id". the next command to type is `renice +1 PROCESSID`, replacing "PROCESSID" with the number you found in the first command. if you repeat the renice step several times, iTunes will gain a high nice value (up to positive 20), and consequently will use less proc time. unfortunately, you have to do this everytime you quit/relaunch iTunes. if you want to return iTunes to its normal nice-ness, use `sudo renice 0 PROCESSID` (note: sudo may require you to type in an administrator's password).
It's not necessarily hardware acceleration. I just disabled hardware acceleration on my athlon box and winamp still averages 0% of the cpu.
Like encoders, not all decoders are created equally.
itunes, and all mac audio players, are processor hungry becuase macs don't use a separate sound card (like peecees do). so the encoding/decoding of the music files is done on the proc and that takes cycles.
I'm sure someone can come up with an even longer script that is even more useless.
Until then, try renice 20 pid (but honestly, it's a bad idea to lower itunes' priority)
i thought i had read that regular users could only increment their nice values one value at a time. i didn realize they could skip up to 20.
Quote:
complete bullcrap.
are you trying to imply that macs do have separate sound cards?
Quote:
It's not necessarily hardware acceleration. I just disabled hardware acceleration on my athlon box and winamp still averages 0% of the cpu.
Like encoders, not all decoders are created equally.
well, that's the reason i always heard relating to iTunes proc percentage. if a sound card isn't working on the sound and the proc isn't working on the sound, then what is?
i thought i had read that regular users could only increment their nice values one value at a time.
You can't do that.
renice +1 pid
renice +1 pid
renice +1 pid
renice +1 pid
renice +1 pid
renice +1 pid == renice 1 pid (absolute number)
No -n support and we're not on linux either...
"monotonic increment" doesn't mean one by one, it just means that you can't lower the number unless you are a superuser.
Quote:
Originally posted by thuh Freak
are you trying to imply that macs do have separate sound cards?
I'm trying to imply that:
a) While PCs had separate sound cards since ever (btw this has been changing recently) only 2 years or so ago mp3 hardware decoding capable cards came to market. Playing an mp3 on a two year old Athlon system (no hw support) uses almost no CPU.
b) It's not impossible to develop hardware acceleration just because the Mac's sound chips aren't on a PCI card.
-> Whether the audio stuff is on a separate PCI card or not has nothing to do with hardware acceleration whatsoever.
However this is not really the point at all.
mpg123 uses 5% (and I don't think much altivec optimization went into that one) while itunes uses 10-15% to play the same song. Now that's the point.
Yep. It's combination of a higher quality but less optimized algorithm running on a slower clockspeed processor that only has one FPU vice two. Raw cycles are a HUGE difference here, not to mention getting to do twice as much work per cycle. It's like boxing with both hands tied behind your back, but baby you've got the nicest [no pun intended!] gloves on back there!
1) So why isn't it optimized? Altivec has 4x single precision FP (or whatever is used to decompress mp3).
2) I think you misunderstood me. mpg123 (no altivec) uses 5% while AT THE SAME TIME ON THE SAME MACHINE itunes uses 10% with quality enhancments and equalizer TURNED OFF.
It uses an altivec optimized mpg123 library and uses 2% CPU. It even has a very simple GUI which means that the app has to listen for events etc. just like iTunes, unlike CL mpg123.
So what's with the other 8%? iTunes probably uses them to do the song name scrolling...
Comments
Regards,
Peter
Regards,
Peter
Originally posted by equinox
My iTunes takes up to 10-15% of CPU Power while playing an MP3 tune on my iMac 1GHz machine. Is this normal? Seems a bit too high?!
Regards,
Peter
Seems that mine wakes up a lot too and takes up at least 32 mb of ram when playing a good song and using the graphic thing.
Originally posted by equinox
thats sound logical to me. \ isn't it possible to make startup-script fot that? Sorry for my ignorance, but i switched to Mac few days ago..
Regards,
Peter
you can actually make a script for it (not necessarily a startup script). here's a version written in sh:
#!/bin/sh
/usr/bin/open /Applications/iTunes.app/
pid=`/bin/ps aux | /usr/bin/grep "iTunes.app" | /usr/bin/grep -v "grep" | cut -b "7-14"`;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
exit 0;
copy and paste that into a text editor (make sure, if you use textedit, that its not saved as an rtf and that no formatting is added). save the file as "iTunesFix.command" inside your home directory. Open up terminal, and do the following command: `chmod +x ~/iTunesFix.command`. now you can move the .command file anywhere you'd like, and even add it to the login items (in sys prefs). The unfortunate part (for people who don't regularly keep terminal open) is that 2x clicking that file will open up terminal. If you wrap it inside an applescript, i think you can avoid that, but i'm not very familiar with applescript.
Mine fluctuates between 7% and 13%, occasionally spiking to about 20%.
This is with the equalizer on... no visualization, though.
Originally posted by thuh Freak
itunes, and all mac audio players, are processor hungry becuase macs don't use a separate sound card (like peecees do). so the encoding/decoding of the music files is done on the proc and that takes cycles. if you find itunes is overstepping its bounds, you can alter its nice value [nice values tell the kernel what priority to give processes]. in terminal, type: `ps aux | grep iTunes.app`. (note, you may have to widen the terminal window a bit for that command). the first number printed is the "process id". the next command to type is `renice +1 PROCESSID`, replacing "PROCESSID" with the number you found in the first command. if you repeat the renice step several times, iTunes will gain a high nice value (up to positive 20), and consequently will use less proc time. unfortunately, you have to do this everytime you quit/relaunch iTunes. if you want to return iTunes to its normal nice-ness, use `sudo renice 0 PROCESSID` (note: sudo may require you to type in an administrator's password).
It's not necessarily hardware acceleration. I just disabled hardware acceleration on my athlon box and winamp still averages 0% of the cpu.
Like encoders, not all decoders are created equally.
Originally posted by thuh Freak
itunes, and all mac audio players, are processor hungry becuase macs don't use a separate sound card (like peecees do). so the encoding/decoding of the music files is done on the proc and that takes cycles.
complete bullcrap.
Originally posted by thuh Freak
you can actually make a script for it (not necessarily a startup script). here's a version written in sh:
Code:
#!/bin/sh
/usr/bin/open /Applications/iTunes.app/
pid=`/bin/ps aux | /usr/bin/grep "iTunes.app" | /usr/bin/grep -v "grep" | cut -b "7-14"`;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
/usr/bin/renice +1 $pid;
exit 0;
I'm sure someone can come up with an even longer script that is even more useless.
Until then, try renice 20 pid (but honestly, it's a bad idea to lower itunes' priority)
Originally posted by equinox
My iTunes takes up to 10-15% of CPU Power while playing an MP3 tune on my iMac 1GHz machine. Is this normal? Seems a bit too high?!
My iTunes takes up to 10-15% of my brain's processing power while playing an MP3 tune on my iMac 1GHz machine.
It seems that this drop in overall productivity should concern users at least as much as the consumed CPU time.
Originally posted by 123
I'm sure someone can come up with an even longer script that is even more useless.
Until then, try renice 20 pid (but honestly, it's a bad idea to lower itunes' priority)
i thought i had read that regular users could only increment their nice values one value at a time. i didn realize they could skip up to 20.
complete bullcrap.
are you trying to imply that macs do have separate sound cards?
It's not necessarily hardware acceleration. I just disabled hardware acceleration on my athlon box and winamp still averages 0% of the cpu.
Like encoders, not all decoders are created equally.
well, that's the reason i always heard relating to iTunes proc percentage. if a sound card isn't working on the sound and the proc isn't working on the sound, then what is?
Originally posted by thuh Freak
i thought i had read that regular users could only increment their nice values one value at a time.
You can't do that.
renice +1 pid
renice +1 pid
renice +1 pid
renice +1 pid
renice +1 pid
renice +1 pid == renice 1 pid (absolute number)
No -n support and we're not on linux either...
"monotonic increment" doesn't mean one by one, it just means that you can't lower the number unless you are a superuser.
Originally posted by thuh Freak
are you trying to imply that macs do have separate sound cards?
I'm trying to imply that:
a) While PCs had separate sound cards since ever (btw this has been changing recently) only 2 years or so ago mp3 hardware decoding capable cards came to market. Playing an mp3 on a two year old Athlon system (no hw support) uses almost no CPU.
b) It's not impossible to develop hardware acceleration just because the Mac's sound chips aren't on a PCI card.
-> Whether the audio stuff is on a separate PCI card or not has nothing to do with hardware acceleration whatsoever.
However this is not really the point at all.
mpg123 uses 5% (and I don't think much altivec optimization went into that one) while itunes uses 10-15% to play the same song. Now that's the point.
Originally posted by AirSluf
Yep. It's combination of a higher quality but less optimized algorithm running on a slower clockspeed processor that only has one FPU vice two. Raw cycles are a HUGE difference here, not to mention getting to do twice as much work per cycle. It's like boxing with both hands tied behind your back, but baby you've got the nicest [no pun intended!] gloves on back there!
1) So why isn't it optimized? Altivec has 4x single precision FP (or whatever is used to decompress mp3).
2) I think you misunderstood me. mpg123 (no altivec) uses 5% while AT THE SAME TIME ON THE SAME MACHINE itunes uses 10% with quality enhancments and equalizer TURNED OFF.
I just came accross this player: http://www.lounging.com/monoware/tempe.html
It uses an altivec optimized mpg123 library and uses 2% CPU. It even has a very simple GUI which means that the app has to listen for events etc. just like iTunes, unlike CL mpg123.
So what's with the other 8%? iTunes probably uses them to do the song name scrolling...
Originally posted by 123
So what's with the other 8%? iTunes probably uses them to do the song name scrolling...
Correct, the display uses a lot of power.
By making the iTunes window so small that you can't see the display, it only uses half as much processor power.