1 IKI10230 Pengantar Organisasi Komputer Kuliah no. 01: Pendahuluan 11 Februari 2004 L. Yohanes Stefanus Bobby Nazief bahan kuliah: Sumber: 1. Hamacher. Computer Organization, ed-5 2. Materi kuliah CS61C/2000 & CS152/1997, UCB
2 IKI10230 °Pengantar Organisasi Komputer “Mata kuliah ini mengajarkan dasar-dasar organisasi komputer sekuensial, yang terdiri dari komponen-komponen: input, output, memori, dan prosesor (kontrol dan datapath), melalui pemrograman dengan bahasa assembly.” °Prasyarat: Pengantar Sistem Digital Dasar-Dasar Pemrograman °Bobot: 3 SKS °Buku Acuan: Paul A. Carter, PC Assembly Language V. Carl Hamacher, dkk. Computer Organization. Edisi ke-5. McGraw-Hill, David Patterson & John Hennessy. Computer Organization & Design: The Hardware/Software Interface. Morgan Kaufmann Publishers, Inc.
3 Perangkat Lunak Pembantu (Tools) °NASM (Netwide Assembler) Intel x86 Assembler °GCC (GNU C Compiler) C compiler (bagian dari DJGPP) °EDEBUG32 Debuger (bagian dari DJGPP)
4 Administrasi Perkuliahan °Penilaian: Tugas:30%(4 tugas pemrograman + 4 PR) UTS:30% UAS:40% °Jadwal Kuliah: Rabu : 9:00 – 10:15, 10:30 – 11:45 WIB °Jadwal Tutorial: Senin: 13:00 – 13:50 WIB (tergantung keperluan) °Jadwal Ujian: UTS: 14 April 2004 UAS: Juni 2004
5 Rencana Perkuliahan TGLTOPIKCarterHamacher 11-FebPendahuluan, Organisasi Komputer1 18-FebStored Program Computers2.1, 2.2, 2.3, Feb Sistem Bilangan, Operasi +, Mar Assembly Language Mar Assembly Programming, Data Transfer Mar Integer Arithmetic, Micro Architecture , 7.2, Mar Control Structures, Control Unit , Mar Logical Operations 3.1, Apr Addressing Modes, Review 14-AprUTS 21-Apr Memori 5.1, 5.4, 5.5, Apr The CALL and RET Instructions 4.3, Mei Multi-Module Programs, HLL Interfacing 4.6, Mei Array/String Instructions, I/O 54.1, Mei Floating Point Arithmetic, Operasi *, / 66.3,6.6, Mei Review
6 Rencana PR & Tugas Pemorgraman TGLPRTUGAS PEMROGRAMAN 11-Feb 18-Feb#1: Organization & Stored Program Computers 25-Feb#0: Pengenalan tools 03-Mar#2: Assembly Language 10-Mar#1: Data Transfer 17-Mar#3: Micro Architecture 24-Mar#2: Arithmetic 31-Mar 07-Apr#3: Logic & Control 14-Apr 21-Apr#4: Memory 28-Apr#4: Subroutine 05-Mei 12-Mei 19-Mei#5: HLL Interface 26-Mei
7 Organisasi Sistem Komputer
8 I/O systemProcessor Compiler Operating System (Windows 98) Application (Netscape) Digital Design Circuit Design Instruction Set Architecture °Koordinasi dari berbagai tingkat “abstraksi” Datapath & Control transistors Memory Hardware Software Assembler 10230
9 Abstraksi Sistem Komputer
10 Konsep Abstraksi °Memudahkan bermacam “pengguna” memahami sistem komputer sesuai tingkat kebutuhannya (yang berbeda-beda): end-user: -menggunakan aplikasi untuk menyelesaikan tugasnya -butuh aplikasi yang merepresentasikan alat bantu penyelesaian tugasnya pemrogram aplikasi: -menggunakan development tools untuk membuat program aplikasi -butuh model sistem komputer tanpa bergantung pada jenis komputer secara spesifik pemrogram sistem: -membuat program sistem -butuh model sistem komputer tanpa bergantung pada implementasi komponen-komponen perangkat keras
11 Tingkat-tingkat Abstraksi Sistem Komputer °Application S/W MS Word computer as electronic type-writer MS Excel computer as electronic calculator °System S/W Compilers computer as translator (source to executable program) Operating Systems computer as machine that executes programs, stores files, prints content of files to printers, communicate with other computers °Instruction Set What basic operations can be carried out What, where, and how data can be stored & retrieved in/from memory How can data be exchanged to the outside “world” °Computer H/W The 5 components: Datapath, Control, Memory, Input, Output
12 Bahasa Pemrograman
13 Tingkat-tingkat Bahasa Pemrograman High Level Language Program (e.g., C) Assembly Language Program Machine Language Program (80x86) Control Signal Specification Compiler Assembler Machine Interpretation A = 25; B = 8; C = A * B; Adw 25 Bdw 8 Cresw 1 moveax, [A] movebx, [B] addeax, ebx mov[C], eax °°°° 10230
14 Java: Interpreted Programming Language Java Language Program Byte Code Machine Language Program (80x86) Control Signal Specification Java Compiler Machine Interpretation °°°° Interpreter (Java Virtual Machine) + Just In Time (JIT) Compiler
15 Java (.java) Byte Code (.class) Deskripsi Byte Code: getstatic get static field from class ldc push item from runtime constant pool invokevirtual invoke instance method return return control to the caller (
16 Sejarah Komputer
17 Generasi Komputer °I: ’46 – ’57: UNIVAC 1103 Bahasa Rakitan Vacuum Tube instruksi/detik °II: ’58 – ’64: IBM 7094 Bahasa Tingkat Tinggi (Fortran, Cobol), Kompilator Transistor I/O & Processor Parallelism instruksi/detik °III: ’65 – ’71: IBM System/360, DEC PDP-8 Sistem Operasi Small- & Medium-scale Integrated Circuit (IC) Cache & Virtual Memory, Microprogramming, Pipelining, Parallelism instruksi/detik °IV: ’72 – ’77: Apple IIe, IBM PC Large Scale Integrated Circuit (LSI) Microprocessor, PC instruksi/detik °IV: ’78 – …: – Pentium IV, MIPS, Sparc, PowerPC Very Large Scale Integrated Circuit (VLSI) instruksi/detik
18 Arsitektur Komputer
19 Komponen-komponen Komputer KEYBOARD: to input command/data MONITOR: to output data SPEAKER: to output data “CPU”: to process command & data MOUSE: to input command/data DISK: to input/output data
20 5 Komponen Utama Komputer Processor (active) Computer Control (“brain”) Datapath (“brawn”) Memory (passive) (where programs, data live when running) Devices Input Output Keyboard, Mouse Display, Printer Disk (where programs, data live when not running) “CPU”
21 Processor °Responsible of executing program stored in memory read instructions & input data execute store results (output data) °Control Unit (“otak”): interprete instruction control data transfer between registers define processsor’s ‘language’ complexity (e.g., RISC vs. CISC) °Datapath (“otot”): ALU: Aritmetic & Logical Unit Exposed register -Size of register determines processor smallest data unit (i.e., 8-bit, 16-bit, 32-bit, 64-bit computers) Hidden register
22 Memory °Responsible of storing instructions/data °Each unit of instruction/data is stored in a memory cell, whose address is known to the processor °Any memory cell can be accessed by a processor randomly (RAM: random access memory) °The amount of instruction/data accessed by a processor may vary (1, 2,..., n memory cells at a time) °To achieve trade-off between speed and cost, memory is structured hierarchically memory hierarchy
23 Input/Output (Device) °Responsible of communicating with the outside (of computer) world °A device may serve as Input-only, Output-only, or both (Input-Output) device Input-only: keyboard Output-only: monitor display Input-Output: floppy disk, hard disk °Data translation may be needed when processor exchanges data with an I/O device so humans can understand them
24 Interkoneksi Antar-komponen Komputer (1/2) Gbr. 5. (a) Tampak belakang komputer. (b) Bagian dalam komputer (tampak samping). *Diambil dari
25 Interkoneksi Antar-komponen Komputer (2/2) Proc Caches Processor-Memory Bus Memory I/O Devices: Controllers adapters Disks Displays Keyboards Networks Interconnected by a BUS I/O Bus
26 Tren Teknologi
27 Tren Teknologi: Kapasitas Mikroprosesor 2X transistors/Chip Every 1.5 years Called “Moore’s Law” Alpha 21264: 15 million Pentium Pro: 5.5 million PowerPC 620: 6.9 million Alpha 21164: 9.3 million Sparc Ultra: 5.2 million Moore’s Law Pentium 4: 42 million Pentium III: 9.5 million
28 Tren Teknologi: Kinerja Prosesor 1.54X/yr Processor performance increase/year, mistakenly referred to as Moore’s Law (transistors/chip)
29 Tren Teknologi: Kapasitas Memori (1 Chip DRAM) year size(Megabit) Now 1.4X/yr, or doubling every 2 years 4000X since 1980
30 Tren Teknologi: Kapasitas Disk Areal Density = BPI x TPI -BPI: Bit Per Inch -TPI: Tracks Per Inch Change slope 30%/yr to 60%/yr about 1991
31 Teknologi Komputer Perubahan Dramatis °Prosessor 2X lebih cepat setiap 1,5 tahun 100X lebih cepat dalam dekade terakhir °Memori Kapasitas DRAM: 2x / 2 years Kecepatan Memori: meningkat 10% per tahun Biaya per bit: membaik 25% per tahun Kapasitas meningkat 64X dalam dekade terakhir °Disk Kapasitas disk: > 2X setiap 1,0 tahun Biaya per bit: membaik 100% per tahun Kapasitas meningkat 120X dalam dekade terakhir
32 Komputer Berkinerja Tinggi (High Performance Computers)
33 Intel Pentium Pro Quad All coherence and multiprocessing glue in processor module Highly integrated, targeted at high volume Low latency and bandwidth
34 SUN Enterprise °Proc + mem card - I/O card 16 cards of either type All memory accessed over bus, so symmetric Higher bandwidth, higher latency bus
35 Cray T3E Scale up to 1024 processors, 480MB/s links Memory controller generates request message for non-local references No hardware mechanism for coherence -SGI Origin etc. provide this
36 Intel Paragon
37 IBM SP-2 °Made out of essentially complete RS6000 workstations °Network interface integrated in I/O bus (bw limited by I/O bus)
38 Berkeley NOW °100 Sun Ultra2 workstations °Inteligent network interface proc + mem °Myrinet Network 160 MB/s per link 300 ns per hop
39 Intel 80x86 Architecture
40 Intel History: ISA evolved since 1978 °8086: 16-bit, all internal registers 16 bits wide; no general purpose registers; ‘78 °8087: + 60 Fl. Pt. instructions, (Prof. Kahan) adds 80-bit-wide stack, but no registers; ‘80 °80286: adds elaborate protection model; ‘82 °80386: 32-bit; converts 8 16-bit registers into 8 32-bit general purpose registers; new addressing modes; adds paging; ‘85 °80486, Pentium, Pentium II: + 4 instructions °MMX: + 57 instructions for multimedia; ‘97 °Pentium III: +70 instructions for multimedia; ‘99 °Pentium 4: +144 instructions for multimedia; '00
41 Arsitektur Intel P6 (Pentium Pro) Control Unit Data Path
42 Contoh: Komputer Berbasis Pentium Processor/Memory Bus PCI Bus I/O Busses Memory Processor I/O