linux on PPC

Support for HandBrake on Linux, Solaris, and other Unix-like platforms
Forum rules
An Activity Log is required for support requests. Please read How-to get an activity log? for details on how and why this should be provided.
Post Reply
hacedon
Posts: 3
Joined: Tue Oct 16, 2007 12:04 pm

linux on PPC

Post by hacedon »

is there going to be "handbrake" for PPC users, cause i think it would be really convenient if i could rip the DVD directly on the ps3 in Ubuntu or YDL and then just transfer it to the XMB-os
User avatar
s55
HandBrake Team
Posts: 9900
Joined: Sun Dec 24, 2006 1:05 pm

Post by s55 »

I certainly wouldn't get our hopes up. Whilst possible it seems unlikely since
linux ppc users (maybe ever user) are very low in numbers.

It'll probably be a case of you having to compile it yourself if you want to use it.
redraiderbum
Regular User
Posts: 132
Joined: Thu Jun 21, 2007 3:53 am

Post by redraiderbum »

I was actually wondering if it is possible to compile handbrake on PS3, I was thinking about getting one and using it as a computer. There is a new one coming out that will run around 350 I think... pretty good for a blue ray drive!

@sr55: In theory how would one optimize handbrake for the cell processor? I know ydl comes with a cell development environment do you think it would be possible to let the dev environment do it?
User avatar
s55
HandBrake Team
Posts: 9900
Joined: Sun Dec 24, 2006 1:05 pm

Post by s55 »

Wouldn't know where to begin really. I don't do that kind of work. There is a post kicking around, made recently, which someone has posted compile instructions but performance was really nothing special. Infact my Dual Core Althon 64 x2 3800 outperforms it by a fair margin. (and I call this a low end machine now)
redraiderbum
Regular User
Posts: 132
Joined: Thu Jun 21, 2007 3:53 am

Post by redraiderbum »

I was thinking that was because it HB wasn't optimized. The cell is a central processor with 7 satellites (I think maybe 8 total), and one is disabled when using linux so there would be the central processor then 6 satellites. Unfortunately, if the code is not optimized for the cell then only the central processor is used. I believe that processor is a single G5 @ 3.2 GHz so it would be hideously slow with no optimizations.

It would be great to get an optimized version, the PS3 can, afterall, pull 2 teraflops. Although, that is critical in graphics processing; is it the same for video encoding or are integer operations more important or logic? If floating isn't the most important type of operation, I suspect even optimized there would be no significant improvement.
User avatar
s55
HandBrake Team
Posts: 9900
Joined: Sun Dec 24, 2006 1:05 pm

Post by s55 »

cvk_b has been working on an optimised version for the G5 itself. Some of those optimisations could, in theory be ported.

Theres a good chance that even if all the libaries were updated to use the power of the PPC chip in the PS3 there would end up being a bottleneck somewhere else. I suspect IO (only 256MB ram and a very slow HD)
redraiderbum
Regular User
Posts: 132
Joined: Thu Jun 21, 2007 3:53 am

Post by redraiderbum »

You could, again in theory, avoid most of the IO bottlenecks by mounting an external volume via fuse or something similar on a gigabit ethernet (or fibre channel if ps3 supports that). Then just have the ps3 stream the data in for processing, then immediately back out for storage.

The satellite processors are more like dedicated graphics processors (which is why they do floating point so well), apparently it's hard to optimize for them. But when they are used fully they can, as in the folding@home project, ridiculously outperform every contemporary processor.

It's probably just a fanciful idea, but considering it already has a blu ray drive, it would be nice to be able to HD encode directly on the device without having to transfer a 20 GB single movie file. But that requires HB handle BD format also so that is ridiculously out of scope.
hacedon
Posts: 3
Joined: Tue Oct 16, 2007 12:04 pm

Post by hacedon »

sr55 wrote:I certainly wouldn't get our hopes up. Whilst possible it seems unlikely since
linux ppc users (maybe ever user) are very low in numbers.

It'll probably be a case of you having to compile it yourself if you want to use it.
but now with PS3 out the users should increase, and seriously getting linux on ps3 and NOT use "handbrake" would almost be stupid

p.s. with ubuntu 7.04 installed my ps3 uses 2 of the 7 usable cells (it shows a third CPU but its of unknown model) and i use 213.5 of the ram
redraiderbum
Regular User
Posts: 132
Joined: Thu Jun 21, 2007 3:53 am

Post by redraiderbum »

