Senin, 18 Maret 2013



Resource management

A resource handle is an identifier for a resource that is currently being accessed. Resource handles can be opaque, in which case they are often integer numbers, or they can be pointers that allow access to further information. Common resource handles are file descriptors and sockets.
A situation when a computer program allocates a resource and fails to deallocate it after use is called a resource leak. Resource tracking is the ability of an operating system, virtual machine or other program to terminate the access to a resource that has been allocated but not deallocated after use. When implemented by a virtual machine this is often done in the form of garbage collection. Without resource tracking programmers must take care of proper manual resource deallocation. They may also use the RAII technique to automate this task.
Access to memory areas is often controlled by semaphores, which allows a pathological situation called a deadlock, when different threads or processes try to allocate resources already allocated by each other. A deadlock usually leads to a program becoming partially or completely unresponsive.
Access to resources is also sometimes regulated by queuing; in the case of computing time on a CPU the controlling algorithm of the task queue is called a scheduler.



Operating System Structure

The structure of the computer operating system include:

1. Process management
That operating system is responsible for activities related to the management of processes such as: creation and deletion of user processes, suspend or resume a process, provide mechanisms for for process synchronization, communication and deadlock.

2. Manajemen main memory
That operating system is responsible for activities related to memory management.

3. Management of secondary storage

the operating system is responsible for storing data permanently on the hard disk, floppy disk and more.

4. Management system I / O

the operating system provides a common device driver so that I / O operations can be uniform.

5. File management

is a collection of related information such as file management: creation, deletion and file manipulation.

6. Protection system

a mechanism that controls the right of access by the program, processors or users to resources.

7. Command Interpreter System

the operating system waiting for instructions or commands from the user / user. Instructional program that reads and interprets control statements is generally referred to as control card interpreter, command line interpreter and a UNIX shell.



Operating System OverviewWhat is the process in the operating system?an activity that is strongly influenced by previous executions, status, and a number of system resources
Model operating systems whichever requires the existence of timing and synchronization?

    
Siste multiprogramming
    
Timesharing system
    
Real time transaction system
What is the difference between timesharing system with real time transaction system?timesharing system can serve a wide variety of application programs according to the needs of the user, while the only real time transaction system can serve multiple types of applications only.
Any problems that may occur in the process?

    
Synchronization is not appropriate
    
Failure mutual exclusion
    
Execution of control program
    
Deadlock
What are the components of the process?

    
Executable programs (. Exe)
    
It matters relating to the required data
    
Process execution context or state

 
Example setting process

    
the list
    
entry process
    
process
    
the index
What explanation Virtual Memory?
 
Virtual memory is a facility provided by the OS aga a program can take advantage of some area secondary memory (hard disk) as the logical main memoryintended that some programs can be stored in memory simultaneously, so there is no vacancy at the time of a change of activity execution processIsolation of data between processes is done by giving a unique code for each processMemory sharing done in a way to overlap the virtual portion of memory that will be sharing.
What is paging?Paging is one astu memory mapping technique by dividing the process into small blocks of fixed-sized blocks called pageprogram accesses data using virtual address consists of page number and offsetevery page dapaat freely placed in memory is called dynamic mapping.
What are the advantages of paging?

    
Mapping between virtual addresses to physical addresses in the program memory can be done dynamically
    
Eliminating the need to put all the page of a process is put in memory simultaneously
Types of modern operating systems

     
Monolitic operating system kernel is implemented as a process whereby all the constituent Koponen (scheduling, file systems, networking, device drivers, memory management, etc.) to access the same address space.
    
Microkernel architecture is an operating system microkernel models teriri of 2 parts: the kernel and the server.
    
Multithreading is a process that is being executed broken down into parts small parts which run concurrent
    
Symmetric multiprocessing operating system is running there is a computer that uses more than one processor symmetry.
    
Distributed operating system is the number of computers connected through a network set up a cluster
    
Model of object-oriented operating system is being added to the kernel module is designed with object oriented methods.



SYSTEM INPUT / OUTPUT

