[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

sun4c is NOT currently supported - but there is hope [was: Fun upgrading libc]



Hi folks,

I have to apologize, it appears that support for sun4c was actually dropped some time ago :-(. I was not able to find the direct statement, but there is a note from Ben Collins [0] making it pretty clear. My (erroneous) impression that it was still supported was coming from sarge installation manual [1], which still lists is as such. Upon further investigation it appeared that this is just cruft copied over from the old installation manual which nobody bothered to edit yet.

On the other hand, I started asking people around and it appears that in the current situation reenabling such support might be pretty simple (the famous last words!). The main problem why current binaries do not run on sun4c is because glibc is currently compiled with -mv8 gcc option, which enables the generation of SPARC v8 instructions. The only difference from the v7 instruction set (supported by sun4c) is that compiler emits the integer multiply and divide instructions (umul/udiv), which cause 'Illegal instruction' on sun4c. As I was told, there is currently only a handful of libraries optimized with -mv8 for performance reasons, the rest of the binaries is built with default v7 set. Recently a hwcap (hardware capability) feature was introduced in glibc, which basically allows to use a different libc library based on the hardware capabilities (allowing, for example, to use MMX instructions on machines which support it). One way to make it useful for sun4c is to build a libc without v8 optimization and use hwcap to make it used on sun4c machines. Another way, which is not preferrable for performance reasons, is to use the capability of modern kernels to trap and emulate umul/udiv instructions. That would probably lead to a largish performance hit.

Anyway, these are just some random thoughts I picked up from some very smart people (thanks to a bunch of them, especially Steve Langasek and Peter Samuelson, for explaining the situation to me). Unfortunately, I do not have any sun4c hardware myself to experiment, but if anyone is interested, that might be an interesting project.

[0] http://lists.debian.org/debian-sparc/2003/08/msg00027.html
[1] http://d-i.alioth.debian.org/manual/en.sparc/ch02s01.html#sparc-cpus

Best regards,

Jurij Smakov                                        jurij@wooyd.org
Key: http://www.wooyd.org/pgpkey/                   KeyID: C99E03CC



Reply to: