Rockbox Technical Forums

Support and General Use => Plugins/Viewers => Topic started by: Danycacks on December 01, 2007, 06:42:27 PM

Title: RockBoy Speed
Post by: Danycacks on December 01, 2007, 06:42:27 PM
Is there a way to speed up the games on the iPod. Because there slow.
Title: Re: RockBoy Speed
Post by: zajacattack on December 01, 2007, 08:29:40 PM
To my knowledge, there is not; however, I might be mistaken.
Title: Re: RockBoy Speed
Post by: safetydan on December 01, 2007, 08:30:10 PM
If there was it'd already be done. There's room for optimisation, but no one has stepped up to do it.
Title: Re: RockBoy Speed
Post by: grossaffe on December 02, 2007, 03:37:38 AM
i'm sure if someone went to the length of overclocking their player it could be done... but that's a complete waste.
Title: Re: RockBoy Speed
Post by: Sanek on December 04, 2007, 07:53:11 PM
i'm sure if someone went to the length of overclocking their player it could be done... but that's a complete waste.

I'm actually curious - how feasible would overclocking of a 5.5g iPod by say 5-10 MHz be? I know its an embedded device and normally should not be overclocked because of possible overheating, the battery life would go down, etc.

In theory, how much can an iPod be overclocked without risking overheating?

The reasoning for this would be to get just a tiny bit more power out of the CPU when needed (only when needed mind you, to save some power), so things like RockBoy would run better.
Title: Re: RockBoy Speed
Post by: Llorean on December 04, 2007, 08:11:27 PM
Why not optimize Rockboy. I really don't like the idea of "Abuse the hardware, rather than doing the actual work needed to get things running well."

Those of you who want faster Rockboy are more than welcome to contribute patches optimizing things, but it's unlikely Rockbox will ever intentionally abuse hardware just so people don't have to work on things.
Title: Re: RockBoy Speed
Post by: zajacattack on December 04, 2007, 08:19:17 PM
Well, why not overclock? Wouldn't that give an overall performance boost?
Title: Re: RockBoy Speed
Post by: safetydan on December 04, 2007, 08:23:04 PM
The specifications that we have for these chips say that their maximum clock is 80 MHz. Do you really want to go outside that? Apart from heat and battery life issues there's also the danger of breaking the CPU in some way.
Title: Re: RockBoy Speed
Post by: zajacattack on December 04, 2007, 08:25:52 PM
Oh, so the risks end up outweighing the benefits?
Title: Re: RockBoy Speed
Post by: Llorean on December 04, 2007, 08:34:01 PM
In case the key word "abuse" didn't hand it to you on a silver platter, overclocking is a good way to cause permanent damage to the hardware.

Overclocking is not a solution, it's a way to avoid solving the problem properly. Any performance gains would be offset by an increased chance of permanent hardware failure.

Why not optimize code? Wouldn't that give performance boosts?
Title: Re: RockBoy Speed
Post by: grossaffe on December 04, 2007, 09:10:55 PM
i was simply stating it could be done, but definitely should NOT be done.  first off, i don't know of any way to do it through software (don't know if the rockbox developers could do it), which means it would have to be done with an oscillator crystal soldered to the main board, most likely not fitting in the designed case.  and on top of all of that, like previously stated, it would be a terrible strain on the chip as well of the lack of adequate cooling which would no doubt cause irreparable harm do the device.  but if you REALLY wanted that little performance boost...
Title: Re: RockBoy Speed
Post by: Llorean on December 04, 2007, 09:35:57 PM
It can be done in software fairly easily actually.
Title: Re: RockBoy Speed
Post by: Sanek on December 04, 2007, 10:36:18 PM
It can be done in software fairly easily actually.

Just a little follow-up question:
On an iPod, when CPU frequency increases, does the voltage change with it (proportionally) or is the voltage always constant?

My guess would be that it changes all the time depending on the CPU utilization as to save some energy, but is that really the case?

RockBoy was just an example since thats what the thread was about. The reasoning I had behind the overclocking question is that it would allow running more demanding applications on the same targets, but I guess it could possibly be too dangerous and ultimately not worth the risk to go beyond the specifications of the CPU - which brings me to my next question...

The specifications that we have for these chips say that their maximum clock is 80 MHz. Do you really want to go outside that? Apart from heat and battery life issues there's also the danger of breaking the CPU in some way.

According to Wikipedia, 5th Generation iPods use PortalPlayer 5022 CPU
http://en.wikipedia.org/wiki/PortalPlayer

And according to the PortalPlayer 5022 CPU Specifications in the Rockbox wiki:
Quote
Up to 100 MHz processor operation per core with independent clock-skipping feature on COP

http://www.rockbox.org/twiki/bin/viewfile/Main/PortalPlayer?rev=1;filename=5022_Brief_Mar05.pdf