INPUT OUTPUT SYSTEMFunction Module I / OModule I / O is a component in a computer system responsible forcontrolling an external device or more and also responsible for the exchange of data between the external device to the main memory or to register - registerCPU.Dalam realize this will require internal interface with a computer (CPU andMain memory) and interface with external devices to perform the functions - control functions.In carrying out their functions for I / O module can be divided into several categories,namely:• Control and timing.• Communication CPU.• Communication external devices.• Pem-buffer's data.• Detection error.Measures Handling I / O1. CPU check staus moduli / O Device2. I / O module sends status3. When ready, CPU requests data transfer4. I / O modules retrieve data from the device5. I / O module data transfer in a variety of output keCPU diinginakanMethod of Accessing I / O1.MemoriMapped I / OIn memory-mapped I / O, there is a single space for memory locations and device I / O. CPU register status and treat the data register I / O module as memory locations andusing the same machine instructions to access both the device memory and I / O.Konskuensinya is required for single-channel and single-channel readoutfor writing. The advantage of memory-mapped I / O is efficient in programming, but it takes up a lot of memory address space.2. Isolated I / OIn the technique of isolated I / O, to separate the memory addressing space and the addressing space for I / O. With this technique required a bus that is equipped with a channel memory plus reading and writing command line output. Advantages isolated I / Ois little instruction I / O.Method of Operating system I / O1. I / O FixedOn the I / O programmed, data is exchanged between the CPU module and I / O. CPU executes programs that provide I / O to the CPU directly, such as data transfer, sending the read or write, and monitoring devices. The weakness of this technique is the CPU will wait until the I / O operation is complete I / O module so that it will waste time, let alone CPU faster processing operations.2. I / O Instruction (Demand Driven)driven I / O allows a process not waste - waste of time. The process is CPU issued an I / O module I / O, along the order of I / O modules run I / O then the CPU will execute the command - command lainnya.Apabila I / O module has finished running the instructions given to him will interrupt the CPU that the task has been completed.3. Direct Memory Access (DMA)The technique described previously is I / O programmed and Interrupt-Driven I / O has a weakness, which is a process that occurs in the module I / O still involves CPU directly. This implies:• The rate transfer I / O operations that depend on the speed of the CPU.• Working CPU impaired because of interruptions directly.Starting from the above drawbacks, especially for handling large volume of data transfer developed better techniques, known as the Direct Memory Access (DMA). Working principle shall delegate the DMA is working CPU I / O to DMA, the CPU would only be involved early in the process to provide complete instructions on DMA and End process. Thus, the CPU can execute other processes without much annoyed by the interruption.Data Transfer1. Transfer Formata. Parallel: all bits transmitted simultaneously on the characters within a certain time limit transmissionb. Serial: data shipped sequentially in a single komnikasi line, so that the sender and receiver must share the deadline for submitting the characters into multiple sub-interval delivery
             
 
Parallel transfer is faster because it has a lot of transmission lines, but no bias is applied at a distance that is too long, because it can happen anatar channel interference2. Transfer Modea. Synchronous:
            
Speed ​​device I / 0 was varied in abundance serial data sent and turns in a period that has been applied, the transfer rate is set on the device I / O with low speedb. Asynchronous
            
The process of back and forth in the forward control signal from the sender to the receiver.Interfacing Devices I / On A tool for connecting a piranati digunakana with the CPU through the BUSn General Function:Synchronize the data transfer between CPU and device I / OFunction Details:1. Provider status of device I / O to the CPU2. Have the ability to interrupt / DMA3. Able to transfer to the device CPU instructions4. Able to serve as a buffer storage of data transfer5. Being able to test the similarity of data6. Being able to decode and encode the data7. Have special facilities: parallel to serial conversion of data, character encoding F1, F2
    
BACKSPACE, DELETE, etc.8. Provides operating status signalsStrukrur Interface:1. Register: Full (CR): recorded instructions and information in the device
    
Status (SR): record the status of the device and issue an error message
    
Data Input (S) and Data Ouput: as a data buffer for input and output operations2. BUS
    
Receiver: handle data input
    
Transciever: bidirectional data circuits to handle both input and output
    
Driver / Buffer Bus: tri state circuit that stores the information bus.System Processor I / On General Purpose computers that contain a number of channels of DMA, the CPU itself and run in paralleln Function:As a front end tool that handles every aspect of I / O and provides a controller I / O, called an I / O ChannelInstructions IOP:1. Data Transfer Instructions
    
Input (reading), Output (writing) and reading status information2. General Instructions Purpose
    
Instructions arithmetic, logic, branching (conversion, operation priorities, evaluation addresses, jump instructions)3. Full Instructions
   
Instructions for handling function device I / O special which was not involved in the data transfer example: moving head R / W to determine the location and the track record on the disc.Format Instruction IOP:1. Field Opcode: representation of the type of operation2. Field Memory address: starting address block of memory used to transfer3. Field Word Count: the number of word to be transferred4. Full Field: for functions device I / O special5. Filed Status: for the purposes of communication and record keeping.



