310 likes | 409 Views
CSC210 – Scientific Computing. Introduction to Computer Systems and Architecture. Von Neumann model. The bus model. Microcomputers. Other computers. Layered architecture. The Microprocessor.
E N D
CSC210 – Scientific Computing Introduction to Computer Systems and Architecture
The Microprocessor A microprocessor incorporates most or all of the functions of a central processing unit (CPU) on a single integrated circuit (IC). The microprocessor contains the arithmetic logic unit (ALU) and the control unit for a microcomputer. It is connected to memory and I/O by buses which carry information between the units.
Memory • Types of memory: • RAM (Read Access Memory) – usually volatile • ROM (Read Only Memory) – non-volatile • PROM (Programmable read-only memory) – Programmed once in factory • EPROM (Erasable programmable read-only memory) – Reprogrammed with exporure to ultraviolet light • EEPROM (Electrically erasable programmable read-only memory) – Electrically altered with voltage outside normal operation • Flash – Fast with high endurance EEPROM • Important: Every memory location has an address associated with it.
Virtual Memory • The program thinks it has a large range of contiguous addresses; but in reality the parts it is currently using are scattered around RAM, and the inactive parts are saved in a disk file. • Paged virtual memory: Almost all implementations of virtual memory divide the virtual address space of an application program into pages, usually of fixed size.
File System Most file systems make use of an underlying data storage device that offers access to an array of fixed-size blocks, sometimes called sectors, generally a power of 2 in size (512 bytes or 1, 2, or 4 KB are most common). The file system software is responsible for organizing these sectors into files and directories. Different file systems: fat, fat32, ntfs, ext3, xfs, reiserfs, nfs, …
Input – Output / Interrupts Interrupts: asynchronous signal from hardware indicating the need for attention or a synchronous event in software indicating the need for a change in execution. A hardware interrupt causes the processor to save its state of execution via a context switch, and begin execution of an interrupt handler. Connections: serial, parallel
Compilers A Compiler is a program that translates code of a programming language in machine code, also called object code. The object code can be executed directly on the machine where it was compiled.
Interpreters An Interpreter is a program that implements or simulates a virtual machine using the base set of instructions of a programming language as its machine language.
Databases A database is a structured collection of records or data that is stored in a computer system. Databases can take advantage of indexing to increase their speed. Databases can provide: Transactions Replication Security …
Networks A computer network is a group of interconnected computers.
The Web – Client-Server model The client-server software architecture model distinguishes client systems from server systems, which communicate over a computer network. A client-server application is a distributed system comprising both client and server software. A client software process may initiate a communication session, while the server waits for requests from any client. Peer-to-peer is another model, where peers are both clients and servers.
Data representation - numbers The binary system • Bit: single binary digit (0 or 1) • Byte: 8-digit binary number (8 bits) • Bit 0 is the low order bit or least significant bit, bit 7 is the high order bit or most significant bit of the byte. • Kilobit (Kb): 1024 bits • Kilobyte (KB): 1024 Bytes = 210 Bytes • Megabyte (MB): 1024 KB = 220 Bytes • Gigabyte, Terrabyte, Petabyte, etc. • A word is 16 bits and a double word is 32 bits.
Logical operations if you want to compute the logical AND of the following two eight-bit numbers, you would perform the logical AND operation on each column independently of the others
Integer number representations Integers: signed and unsigned Unsigned: The binary number ...00000 represents zero, ...00001 represents one, ...00010 represents two, and so on toward infinity. Signed: We can represent the negative values -128..-1 and the positive values 0..127 with a single eight bit byte. With a 16-bit word we can represent values in the range -32,768..+32,767. With a 32-bit double word we can represent values in the range -2,147,483,648..+2,147,483,647. Negative numbers are represented as Two’s complements, a notation which facilitates arithmetic operations.
Real number representations Reals: single precision and double precision FPnumber = (-1)S · (1 + Significand) · 2(Exponent - Bias)
Representation of images 1-bit 4-bit 8-bit 2 colors 16 colors 256 colors