So maybe there really is room for overclocking there?
Title: Re: RockBoy Speed
Post by: safetydan on December 04, 2007, 11:09:35 PM
That's one particular model. Other's in that series support lower clock rates.

As the the clock rate is software controllable, feel free to experiment. But it's something that you're doing at your own risk. A much better solution would be to optimise rockboy.
Title: Re: RockBoy Speed
Post by: Llorean on December 04, 2007, 11:35:52 PM
It's quite likely that, for most things Rockbox does (with the notable exception of Monkey's Audio music, which isn't even fast on the Gigabeat) we should be able to run them successfully at 80mhz with enough optimization.

Since we're going to *have* to do it anyway for most of the iPods, we should focus any effort on solving the problems.

As well, that wikipedia article is slightly wrong. The iPod Video uses the PP5021, which reports itself in software as a PP5022C, and we theorize that those are PP5022 chips that don't run stably at full speed.
Title: Re: RockBoy Speed
Post by: Mad Cow on December 06, 2007, 12:06:23 PM
As well, that wikipedia article is slightly wrong. The iPod Video uses the PP5021, which reports itself in software as a PP5022C, and we theorize that those are PP5022 chips that don't run stably at full speed.

If that's true then overclocking to 100mhz will be relatively safe. Remember that these chips are put through tests much more demanding than any real-world application, just to be safe. Most factory underclocked chips will be stable at the speeds of their normally-clocked parts under normal conditions. Not saying that the devs should do it, but just saying that it will be pretty safe.
Title: Re: RockBoy Speed
Post by: pixelma on December 06, 2007, 12:44:40 PM
I'd like to point the people interested in overclocking to this about 10 minutes of discussion in IRC (http://www.rockbox.org/irc/reader.pl?date=20071102#22:18:59) (starting at 22:18). The most interesting fact to me is that his two Ipod Videos behave differently.

Personally I wouldn't trust in it not damaging something, I was already a bit worried about a 1st generation Mini that had to run at the boosted CPU frequency of 75MHz (back then) all the time as long as frequency scaling didn't work correctly and had to be disabled for stability. The Ipod got really warm and the battery was eaten very quickly.
Title: Re: RockBoy Speed
Post by: Sanek on December 07, 2007, 12:35:37 AM
I'd like to point the people interested in overclocking to this about 10 minutes of discussion in IRC (http://www.rockbox.org/irc/reader.pl?date=20071102#22:18:59) (starting at 22:18). The most interesting fact to me is that his two Ipod Videos behave differently.

Personally I wouldn't trust in it not damaging something, I was already a bit worried about a 1st generation Mini that had to run at the boosted CPU frequency of 75MHz (back then) all the time as long as frequency scaling didn't work correctly and had to be disabled for stability. The Ipod got really warm and the battery was eaten very quickly.

Well considering all that, still would be nice to have some form of overclocking available. Not extreme overclocking, but considering 30GB Ipod Video runs at 80 Hz, I don't think it would really be that dangerous to overclock it to 90MHz-95MHz. Also when I say overclock, I don't mean that it would run at constant 90MHz-95MHz, I mean that the ipod cpu will have the potential to get to that frequency if needed, however work at much lower frequency under normal circumstances to save power.

You have to admit that the idea of having things like the MPEG plugin run at more watchable frame rates on iPod Video would be pretty intriguing.

Also, about the heat and battery life issue... What if you increase the frequency by a bit (like to 90MHz) and keep the stock voltage? Is the supplied voltage the one listed for 100MHz CPUs? If so, the CPU might very well be stable at higher clock rates without increasing the voltage, which removes (or at least lowers considerably) the risk of damaging the hardware.

If the CPU does run unstable, you could risk damaging the OS, however that should not be a very major problem because it can be easily fixed by replacing the rockbox folder with a fresh one.
Title: Re: RockBoy Speed
Post by: Spanky on December 07, 2007, 12:56:06 AM
I think it should be one of those advanced settings maybe put it in the debug menu so most people won't mess with it. As far as the battery is concerned you can get better batteries that last a lot longer and I think that is what should be done after you put rockbox on your ipod so you can get the most out of it. I would really like this option so maybe crossfeed and equalizer can be running at the same time.
Title: Re: RockBoy Speed
Post by: GodEater on December 07, 2007, 02:59:25 AM
*I* think that people who think they know enough to over clock their iPods safely ought to know enough to build their own version of Rockbox with whatever clock frequency they like.

We don't want a spate of people coming to our forums with smoking holes in their pockets where their iPod used to be.
Title: Re: RockBoy Speed
Post by: safetydan on December 07, 2007, 03:45:10 AM
Pretty much what GodEater said. If you want to do this, make your own build with the max clock tweaked. Just don't complain if it causes you problems. Changing the maximum clock   is not something that should ever be available in a normal build.