顯示具有 OS 標籤的文章。 顯示所有文章
顯示具有 OS 標籤的文章。 顯示所有文章

2014年1月12日 星期日

[IOS] I/O Systems

Ch 13 I/O Systems

Ch 13.1 Overview

  • Explore the structure of an operating system’s I/O subsystem
  • Discuss the principles of I/O hardware and its complexity
  • Provide details of the performance aspects of I/O hardware and software

2014年1月11日 星期六

[IOS] Ch 12 Secondary-Storage Structure

Ch 12 Secondary-Storage Structure

  • Describe the physical structure of secondary and tertiary storage devices and the resulting effects on the uses of the devices
  • Explain the performance characteristics of mass-storage devices
  • Discuss operating-system services provided for mass storage, including RAID and HSM

[IOS] Ch 11 Implementing File-Systems

Ch 11 Implementing File-Systems

  • To describe the details of implementing local file systems and directory structures
  • To describe the implementation of remote file systems
  • To discuss block allocation and free-block algorithms and trade-offs

2014年1月10日 星期五

[IOS] Ch 10 File-System

Ch 10 File-System

  • To explain the function of file systems
  • To describe the interfaces to file systems
  • To discuss file-system design tradeoffs, including access methods, file sharing, file locking, and directory structures
  • To explore file-system protection

[IOS] Ch 9 Virtual-Memory Management

Ch 9 Virtual-Memory Management

  • To describe the benefits of a virtual memory system
  • To explain the concepts of demand paging, page-replacement algorithms, and allocation of page frames
  • To discuss the principle of the working-set model

2014年1月9日 星期四

[IOS] Ch 8 Memory Management Strategies

Ch 8 Memory Management Strategies

  • To provide a detailed description of various ways of organizing memory hardware
  • To discuss various memory-management techniques, including paging and segmentation
  • To provide a detailed description of the Intel Pentium, which supports both pure segmentation and segmentation with paging

2014年1月8日 星期三

[IOS] Ch 7 Deadlocks

Ch 7 Deadlocks

  • The Deadlock Problem
  • System Model
  • Deadlock Characterization
  • Methods for Handling Deadlocks
  • Deadlock Prevention
  • Deadlock Avoidance
  • Deadlock Detection
  • Recovery from Deadlock
  • To develop a description of deadlocks, which prevent sets of concurrent processes from completing their tasks.
  • To present a number of different methods for preventing or avoiding deadlocks in a computer system.

[IOS] Ch6 Synchronization #3

Ch 6.7 Monitors

  • Problems with Semaphores:
    • Used for 2 independent purposes
      • Mutual exclusion
      • Condition Synchronization
    • Hard to get right while coding
      • signal(mutex) … wait(mutex) : several processes may be executing in their critical sections simultaneously
      • wait(mutex) … wait(mutex) : deadlock
      • omitting of wait(mutex) or signal(mutex) (or both)
      • small mistake easily leads to deadlock / livelock
    • Separation of mutual exclusion and condition synchronization
    • Automatic wait and signal
  • To solve it, develope monitor type:
    • A high-level abstraction that provides a convenient and effective
      mechanism for process synchronization

2014年1月6日 星期一

[IOS] Ch6 Synchronization #2

Ch6.6 Classic Problems of Synchronization

  • The Bounded-Buffer Problem
  • The Readers-Writers Problem
  • The Dining-Philosophers Problem

2013年11月10日 星期日

[IOS] Ch6 Synchronization #1


A cooperating process is one that can affect or be affected by other processes executing in the system. Cooperating processes can either directly share a logical address space (that is, both code and data) or be allowed to share data only through files or messages. The former case is achieved through the use of threads, discussed in Chapter 4. Concurrent access to shared data may result in data inconsistency, however. In this chapter, we discuss various mechanisms to ensure the orderly execution of cooperating processes that share a logical address space, so that data consistency is maintained.

2013年11月9日 星期六

[IOS] Ch5 Process scheduling

Basic concept

  • In a single-processor system, only one process can run at a time
    • Any others must wait until the CPU is free and can be rescheduled.
  • Multiprogramming is to have some process running at all times to maximize CPU utilization. 
    • A process is executed until it must wait, typically for the completion of some I/O request. 
    • Several processes are kept in memory at one time, when one process has to wait, the operating system takes the CPU away from that process and gives the CPU to another process. 
    • Every time one process has to wait, another process can take over use of the CPU.
    • Scheduling of this kind is a fundamental operating-system function.
    • Almost all computer resources are scheduled before use. The CPU is, of course, one of the primary computer resources. Thus, its scheduling is central to operating-system design.