System Memory  
System Memory (Memory) are electronic components that store instructions waiting to be executed by the processor, data needed by insruksi (command) and the results of the processed data (information). Memory chip typically consists of one or more of the other circuits in the processor board. Computer memory can be described as a whiteboard, where everyone enters the room can read and utilize the existing data without changing the composition presented. The data are processed by a computer, is still stored in the memory, and in this case the computer only reads the data and then process it. One time the data stored in computer memory, the data will remain there forever. Each time memory is full, then the data can be removed in part or in whole to be replaced with new data.Characteristics of memory systems in general:a. Location• CPUThis built-in memory is the CPU (microprocessor) and is required for all activities of the CPU. This memory called registers.• Internal (main)This memory outside the processor chip but internal to the computer system and is required by the CPU to process execution (operations) program, to be accessed directly by the processor (CPU) without any intermediate module. The internal memory is often also referred to as primary memory or main memory. The internal memory is typically used RAM media• External (secondary)This memory is external to the computer system and certainly beyond the CPU and is required to store data or instructions permanently. Memory, it is not necessary in the execution process so it can not be accessed directly by the processor (CPU). For external memory access by the CPU to go through the controller / module I / O. External memory is often also referred to as secondary memory. This memory consists of peripherals such as storage devices: disks, magnetic tape, etc..a. Capacity• Size of wordInternal and external memory capacity is usually expressed in terms of bytes (1 byte = 8 bits) or a word.• The number of wordWord length is generally 8, 16, 32 bits.
b. Transfer UnitUnit equal to the number of channels transfer data into and out of the memory module. The concept of transfer units are:• Word, a unit of the "natural" memory organization. Word size is usually equal to the number of bits used for the representation of the number and length of instruction.• Addressable units, the number of systems, units are adressable word. But there is a system by addressing the byte level. In all cases the relationship between the length of a an address and the number N adressable unit is 2A = N.• Unit of transfer, is the number of bits that are read or written into the memory at a time. In external memory, data transfer is usually larger than a word, called a block.
c. Access MethodsThere are four types of data access unit, as follows.:• Sequential accessMemory is organized into units of data, called records. Access is made in the form of specific linear sequence. Addressing information used to separate records and to assist in the search. Mechanism of read / write are shared (shared read / write mechanism), by walking towards the desired location to remove record. Record access time varies. Examples of sequential access is the access to magnetic tape.• Direct accessSuch as sequential access, direct access also make use of shared read / write mechanism, but each block and the record has a unique address based on physical location. Access is made directly to the public range (general vicinity) to reach the final location. Access time varies. Examples of direct access is the access to the disk.• Random accessEach location can be selected at random and accessed and addressed directly. The time to access a particular location does not depend on the sequence of previous access and is constant. An example is a system random access main memory.• Associative accessEach word can be searched based on its content and not by address. As in RAM, each location has its own mechanism pengalamatannya. When the search was not constantly depend on the location or previous access patterns. An example is the associative cache memory access.a. PerformanceThere are three parameters for the performance of the memory system, namely:• Access time (Access Time)For RAM, access time is the time required to perform a read or write operation. As for non-RAM, access time is the time required to perform read and write mechanism at specific locations• Cycle time (Time Cycle)The cycle time is the access time plus the transient time until the signal is lost from the channel signal or to generate return data when the data is read destructively.• Transfer rate (transfer rate)The transfer rate is the speed of transfer of data to a memory unit or transferred from the memory unit. For RAM, the transfer rate is equal to 1 / (cycle time). Meanwhile, the non-RAM, apply the following equation.:
TN = average time to read / write the number of N bits.TA = average access timeN = number of bitsR = The transfer speed, in bits per second (bps)a. Type of PhysicalThere are two types of physical memory, namely:• semiconductor memoryThis memory technology using LSI or VLSI (very large scale integration). This memory is widely used for the internal memory as RAM.• Memory magnetic surfaceThis memory is widely used for external memory that is to disk or magnetic tape.b. Physical CharacteristicsThere are two criteria that reflect the physical characteristics of memory, namely:• Volatile and non-volatileIn volatile memory, the information will be naturally broken or lost when electrical power is turned off. In addition, the non-volatile memory, so the information recorded will still be there without damage prior to the change. In this memory power is not required to retain the information. The memory is non-volatile magnetic surface. Semiconductor memory can be either volatile or non-volatile.• Erasable and Non-erasableErasable means that memory contents can be removed and replaced with other information. Semiconductor memory that is not erased and is non-volatile ROM.1. Memory HierarchyThree questions in the design of memory, that is: How much? This involves kaspasitas. How soon? This is about the time of access, and how expensive are concerned the price? Each spectrum technology has the following relationship:• The smaller the access time, greater cost per bit.• The greater the capacity, the smaller the price per bit.• The greater the capacity, the greater the access time.To get the best performance, the memory must be able to follow the CPU. This means that when the CPU is executing instructions, we do not need to stop the CPU to wait for instructions or operands. As for getting the best performance, memory becomes expensive, berkasitas relatively low, and fast access time. To obtain optimal performance, it should be a combination of a memory component technology. From the combination of the memory hierarchy can be structured as follows:Goes down the hierarchy, then the things below will occur:a) Decrease in price per bitb) Capacity buildingc) Increasing access timed) Decrease the frequency of memory access by the CPU.The key to the success of this hierarchy is a reduction in the frequency of access. The slower memory then the CPU needs to access the less. Overall the computer system will be fixed quickly but needs a large memory capacity is met.





Modern Computer Architecture
Currently, when his computer has a speed of data processing (processor clock) above 2 GHz, 64bit architecture, and secondary storage reaches Terabyte, it seems there is no more constraints on data processing in sudutpengguna Performance, individual information processing is no longer in the range of 100K to 1024MB but was much greater. The computer must be able to interact with perangjat-devices such as WiFi, Bluetooth, wireless modems, and so on.

                                                 Modern Computer Von Neumann




The main components are as follows:
* Central Processing Unit serves as the controller and processor instructions
* Memory or act as primary storage reservoir data and information.
* The input device output, serves as media receiver response / feedback from outside the computer system and deliver it back out computer systems.