Writing an Operating System
for SPARC-Based Computers








This set of tutorials is intended as a supplement to the SigOps OS Tutorial. I assume the same basic knowledge of operating systems that it assumes. The purpose of this tutorial is to provide enough information such that the interested and determined reader can write an OS for a SPARC®-based computer, in my case, a SPARCstation®. Writing C code, Makefile syntax, explaining what a page table is, etc. is beyond the scope of this document; however, I will provide explanations for some of the more arcane parts of the process like manually invoking the linker and the vagaries of the SPARC architecture that will be unfamiliar to i386 programmers. Since maintaining this document is an ongoing project, if you think something is unclear, please e-mail me.

Currently, all of this information pertains to the sun4c architecture (i.e. SS SLC, ELC, IPC, IPX, 1, 1+, 2). There should not be too much difference between that and others like sun4m (i.e. SS Classic, LX, 4, 5, 10, 20), but others like sun4u (Ultra 1, 2, 5, 10, 30, 60, and friends) are of course completely different beasts. Sorry, but I only have a SS 1+. Faithful clones of sun4c machines should be fairly straightforward.

I strongly recommend that you purchase a copy of the SPARC V8 Architecture Manual from SPARC International. N.B. that V9 (the current version) of the Manual is for the ULTRASPARC family.

This tutorial is not yet complete. That is because I have yet to figure out all of the topics. They will be filled in as I learn, and my OS progresses.

I assume no responsibility for the accuracy of the information in this document, although I've tried to do my best. Use this information at your own risk. If your computer explodes into a ball of fire, it's not my fault.

So if you're still reading and are still set on writing an OS, roll up your sleeves: it's time for some serious hacking!



Table of Contents
  1. Introduction
  2. Setting Up
  3. Development Environment
  4. Debugging Methods
  5. Applications
  6. Memory Management
  7. Multitasking
  8. IPC
  9. Hardware Interrupts


References
Revision History


Writing an Operating System for SPARC-Based Computers is Copyright © 1998 by Sidney Cammeresi in its entirety. All rights reserved.

Permission is granted to make verbatim copies of this tutorial for non-commercial use provided this notice remains intact on all copies.

SPARC® is a registered trademark of SPARC International, Inc. SPARCstation® is licensed exclusively to Sun Microsystems, Inc. Products bearing SPARC trademarks are based on an architecture developed by Sun Microsystems, Inc.