CPS 356 Lecture notes: Introduction to Operating Systems



Coverage: [OSCJ8] Chapter 1 (pp. 3-47) and [USP] Chapter 1 (pp. 3-20)


Introduction to CPS 356

logistics, evaluation, and policies


What is an operating system?

what is an operating system? a collection of programs that
  • manage computer resources (CPU, main memory, secondary memory, I/O devices)
  • provide a working environment for the user
with the following goals:
  • manage computer resources efficiently
  • make a computer system convenient to use
An OS manages a variety of system resources:
  • CPU (time)
  • main memory space
  • file storage space
  • I/O devices
An OS allocates and deallocates resources to executing programs (or processes) and may resolve conflicts.


Operating system history

  • historically, programmer was the OS
    • load program (switches, paper tape, cards)
    • set starting address
    • monitor execution
  • assemblers, linkers, and loaders eventually helped
  • compilers and high-level languages helped the programmer by providing a higher level of abstraction
  • professional operators handled job setup and execution
  • programmer debugged problems from memory dumps
  • operators grouped multiple programs with similar characteristics
  • batch system allowed no interaction between the user and the executing program
  • the biggest problem was (and still is) the discrepancy between the speed of the CPU and the speed of I/O devices; two solutions:
    • off-line processing
    • disk spooling, which often results in a group (pool) of jobs ready to run when the running job finishes


Review of computer organization


(ref. [OSIDP6] Fig. 1.1 on p. 9; image courtesy [OSIDP6] webpage)
  • von Neumann architecture
  • von Neumann bottleneck


Review of instructions (cycle & representation)


(ref. [OSIDP6] Fig. 1.2 on p. 12; image courtesy [OSIDP6] webpage)


(ref. [OSIDP6] Fig. 1.3 on p. 13; image courtesy [OSIDP6] webpage)


What happens when you power on a computer?

When a computer is powered on, a minimum amount of information is read from secondary memory into main memory and control is transferred to that area of main memory; this code reads the core of the OS, called the kernel, which executes the initial process. This process is called bootstrapping or the process of pulling oneself up by one's bootstraps.


Why study this stuff anyway?

  • the computing power (e.g., multiple cores on the desktop) is now here to render many OS concepts practical in application programming (e.g., Google Chrome or game programming)
  • gateway to studies in systems programming, parallel programming, distributed computing, and networking


Course objectives

  • Establish an understanding of operating system internals such as process creation and management, scheduling, and memory management.
  • Establish an understanding of concurrent programming and synchronization.
  • Develop a proficiency in UNIX and C as a operating systems programming language and environment.


References

    [OSCJ8] A. Silberschatz, P.B. Galvin, and G. Gagne. Operating Systems Concepts with Java. John Wiley and Sons, Inc., Eighth edition, 2010.
    [OSIDP6] W. Stallings. Operating Systems: Internals and Design Principles. Prentice Hall, Upper Saddle River, NJ, Sixth edition, 2009.
    [USP] K.A. Robbins and S. Robbins. UNIX Systems Programming: Concurrency, Communication, and Threads. Prentice Hall, Upper Saddle River, NJ, Second edition, 2003

Return Home