Have you tried it with YDL, it seems if anything is going to have native support it would be that distro? PPC linux is what they do.

What kind of encode times are you getting? I guess a comparison would be most helpful.

EDIT: Incidentally try this version:

http://handbrake.m0k.org/forum/viewtopic.php?t=621

It's optimized for the G5 processor which I believe is the core of the cell.
stmiller
Regular User
Posts: 59
Joined: Thu Apr 12, 2007 8:16 pm

Post by stmiller »

^That G5 version is for OS X. Not Linux. :)

I've used Handbrake for several versions now under PowerPC Linux. It compiles from source and runs great as normal. It is smp aware if you have a dual core machine.

x264 takes advantage of the altivec goodness. The new gtk Linux GUI works also.
hacedon
Posts: 3
Joined: Tue Oct 16, 2007 12:04 pm

Post by hacedon »

redraiderbum wrote:Have you tried it with YDL, it seems if anything is going to have native support it would be that distro? PPC linux is what they do.

What kind of encode times are you getting? I guess a comparison would be most helpful.
i tried YDL, i dont wanna get in to why but it suxx, the only thing better with it is WIFI-support

encode times? huh explain plz :P

im not to experienced with linux i used it for the first time when i got my ps3
redraiderbum
Regular User
Posts: 132
Joined: Thu Jun 21, 2007 3:53 am

Post by redraiderbum »

What I mean is, put in a standard encode line, and see what the fps is? I assume you are using HandBrakeCLI, put in this line with an arbitrary DVD and let it encode until it finishes:

HandBrakeCLI -i MovieFolder -o MovieName.avi -e x264 -E lame

You can delete the file afterward, just copy and post the progress line. I can tell you approximately what "typical" (x86) processor that encode speed is comparable to.
redraiderbum
Regular User
Posts: 132
Joined: Thu Jun 21, 2007 3:53 am

Post by redraiderbum »

Incidentally, when I used YDL on my ibook G4 I didn't like it either. The new Ubuntu is out also so you could try that.
thatguy
Posts: 2
Joined: Thu Oct 25, 2007 9:08 pm

Post by thatguy »

Wanted to chime in here, because I have considerable interest in getting HandBrake running quicker on PS3.

I've managed to get it running under YDL on PS3, but of course it just uses the hyperthreaded PPC core (sees 2 CPU's) and is painfully slow. Using the AppleTV settings it runs about 4 fps. Under YDL, programs have access to 3 of the Cell's SPE's. If one could alter the source to run the program on one or more SPE's, it seems that HandBrake would absolutely fly. Unfortunately, I'm no CS major so I'm not up to the task, but if I could find someone who was, there would be a high level of interest for myself and many others in a SPE-enabled build of HandBrake.
stmiller
Regular User
Posts: 59
Joined: Thu Apr 12, 2007 8:16 pm

Post by stmiller »

^This depends on projects like x264 in writing Cell optimized code, since HandBrake depends on x264 and many other projects.

Search and ask on the x264 dev mailing list, or the doom9.org forums for any news on the PS3 and x264.

I was getting 30-45FPS with x264 on my dual 2Ghz G5 with Ubuntu PowerPC. (I have since sold that machine, so I cannot test anything for the time being.)

So you *should* possibly be getting better performance than that on the PS3. I assume this is a binary that you compiled from source? And not one that someone gave you?
thatguy
Posts: 2
Joined: Thu Oct 25, 2007 9:08 pm

Post by thatguy »

I did compile this from source. I'm not aware of any HandBrake CLI packages for PPC Linux that are pre-built.

I'll search for x264 optimized for Cell though, thanks for the suggestions.
pluto7777
Posts: 3
Joined: Sun Feb 17, 2008 8:51 am

Re:

Post by pluto7777 »

thatguy wrote:I did compile this from source. I'm not aware of any HandBrake CLI packages for PPC Linux that are pre-built.

I'll search for x264 optimized for Cell though, thanks for the suggestions.
What version of Handbrake did you compile from source? I've tried 9.1 and 9.2 and both fail to link.
(This is on a Powerbook G4 not CELL)
saintdev
Regular User
Posts: 146
Joined: Wed Dec 20, 2006 4:17 am

Re: linux on PPC

Post by saintdev »

There's not really anything that the main HandBrake code can to do make it faster on a Cell. That would really be up to the encoder libraries to write code to use the SPEs, which we have no involvement in the development of. Most of the processor time is spend in the encoder libraries, not in our own code.
Post Reply