Drive failure, ps3, other news…

It was quite a busy week, we (me and dario) eventually end up gaining full access to our lab and got all the duties our previous mentor and colleagues had at lscube.

We had been at ONU for our first webcast in Geneva. The place was quite nice and the people were absolutely great =). Once we got back in Italy we spend some time preparing the feed for storage and preparing a new release for fenice (did we tell the 1.12 was the last? well not really since felix was missing….) and felix, the live feeder.

Hopefully tomorrow I’ll set up everything for a proper release and then move to fenice-ng or fe.ng and libnemesi, while we were travelling I eventually fixed the h264 packetizer so now fe.ng can stream h264 and mp3 correctly =) Once I get also libnemesi supporting it I’ll do at least as rc snapshot. Dario worked quite hard to improve the scheduler in order not to choke on certain bad behaviours from a certain well known client…

Now I have a big news: I eventually got a ps3 =) It is japanese model sony graciously lent me for a while ^^ Sadly the label on says 100V~3.8A 50/60Hz and that means that I have to get a voltage converter… Luckily Geert pointed me a nice german shop with good prices, http://www.thiecom.de, I hope what I ordered (correcting at the last minute a product mismatch, I hope the order change email reached otherwise I’d get a 110to220 that is exactly the opposite I need…) will arrive next week since I want to check myself the new livecd and maybe complete the step by step docs.

I eventually complete the fbcompose altivectorization in cairo (check the mailing list for the patch) and hopefully now there is enough to start benchmarking it…

Now the sad news: my Alubook hd died, I’m trying to recover as much as possible and then send it for repair (this time I have a full applecare and I’m going to use fully ^^ ), so I won’t as much available as I was before for more or less 2-3 weeks, hopefully.

I guess that’s more or less all.

Building on/for Cell/SPU

One of the most annoying things I’m starting to see are bogus way to check for presence of compilers or lib for SPU support…

Since it is almost the last day of the year here the top annoying pratices list:

– misnaming: ppu- isn’t a valid prefix, powerpc64-unknown-linux-gnu- is, anyway if is the native compiler gcc would do perfectly, if isn’t someone would provide it to configure so. PLEASE AVOID PPU-

– misnaming: spu- could be a partially valid prefix, _maybe_ spu-elf- is the correct one . TREAT SPU AS A CROSS TARGET, ALWAYS.

– bad assumption: I may have a valid spu compiler but _MAYBE_ I didn’t registered elfspe or elfspe2 on binfmt so I cannot automagically run spu binaries or maybe I don’t have spufs mounted. TREAT SPU AS A CROSS TARGET, ALWAYS.

– picking cflags from env: the spu-elf-gcc and the native gcc may not share the same cflags, make sure your configure could pick CFLAGS_{powerpc,powerpc64,spu} as they fit.

– hardcoding paths: the ibm and the sony sdk are for non native system with non default cross paths, I know beside gentoo and few other crazy people nobody is using alternate paths, still since maybe native system should be expected and _maybe_ less custom paths could appear, please do not hardcode /opt/${STI_SDK}/blah as include/lib path in your applications or applications patches (like the one for lame). PLEASE KEEP THINGS CLEAN.

Here a top5, luckly there aren’t that many annoyances =)

Have a great new year.

who cares about fortran?

Ok, flamebait title….

Now with the new newlib release I’m pleased to announce that I’m just 2 steps from having a working out of box spu toolchain.

all you need currently is just to:
– patch the toolchain.eclass https://bugs.gentoo.org/show_bug.cgi?id=158495
– disable fortran useflag (since it won’t build because of a upstream issue)

and then just issue a crossdev –l 1.15.0 –g 4.3.0_alpha20061216 spu

and you’ll have a a full toolchain (including spu-elf-g++)

Many thanks to my fellow testers and to Shine for the ssh account over his box =)

spe-samples builds!

Ok, it shouldn’t be a important news in itself but creating an ebuild for it helped me getting a better idea on which are the pitfalls and issues of:

– autotools usage: probably would be better avoid that many configure and call the spu ones as they were cross building
– paths and prefixes: ppu- and plain spu- aren’t that correct IMHO and seems config.sub shares my opinion…
– forcing -m{32|64} could be wrong when you try to embed spulets in ppc{32|63} elfs
– you shouldn’t feed spu-elf-gcc with CFLAGS_ppc64 …

Hopefully I’ll try to get some of those issues clarified from upstream and/or fixed in an eclass or in the toolchain.

Cell/SPU support almost there

Ok, well I think you already know that gentoo is working pretty fine on ps3 and we are working on getting a quick install route for it (basically figure better how kboot works and make it do what we want)

Today I eventually got a shell on a ps3 and spent some time fixing the libspe2 ebuild (testing it in first person eventually =)), you can find it in my overlay, to get SPU stuff working you need the _VERY_LATEST_ gcc binutils and newlib and just issue a crossdev spu –stage3 to have a (hopefully) good toolchain.

