The CPU and the fetch-execute cycle
Diperkenalkan
11:47
CPU
Prosesor di telepon Anda melakukan sesuatu yang hampir terlalu sederhana. Ambil satu instruksi. Pahami maknanya. Lakukan. Kemudian ambil instruksi berikutnya. Itu…
Narasi bahasa Inggris · takarir bahasa Inggris dan 中文 yang dapat dipilih
Dalam pelajaran ini
| English | Makna |
|---|---|
| CPU/ˌsiː piː ˈjuː/ | |
| data/ˈdeɪtə/ | Recorded facts, observations or values used for analysis or processing. |
| instructions/ɪnˈstrʌkʃnz/ | instruksi |
| ALU/ˌeɪ el ˈjuː/ | |
| control unit/kənˈtrəʊl ˈjuːnɪt/ | Unit Kontrol |
| registers/ˈredʒɪstəz/ | Register |
| buses/ˈbʌsɪz/ | Bus |
| program/ˈprəʊɡræm/ | A set of instructions specifying operations for a computer to carry out. |
| fetch–execute cycle/fetʃ ˈeksɪkjuːt ˈsaɪkl/ | The repeating process of obtaining an instruction, decoding it and carrying out the required operation. |
| logical comparisons | |
| control signals | |
| memory/ˈmeməri/ | Circuits that store data, such as registers, RAM and ROM. |
| address/əˈdres/ | An identifier specifying a location in memory or on a network. |
| chip | |
| Fetch | |
| Execute/ˈeksɪkjuːt/ | |
| PC | |
| MAR | |
| MDR | |
| CIR | |
| ACC | |
| Decode | |
| cache/kæʃ/ | |
| embedded system/emˈbedɪd ˈsɪstəm/ | Sistem Tertanam |
| cores/kɔːz/ | Processing units within a processor that can execute instruction streams. |
| cache size | |
| clock speed/klɒk spiːd/ | The number of cycles of a processor's clock per second; it alone does not determine how quickly every program runs. |
| Storage/ˈstɔːrɪdʒ/ | |
| secondary storage/ˈsekəndəri ˈstɔːrɪdʒ/ | Non-volatile storage used to retain data and programs beyond immediate processing. |
| program counter/ˈprəʊɡræm ˈkaʊntə/ | A processor register holding the address of the next instruction to fetch in the simplified CPU model. |
| address bus/əˈdres bʌs/ | The signal lines used to identify a memory location or device involved in a transfer. |
| data bus/ˈdeɪtə bʌs/ | The signal lines carrying data between processor, memory and other connected components. |
| accumulator/əˈkjuːmjʊleɪtə/ | A register used to hold intermediate arithmetic or logical results during processing. |
Unit pemroses pusat
- CPU memproses data dan menjalankan instruksi, mengulang siklus jutaan kali per detik.
- Di dalamnya terdapat ALU, unit kontrol, dan register, yang terhubung oleh bus.
- CPU menjalankan setiap program melalui siklus ambil–eksekusi.
Bagian-bagian CPU
- ALU — melakukan perhitungan dan perbandingan logika.
- Unit kontrol (CU) — mengirim sinyal kontrol untuk mengelola semua bagian.
- Register — penyimpanan kecil, sangat cepat, menampung satu nilai masing-masing.
- Tiga bus menghubungkannya ke memori: alamat (satu arah), data (dua arah), kontrol.


CPU modern adalah satu chip tunggal yang memuat unit kontrol, ALU, dan register


The ALU in a CPU:
Kesulitan 1/5 · 100 koin + bonus kecil pada penyelesaian pertama hari ini
The arithmetic logic unit does the maths and logic; the control unit manages the parts.
Register dan siklus ambil–eksekusi
- Register khusus: PC (alamat instruksi berikutnya), MAR (alamat untuk diakses), MDR (data/instruksi yang diambil), CIR (instruksi yang sedang dijalankan), ACC (hasil ALU).
- Siklus ini berulang dalam tiga tahap: Ambil (salin instruksi ke dalam CPU, lalu PC + 1) → Dekode (CU menentukan maknanya) → Eksekusi (melakukannya).

Sistem ambil–dekode–eksekusi yang diulangi CPU untuk setiap instruksi

Siklus fetch-execute
Tap round the loop the CPU repeats billions of times a second — fetch the instruction, decode what it means, execute it, then do it all again.
Match each CPU part to what it does.
Kesulitan 2/5 · 140 koin + bonus kecil pada penyelesaian pertama hari ini
The ALU computes, the control unit directs, the PC tracks the next instruction, and cache keeps hot data close.
Put the stages of the cycle in order.
Kesulitan 3/5 · 200 koin + bonus kecil pada penyelesaian pertama hari ini
Fetch the instruction, decode what it means, then execute it — repeated continuously.
Cache, kinerja, sistem tertanam
- Cache adalah sejumlah kecil memori yang sangat cepat dekat CPU, menyimpan data sering digunakan — agar CPU menunggu lebih sedikit.
- Kinerja bergantung pada jumlah core, ukuran cache, dan kecepatan clock (siklus per detik).
- Sistem tertanam adalah komputer kecil yang terpasang dalam perangkat untuk satu pekerjaan tetap (mesin cuci, microwave).

Cache dan memori utama (RAM) berada dekat CPU untuk memberikan data dengan cepat


Which change would improve CPU performance?
Kesulitan 1/5 · 100 koin + bonus kecil pada penyelesaian pertama hari ini
More cores, a larger cache and a higher clock speed all improve performance.
Cache is small, very fast memory near the CPU that holds often-used data, so the CPU waits less than it would reading from main memory.
Kesulitan 1/5 · 100 koin + bonus kecil pada penyelesaian pertama hari ini
A bigger cache, more cores and a higher clock speed all raise performance — cache helps by cutting the wait for data.
Kartu ini baru, jadi ditampilkan dalam bahasa Inggris sampai terjemahannya siap.
Worked example: one trip round the cycle
The program counter 程序计数器 (PC) holds 20. Describe how the next instruction is fetched.
- The address 20 is copied from the PC to the MAR and sent along the address bus 地址总线 to memory. The instruction stored at address 20 comes back along the data bus 数据总线 into the MDR, then is copied to the CIR.
- The PC goes up by 1, to 21, ready for the next fetch. The control unit then decodes the instruction in the CIR, and it is executed (the ALU does any calculation, with the result in the accumulator 累加器).
Which register holds the address of the next instruction to be fetched?
Kesulitan 1/5 · 100 koin + bonus kecil pada penyelesaian pertama hari ini
The PC holds the next address and is incremented after each fetch.
Doubling the number of cores always makes every program run twice as fast.
Kesulitan 1/5 · 100 koin + bonus kecil pada penyelesaian pertama hari ini
Only tasks that can be split between cores speed up, and the cores must share work and memory.
Anda telah memahaminya
- CPU = ALU (matematika/logika) + CU (sinyal kontrol) + register, terhubung melalui bus alamat/data/kontrol
- register kunci: PC (instruksi berikutnya), MAR/MDR (memori), CIR (saat ini), ACC (hasil)
- siklus: fetch → decode → execute
- kinerja: core, ukuran cache, kecepatan clock; cache = memori cepat di dekat CPU
Apa yang salah? Hanya tim situs yang dapat melihatnya.