Download presentation
Presentation is loading. Please wait.
Published byDeborah Hudson Modified over 8 years ago
1
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20011 Recall Objective: understand computers at machine level interested in software perspective Problem: how can we discuss / explain something that is “unknown” ? One Approach: understand the real machine how do the millions of transistors in a computer support programs? impractical! (too complex) Understanding Computers
2
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20012 Alternate Approach: learn and understand an abstract model of the computer’s behaviour emphasize only the important details/attributes have you done this in other courses? programmer’s model abstract model appropriate for explaining software at the machine level no transistor details! widely used in industry models computer as a system System: a set of components that interact to accomplish an objective Programmer’s Model
3
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20013 what are the components? how do they interact? what are the objectives? “A Computer System” Computer System Processor Memory I/O Bus Connected Devices keyboard mouse display printer disk drives communication links etc. Diagram of a Simple Computer System
4
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20014 manipulates information located in components: (processor, memory, I/O) by executing instructions information in processor held in registers processor characterized by: register set: (more later) instruction set – includes addressing modes (more later) interrupt mechanism – lets other components notify processor when “events” happen (more in 94.203!) Processor
5
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20015 holds information in cells (or “locations”) each cell has: address: a name that identifies cell contents: the information “value” held in the cell memory supports two operations: write(address, value): causes the cell identified by address to replace its contents with value (i.e. new information held in the cell = value) read(address): returns the value held as the contents of the cell identified by address (contents of the cell are not changed) Memory
6
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20016 information exchange between computer and connected devices independent I/O components associated with each connected device e.g. keyboard components are associated with the keyboard, mouse components with the mouse, etc. I/O = Input / Output
7
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20017 ports exchange information between bus and I/O components ports are identified by I/O addresses port operations: read and/or write values (not necessarily both) Note: I/O ports memory cells control ports: write values to these – control behaviour of component/device status ports: read values from these – find out about current state of component/device data port: read and/or write values of these – exchange application information (More on ports and I/O later!) Ports
8
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20018 Information plays a key role in all components in the computer system How does information exist in a computer system at the machine level? Topic for next few lectures. What sort of information needs encoding? numbers: counting numbers, integers, reals other numbers (fractions, complex, etc.) characters, strings, text graphics days, months, years (Y2K bug?) others? Information Inside Computer
9
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 20019 There are hardware limitations transistors are switched between two states (more in 257 & 267) on / off or high / low or 0 / 1 information must be encoded in 2-state values! one BInary digiT = one bit = one 2-state value possible value of a bit = 0 or 1 Information Encoding
10
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 200110 Further Complication: registers, cells and ports are built using fixed numbers of transistors values are encoded in a fixed number of bits! e.g. value that is 8-bits wide = byte finite limitations on range of values! for n-bit width 2 n different values Information Encoding (contd)
11
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 200111 How can information be represented as fixed length binary values ? Fixed length binary values Information mapping finite set! Information Encoding Problem
12
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 200112 How can information be represented as fixed length binary values? information is abstract – invented by people binary values are held in fixed width registers, cells and ports computers do not “know” about information computers deal with binary values that have been encoded (by people) to represent information ! Information Encoding Problem (contd)
13
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 200113 suppose an application must deal with day-of-the- week information (e.g. a day-timer/scheduler) must encode days of the week as binary values how many bits are needed? what values should be used? Encoding Example: Days of the Week
14
10-Sep-0194.201 - Fall 2001: copyright ©T. Pearce, D. Hutchinson, L. Marshall Sept. 200114 One Possible Day-Of-The-Week Encoding: Monday 000(binary) Tuesday 001 Wednesday 010 Sunday 110 is this the only possible encoding? would the computer “care” if a different encoding was used? who would care? Encoding Example (contd.)
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.