Many thanks to Shine, that is also already starting to code something useful (that I’ll rip for mplayer once I have the time to start working on it) http://forums.ps2dev.org/viewtopic.php?t=7209

In the other news I got the efika eventually and, well, it’s _really_ tiny, I bought a 60GB hd and I start gather the rest of the components to play with it, I hope next week to assemble everything and have something to tell even about it =)

Misc news

If you check the overlaytimeline you could see some minor updates (new libspe1 and ps3pf_utils tentative ebuild)

I hadn’t written much lately but quite a lot is happening on #gentoo-ppc64 thanks to quite a lot of ps3 owners willing to help testing and to ranger and JoseJX that are preparing something interesting (I won’t tell what since we are working on that right now and probably I’ll leave Brent the pleasure to be the first writing about it once it’s ready^^).

I’m still following what’s happening in the toolchain and kernel sides and looks like all the pieces are coming together nicely.

I guess that’s all.

PS: I read on a certain site complaints about having some patches to support ps3 merged in the .20 kernel and other complaints about not having access to certain features like the gfx right now.

Well, considering how the other PowerPC consoles aren’t supported at all and how hard the Sony+IBM people are working, I’d suggest you to quit complaining and be a bit more supportive… Maybe IF the experiment goes well IBM or Sony or Toshiba could come up with more Cell based hardware for the workstation/desktop market…

step by step…

Looks like booting linux on the ps3 is more or less easy once you figure out the right kernel and the right configuration.

So far http://whitesanjuro.googlepages.com/ got the system booting first using the .16 sources while others acting as guineapig are help me figuring out what is missing and what to do about ps3 and more recent kernels.

Hopefully newlib fixes to build with gcc-fsf will get committed soon and people could start playing with spu coding using the mainline gcc.

there are two new section on powerdeveloper

http://www.powerdeveloper.org/forums/viewforum.php?f=49
http://www.powerdeveloper.org/forums/viewforum.php?f=50

I hope to get some success post and/or inquiries there =)

That’s all for today

Playstation 3!

Some lucky people in Japan got their already, us pitiful European will have to wait a bit more…

Anyway with the release some new toys had appeared already and I already started packaging them =)

Currently my overlay has already ebuilds for the spe-examples, the documentation and some updated kernel sources (arnd sources vanilla for now).

Other useful stuff are the patches to support the Playstation 3 bootloading system (that is quite interesting it itself) and obviously the boot image (provided as iso)

Congratulations to everybody responsible to this timely release, I’m looking forward new surprises (and the rest of the updated toolchain =))

(PS: if somebody with a ps3 is willing to be an early specimen^W ehm, tester for gentoo please contact me and I’ll try to produce a quick test image with the minimal stuff with the tools we have now, edit: some more at http://overlays.gentoo.org/dev/lu_zero )

Bad news = good news?

Today with the help of a lucky owner of a ps3 I managed to discover (reading the kboot script would lead to the same knowledge, note to self) that kboot is a real shell after all, so installing gentoo should be easy, BUT:

– gcc-4.1.1 seems to deplete all the memory -> I’ll provide a build of it
– glibc-2.5 needs a patch to build with gcc-4.3 (the dreaded extern inline issue)
– newlib got coded using a gcc that let you do things you shouldn’t, gcc-fsf as usual is more strict… (I hopefully fixed it already and I’ll post a patch for it soon)
– gcc-4.3 seems to be almost ok beside a nice ICE while building newlib (I’m trying to create a testcase right now)

In short, gentoo almost installed on a ps3 today, BUT I’ll have to figure out why gcc is depleting that much memory and why enabling swap isn’t helping at. [edit: swap wasn’t enabled …]

In the mean time I’ll try to build some tbz2 you could use to avoid the memory depletion issue. (note to sony, have a memory expansion for non-game usage)

Digging the kboot for playstation3

Probably some of us already read about how the playstation3 firmware runs linux (the “OtherOS”)

Some insight:

1- it uses as bootloader a very minimal linux system that then loads the right kernel using the kexec call (yai!, after the gamecube the other ppc platform with kexec implemented is the playstation3…)
2- the instructions obviously are scarce and seems to point out that the provided loader has a nice script to install just one kind of distro (I’ll let the reader the exercise of guessing witch) and doesn’t seem to provide anything useful if you happen to prefer something else…
3- [update] you can access the busybox shell from kbuild and just install gentoo the usual way (suggested using recent ppc64 stage3 and then build a cell-sources kernel using the cell_defconfig)

The kboot is quite neat in itself: it has a great deal of features (like ssh or tftp) and uses pretty standard tools (busybox, linux, kexec-tools, dropbear) plus something specific (the ps3pf-utils).

I’ll add the ps3pf-utils once I have them mirrored on powerdeveloper and maybe adding an unofficial svn/git for it and libspe2 (since looks like they will be improved a lot in the next weeks and keeping track fo the patches is a bit easier this way)