Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- Algorithm
- DATAPATH
- react
- MIPS
- html
- web
- python
- Linux
- system
- github
- XML
- instruction
- while
- MacOS
- Pipelining
- Class
- php
- DB
- architecture
- for
- control
- data structure
- Java
- mysql
- CSS
- DS
- javascript
- function
- DoM
- computer
Archives
- Today
- Total
YYYEJI
[MIPS] ALU를 control하는 signal (Single-Clock) 본문
728x90
MIPS에는 여러 Instruction이 존재하는데,
ALU control가 어떤 값이냐에 따라 실행되는 operation이 달라집니다.
✓ ALUcontrol에 4bits가 들어가는데
① 2bits는 ALUop에서 발생시키고,
ALUop는 어떤 instruction인지에 따라 결정됩니다.
(즉, instruction의 op code를 보게 됩니다.)
lw, sw - 00
beq - 01
R type - 10
② 나머지 2bits는 instruction format에 따라서 2bits가 결정됩니다.
R type의 경우 op code만 보고 instruction을 파악하기 힘들기 때문에, function code까지 확인해야 됩니다.
↓↓↓ 아래 결과에 따라 실행되는 instructio이 달라집니다 ↓↓↓
ALU control lines | Function |
0000 | AND |
0001 | OR |
0010 | add |
0110 | subtract |
0111 | slt(set less than) |
1100 | NOR |
↑↑↑ ALU with 4 control signals ↑↑↑
다시 확인해 보겠습니다.
• ALUop에서 instruction에 따라 2bits가 발생합니다.
lw, sw - 00
beq - 01
R-type - 10
• R-type의 경우 op code만 보고 instruction을 판단하기 힘들기 때문에
function code까지 확인해야 됩니다.
• ALUop의 2bits와 필요할 경우 function code까지 확인해서 ALU control를 발생시켜 ALU가 실행됩니다.
◡̈
'Computer architectures' 카테고리의 다른 글
[MIPS] R-type Control unit (Single-Clock) (0) | 2022.11.07 |
---|---|
[MIPS] Control unit을 결정하는 Multiplexer (Single-Clock) (0) | 2022.11.07 |
[MIPS] beq Datapath (Single-Clock) (0) | 2022.11.07 |
[MIPS] sw Datapath (Single-Clock) (0) | 2022.11.07 |
[MIPS] lw Datapath (Single-Clock) (0) | 2022.11.07 |