2013年11月8日 星期五

[IOS] Ch4 Multithreaded Programming


  • A thread is a basic unit of CPU utilization
  • Comprises
    • a thread ID
    • a program counter
    • a register set
    • a stack. 
  • Shares with other threads belonging to the same process
    • code section
    • data section
    • other operating-system resources(such as open files and signals)
  • A traditional (or heavyweight) process has a single thread of control.
  • If a process has multiple threads of control, it can perform more than one task at a time.
  • multiprocess 的 overhead 比 multithreaded 大

2013年11月7日 星期四

[IOS] Ch3 Process Concept


Process Concept

  • An operating system executes a variety of programs: 
    • Batch system – jobs
    • Time-shared systems – user programs or tasks
  • Textbook uses the terms job and process almost interchangeably
  • Process – a program in execution; process execution must progress in sequential fashion

2013年11月6日 星期三

[IOS] Ch2 System Structures #3


Virtual Machines

  • A virtual machine takes the layered approach to its logical conclusion. It treats hardware and the operating system kernel as though they were all hardware
  • A virtual machine provides an interface identical to the underlying bare hardware
  • The operating system host creates the illusion that a process has its own processor and (virtual memory)
  • Each guest provided with a (virtual) copy of underlying computer

2013年11月5日 星期二

[IOS] Ch2 System Structures #2

 

Types of System Calls

  • Process control
    • end, abort
    • load, execute
    • create process, terminate process
    • get process attributes, set process attributes
    • wait for time
    • wait event, signal event
    • allocate and free memory
  • File management
    • create file, delete file
    • open, close
    • read, write, reposition
    • get file attributes, set file attributes
  • Device management
    • request device, release device
    • read, write, reposition
    • get device attributes, set device attributes
    • logically attach or detach devices
  • Information maintenance
    • get time or date, set time or date
    • get system data, set system data
    • get process, file, or device attributes
    • set process, file, or device attributes
  • Communications
    • create, delete communication connection
    • send, receive messages
    • transfer status information
    • attach or detach remote devices
  • Protection

[IOS] Ch2 System Structures #1


       We can view an operating system from several vantage points. One view
focuses on the services that the system provides; another, on the interface that it makes available to users and programmers; a third, on its components and their interconnections. In this chapter, we explore all three aspects of operating systems, showing the viewpoints of users, programmers, and operating-system designers. We consider what services an operating system provides, how they are provided, how they are debugged, and what the various methodologies are for designing such systems. Finally, we describe how operating systems are created and how a computer starts its operating system.


-- Operating System Concepts 8th, by Silberschatz, Galvin, Gagne


2013年10月22日 星期二

[IOS] Ch1 Introduction note #3


Process Management

  • A process is a program in execution. It is a unit of work within the system. Program is a passive entity, process is an active entity.
  • Process needs resources to accomplish its task
    • CPU, memory, I/O, files
    • Initialization data
  • Process termination requires reclaim of any reusable resources
  • Single-threaded process has one program counter specifying location of next instruction to execute
    • Process executes instructions sequentially, one at a time, until completion
  • Multi-threaded process has one program counter per thread
  • Typically system has many processes, some user, some operating system running concurrently on one or more CPUs
    • Concurrency by multiplexing the CPUs among the processes / threads

2013年10月12日 星期六

[IOS] Ch1 Introduction note #2


Caching

  • Important principle, performed at many levels in a computer (in hardware, operating system, software)
  • Information in use copied from slower to faster storage temporarily
  • Faster storage (cache) checked first to determine if information is there 
    • If it is, information used directly from the cache (fast)
    • If not, data copied to cache and used there
  • Cache smaller than storage being cached
    • Cache management important design problem
    • Cache size and replacement policy

2013年10月11日 星期五

[IOS] Ch1 Introduction note #1


Overview

       An operating system acts as an intermediary between the user of a
computer and the computer hardware. The purpose of an operating
system is to provide an environment in which a user can execute
programs in a convenient and efficient manner.

        An operating system is software that manages the computer hard-
ware. The hardware must provide appropriate mechanisms to ensure the
correct operation of the computer system and to prevent user programs
from interfering with the proper operation of the system.