memory organization
DESCRIPTION
Memory Organization. Microprocessor and Interfacing 261313. CPU 8088 10 MHz 8/16 Bit 1M RAM. CPU 80486 66 MHz 32 Bit 8M RAM. Pentium 133 MHz 32 Bit 16M RAM. Pentium MMX 200 MHz 32 Bit 48M RAM. Pentium II 366 MHz 32 Bit 128M RAM. Pentium M 1.6 GHz 32 Bit - PowerPoint PPT PresentationTRANSCRIPT
Memory Organization
Microprocessor and Interfacing261313
CPU 8088 10 MHz 8/16 Bit1M RAM
CPU 80486 66 MHz 32 Bit8M RAM
Pentium 133 MHz 32 Bit16M RAM
Pentium MMX
200 MHz 32 Bit48M RAM
Pentium II 366 MHz 32 Bit128M RAM
Pentium M 1.6 GHz 32 Bit512M RAM
Core2 Duo 2.0 GHz 32/64 Bit4G RAM
Core i51.33 – 1.86 GHz 32/64 Bit4G RAM
What has changed the least?
0
500
1000
1500
2000
2500
CPU MHz
0
10
20
30
40
50
60
70
Bits
MHz RAM
CPU Bits
What does “Bits” mean?
A CPU “bits” is typically defined by: ALU Size
How many bits can be computed at one time?
Bus SizeHow many bits can be transferred on the bus?
Memory Address SizeHow many address bits are in the instruction?
How many bits Is this PIC CPU?
.................... int16 i;
....................
.................... i=1; 0017: BCF 03.60018: CLRF 220019: MOVLW 01001A: MOVWF 21.................... i = i+2; 001B: MOVLW 02001C: ADDWF 21,F001D: BTFSC 03.0001E: INCF 22,F
16-bit operation on a 8-bit CPUMicrochip PIC16 series
.................... int16 i;
....................
.................... i=1; 0017: BCF 03.60018: CLRF 220019: MOVLW 01001A: MOVWF 21.................... i = i+2; 001B: MOVLW 02001C: ADDWF 21,F001D: BTFSC 03.0001E: INCF 22,F
0 1
0 1
16-bit operation on a 16-bit CPUMicrochip PIC24 series.................... int16 i; .................... .................... i=1; 00210: MOV #1,W400212: MOV W4,802.................... .................... i = i+2; 00214: MOV 802,W400216: ADD W4,#2,W400218: MOV W4,802
ระบบ 32 Bit กำ��ลั�งเจอท�งตั�น?
RAM ใหญ่�ท��สุ�ดท��ระบบ 32 bit มองเห�นม�ค่��เป็�นเท��ใด?
Memory Limit of 32bit Machines
= 4 Giga Bytes
322
How to support bigger memory?
1.Upgrade to 64-bit systems
64-bit OS64-bit CPU
Limitation of moving to 64-bit systems
Need 64-bitHardware Drivers
Applicationsneed to be re-compiledwith a 64-bit compiler
How to support bigger memory?
2. Expand existing bits
วิ ธี�แกำ#ป็$ญ่ห�ของ Intel
Physical Address Extension (PAE)
4 bits 32 bits
362 = 64 GB
PAE Support
CPU with PAE(Since P-Pro)
PAE Aware OS
Benefits of PAE
Backward Compatible
Limitations
Taking advantage of the added memorystill requires changes in the software
Memory Limit of 64 Bit Machines?
?264
How big can we get?
1 kilobyte 1 megabyte 1 gigabyte 1 terabyte 1 petabyte 1 exabyte 1 zettabyte 1 yottabyte 1 xonabyte 1 wekabyte 1 vundabyte
1,024 1,048,576
1,073,741,824 1,099,511,627,776
1,125,899,906,842,624 1,152,921,504,606,846,976
1,180,591,620,717,411,303,424 1,208,925,819,614,629,174,706,176
1,237,940,039,285,380,274,899,124,224 1,267,650,600,228,229,401,496,703,205,376
1,298,074,214,633,706,907,132,624,082,305,024
264 = 18,446,744,073,709,551,616 ~ 18 exabyte
ปี�
Amount of RAM (GB) in a typical computer
About 4TBin 2025
64-Bit Architectures
IA-64 AMD 64, EM64TOr X86-64
True 64bit CPU Hybrid 32/64 bit CPU
A hybrid 32/64 bit system
Has the benefits of a 64-bit programs
Can also run older 32-bit programs
32-Bit programs will not benefit from the 64-bit architecture
Architecture not as clean as true 64-bit systems
สองเรื่�องน่�ารื่ �เกี่�ยวกี่�บหน่�วยความจำ�าของPIC Microcontroller
1. When Memory Grows Beyond Anticipation (เม�อหน่�วยความจำ�าขยายโตเกี่�น่คาด)
1.1 กี่ารื่อ�างอ�งต�าแหน่�งใน่ Flash Memory
0x500 ค�าส�ง0x501 CALL 0x900
… …
0x900 ค�าส�งถั�ดไปี
What is wrong with this call command?
K = 11 bitMaximum memory = 2^11 = 2K Bytes
PIC 16F877 has 8K Flash Memory: How do we access all of it?
PCLATH (F# 0x0A)
Bit 3-4 in PCLATH are usedfor memory access
07
Total Memory becomes 2^13 = 8K Bytes
4 3
Creating a 13 bit memory address
PCLATH
07
01012
CALL or GOTO k (Literal)
0101113
13 Bit Memory Address
OPCODE
4 3
PIC Flash Memory is Divided in to
4 Pages of 2KBytes
2K2K2K2K
01012
0x500 ค�าส�ง0x501 CALL 0x900
… …
0x900 ค�าส�งถั�ดไปี
Fix this program
Address 0x900 exceeds 11 bits
0 1 0 101012
0x900 = 0 0 0 0 0 0 0 00
0x1000x01
0x4FF BCF PCLATH, 4
0x500 BSF PCLATH, 3
0x501 CALL 0x100
… …
0x900 ค�าส�งถั�ดไปี
0 1 0 101012
0x900 = 0 0 0 0 0 0 0 00
0x1000x01