Slashdot Mirror


Darwin/Mac OS X: The Fifth BSD

LiquidPC writes: "Lance M. Westerhoff from AppleLust has written a superb article on the history of BSD. The article talks about the first versions of BSD and continues with the stories of NetBSD, OpenBSD, FreeBSD, BSDi, and it finishes off with Darwin/MacOSX."

7 of 64 comments (clear)

  1. wierd by jacobb · · Score: 3, Insightful
    Funny, how he writes a whole long lengthy article on bsd, and misspells it EVERY time. It's Berk e ley.

    Makes me wonder

  2. What about... by BSDGeek · · Score: 2, Troll

    What about ClosedBSD?

  3. Darwin strength by aphor · · Score: 5, Informative

    Darwin is a Mach kernel, which is a microkernel, based OS. Microkernels ONLY manage/arbitrate the connections between the upper half of device drivers and the IO buffer interface that software can see. The FreeBSD kernel is wrapped around Mach, rather than attatching drivers directly. As a result, the kernel (managing all kinds of goofy stuff like tables of TCP/UDP sockets in use) is preemptable by drivers that need realtime processing (like a FireWire video stream). Also, since the FreeBSD kernel layer only sees a virtual device interface, devices can be attatched and detatched at will without crashing the kernel. You can unload the device driver, recompile it, reload it, and you have just upgraded a device driver without needing to reboot. If your hardware wouldn't fry in the process, you could rip the video card out of a runnig machine, and replace it. Applications may decide to die when they get the message they are not allowed to write to the framebuffer, but then again they could be written to wait patiently...

    The same sort of technique is used to "virtualise" filesystems. So, you have Mac, Mac-extended, UFS, FAT, EXT2FS partitions on the disk, the software is insulated from the differences. It's as if everything looks like it's wrapped in an NFS mount to the OS. This may not be totally accurate on a technical level, but you should understand that there is another layer of abstraction to the Mach kernel architecture..

    Theoretically, you could have heterogenous CPUs in a system. Mach would treat them just like another device with a driver and IO to route here and there. Not that this isn't possible in other OSes, but Mach makes it much easier to do the software side.

    --
    --- Nothing clever here: move along now...
    1. Re:Darwin strength by ZigMonty · · Score: 2
      Good overview.

      For those who want to look deeper:

      The IOKit especially is very cool.

    2. Re:Darwin strength by isdnip · · Score: 2

      I understand the benefit of the microkernel, but have they fixed Mach's performance penalty? Mach was written way back when in the mid-1980s, when networking was not a priority but timesharing a host among multiple users was. So they put in nice task scheduling, but didn't put interprocess communication in the microkernel. So there's substantial overhead in communicating with the network stack. Chorus, I'm told, is a microkernel that works better on the network because of the IPC.

      While I haven't use MacOS X (Windows and Linux, basically, on my current machines), I've heard that its performance is a little slow. Could this microkernel penalty be part of the problem? Could it be fixed? (This note is not meant as a dig against MacOX X, which seems like a brilliant concept; it's a serious question.)

    3. Re:Darwin strength by aphor · · Score: 2

      I have a TiBook 667, and friends run OSX on Pizmo powerbooks. The networking has never been an issue to be quite honest. The packet handling code is all lifted from FreeBSD-3.2, which is blisteringly fast. The slowness I've heard about is in the Aqua eye-candy features like transparency and the "genie" effect. I have personally had slowness with some Carbon (The OS8/9-OSX cross compatibility framework) apps due to poor event loop handling, but that's just cooperative multitasking that hasn't been fixed in the "Carbonization" of the app.

      I am a FreeBSD person, so I have very high expectations about the multitasking performance, and I *HATE* the vestiges of classic that people leave in their apps. I have a prejudicial preference for all things Cocoa, because that means OSX preemptive multitasking ala FreeBSD (as far as performance goes).

      I regularly FTP/SFTP from OSX to sparcv9-Solaris-8 and x86 FreeBSD-STABLE. I am impressed with the performance of the little 5400 RPM 30GB HDD on my TiBook, but thus I haven't felt the network stack's influence on latency or bulk transfer speed: Mach or anything.

      --
      --- Nothing clever here: move along now...
  4. Re:Elegy for *BSD by someonehasmyname · · Score: 2, Insightful

    Too bad it's not true. Even if BSD did die, I'd still install it on all my new boxes.

    --
    Common sense is not so common.