190 likes | 291 Views
Segmentation-1. Segment variable size block 비교 ) page or page frame fixed size block variable partition multiprogramming first-fit , best-fit, worst-fit 비교 ) fixed partition multiprogramming. Segmentation -2. Implementation of Segment table. DAT in Segmentation
E N D
Segmentation-1 • Segment • variable size block • 비교) page or page frame fixed size block • variable partition multiprogramming • first-fit , best-fit, worst-fit • 비교) fixed partition multiprogramming SunMoon University
Segmentation -2 SunMoon University
Implementation of Segment table DAT in Segmentation Virtual Address = ( s, d ) s : segment number in virtual storage d : displacement in that segment dfig 8.18 Sfig 8.23(7.19) dfig 8.19 Segment Table Base Register ( STBR ) SunMoon University
Direct Mapping in Segmentation(1) Segment Map Table Format (dfig 8.22) residence bit secondary storage address segment length protection bit starting address of that segment SunMoon University
Direct Mapping in Segmentation(2) Three types of faults 1st : check residence bit missing segment fault 2nd : check displacement <= segment length segment overflow fault 3rd : check access right segment protection fault SunMoon University
Direct Mapping in Segmentation(3) Advantage of segmentation more logical than paging easy to protection and sharing ex.) sharing in a segmentation static int array[10000]; dfig 8.23 (fig 7.21 = Sfig 8.25) SunMoon University
Direct Mapping in Segmentation(4) Placement first_fit / best_fit / worst_fit Disadvantage external fragmentation same as a dynamic stroage_allocation scheme SunMoon University
Paging and Segmentation Systems(1) Comine Paging and Segmentation each segment : multiples of page size all the pages of a segment need not be in primary stroage at once DAT V.R. = ( s, p, d ) s : segment number p : page number in the segment SunMoon University
Paging and Segmentation Systems(2) d : displacement in the page dfig 8.25 advantages easy to sharing and protection disadvantages diffcult to address mapping SunMoon University
Paging and Segmentation Systems(3) various kind of fault missing segment fault missing page fault segment overflow fault segment potection fault process table dfig 8.26 SunMoon University
Memory-Management Unit (MMU) • Hardware device that maps virtual to physical address. • MMU 기법에 의한 변환 • 기준 레지스터를 재배치 레지스터(Relocation Register) 라고 부름 • 기준 레지스터에 들어있는 값은 메모리로 보내질 때마다 모든 주소에 더해짐 • 사용자 프로그램은 논리 주소를 사용하고, 메모리 하드웨어는 논리 주소를 물리 주소로 바꿈 • 실행시간 바인딩 • 사용자 프로그램 • 단지 논리 주소(Logical Addresses)만을 만들어 냄 • 결코, 실제 물리 주소(Physical Addresses)를 보지 못함 SunMoon University