posted by Tony Bourke on Wed 31st Mar 2004 19:38 UTC

"FreeBSD 5.2.1 SPARC64, Page 2/3"

PCI Devices

My Sun Ultra 5 has an Intel 10/100 card installed and FreeBSD recognized it immediately as fxp0, in addition to the built-in hme0 interface. Both interfaces worked flawlessly.

Compiling

As with the SPARC64 NetBSD port, FreeBSD SPARC64 exists entirely as a 64-bit operating system, with no 32-bit userland or kernel support. Unlike NetBSD, however, this didn't become an issue. I had no trouble compiling any software, including OpenSSL, from either the ports or from source tarball.

FreeBSD 5.2.1 includes GCC 3.3.3 as the default compiler, where most of the other open source OS distributions for SPARC come with GCC 2.95. This sacrifices compile-time in some respects (in an article on O'Reilly's devnet, Marc Espie comments on GCC 3.3's longer compile times), but it gains on the fact that GCC 3.3.3 is current and generally more 64-bit friendly to the 64-bit-only FreeBSD than GCC 2.95 is (I had a few problems myself with GCC 2.95 on 64-bit NetBSD).

Since it's a 64-bit operating system, the included GCC has been adjusted to compile 64-bit binaries (-m64) by default. It also appears to use -mcpu=ultrasparc by default, as an OpenSSL run compiled with no -mcpu declaration and one with -mcpu=ultrasparc were identical. This makes sense, since FreeBSD SPARC only runs on UltraSPARC processors.

It's important to remember that the make utility included with FreeBSD is BSD version of make. Some applications require GNU's make, so you'll have to install that yourself. A common and useful convention is to install GNU's make as gmake, in order to differentiate between the two.

Performance Oddity

MySQL 4.0.17 compiled cleanly from a source tarball (yes, I know 4.0.18 is out, but to keep results consistent with the other reviews, I'm sticking with 4.0.17). While looking through MySQL's site I saw that they have a binary distribution for FreeBSD SPARC64, so I downloaded that and ran sql-bench benchmarks against that as well.

The results showed some interesting results. When compared to the results from Solaris and Linux running on the same Ultra 5, a few operations were slightly faster on FreeBSD, but many were significantly slower.


MySQL 4.0.17 results, various OSs


MySQL 4.0.17 results, various OSs (cont)

For the Linux run, I compiled a 32-bit MySQL binary and ran it on Linux kernel 2.4.24 (64-bit). Under Solaris 9, the run was a 64-bit MySQL binary that I compiled with GCC that I had recorded from earlier articles.

As you can see from the graphs, both the MySQL I compiled and the pre-compiled binary I obtained from MySQL.com exhibited similarly slow behavior.

I thought perhaps it had something to do with soft-updates, so I disabled soft-updates for the /usr partition (where the binaries and data files reside for my tests), and ran the test again with my compiled binary. The results of that run were actually slightly worse across the board.

Given that both Solaris and Linux on the same hardware where generally comparable wit each other, and much quicker in certain operations than FreeBSD, I have to conclude that there is something wrong with the SPARC port of FreeBSD to account for the slowness. Without further testing and more variables, I couldn't say what the issue is for certain, but I would hypothesis that it was something to do with the IDE driver. One way to find out would be to run these test on a system with a SCSI bus, and see if the same anomaly shows up. However, I don't have access to a SCSI-based UltraSPARC system.

Table of contents
  1. "FreeBSD 5.2.1 SPARC64, Page 1/3"
  2. "FreeBSD 5.2.1 SPARC64, Page 2/3"
  3. "FreeBSD 5.2.1 SPARC64, Page 3/3"
e p (0)    28 Comment(s)

Technology White Papers

See More