"Pintos" Operating System, Sogang University, 2019 Fall Season (PRJ1-PRJ3)
์ฌ์ฉ์์ ์ํ ๊ธฐ๋ณธ ๋ช ๋ น์ ๋ํด ํ๋ก๊ทธ๋จ์ ์คํ ํ๊ฒฝ์ ๊ตฌ์ถํ๋ ๊ฒ์ด ์ด๋ฒ ํ๋ก์ ํธ์ ๋ชฉํ์ด๋ค. ๊ฐ๋ฐ ์ ๊ธฐ์กด Pintos์๋ System call, System call handler, Argument passing, User stack์ด ๊ตฌํ๋์ด ์์ง ์์ Pintos๊ฐ ์ฌ์ฉ์ ํ๋ก๊ทธ๋จ์ ์คํํ ์ ์๋ค. Argumemnt passing์ ํตํด ์ฌ์ฉ์ ํ๋ก๊ทธ๋จ์ mutiple arguments๋ฅผ ๋ถ์ํ์ฌ ๋ฉ๋ชจ๋ฆฌ์ ํ ๋นํ๋ ๊ธฐ๋ฅ๊ณผ, ์ ํจํ์ง ์์ ํฌ์ธํฐ๋ฅผ ์ด๋ป๊ฒ ๋์ฒํ ์ง ์ฒ๋ฆฌํ๋ ๊ธฐ๋ฅ๊ณผ, ์ฌ์ฉ์์ ๋ช ๋ น์ ๋ฐ๋ผ ๊ฐ๊ฐ ๊ธฐ๋ฅ์ ์ํํ๋ System call handler์ ๊ธฐ๋ฅ๊ณผ, ์ถ๊ฐ์ ์ธ ๊ธฐ๋ฅ(fibonacci, sum of four int)์ ์ถ๊ฐํ ๊ฒ์ด๋ค.
Project1์์ ๊ตฌํํ ์ฝ๋๋ฅผ ์์ ํด ํ์ผ ์์คํ ๊ด๋ จ ์์คํ ์ฝ์ ์์ฑํ๋ค. Project1์์ STDIN, STDOUT์ ๋ํด์๋ง ๊ตฌํํ์ง๋ง, ์ด๋ฅผ ํ์ฅํ๋ค. ๋ํ project1์์ busy waiting์ผ๋ก ๊ตฌํํ ์๊ณ๊ตฌ์ญ๋ฌธ์ ๋ฅผ Lock๊ณผ Semaphore๋ก ์์ ํ๋ค.
Project 1, 2์์ ์ฌ์ฉ์์ ๋ช ๋ น์ ์ํํ๋ ๋๋ถ๋ถ์ ๊ธฐ๋ฅ์ ๊ตฌํํ๋ค. Pintos์ ๊ฒฝ์ฐ ๊ธฐ๋ณธ์ ์ผ๋ก round-robin ๋ฐฉ์์ผ๋ก scheduling์ ์คํํ๋๋ฐ, ์ด๋ thread์ ์ฐ์ ์์๋ฅผ ๋ฐ์ํ์ง ๋ชปํ๋ค. ๋ฐ๋ผ์ ์ด๋ฒ project 3์์๋ thread์ ์ฐ์ ์์๋ฅผ ๋ฐ์ํ๋ process scheduling์ ๊ตฌํํ๋ค. ์ด๋ฅผ ์ํด thread์ ์ฌ๋ฌ synchronization ๊ธฐ๋ฒ์ด ํ์ฉ๋๋ค. Semaphore, lock๋ฑ์ ๊ธฐ๋ฒ์ ํตํด synchronization์ ๊ตฌํํ๊ณ , ์ถ๊ฐ์ ์ผ๋ก BSD scheduler์ ๊ตฌํํ๋ค. BSD scheduling์ ์ํด์ MLFQ๋ MLRQ์ ๊ธฐ๋ฒ์ด ์ฌ์ฉ๋๋ค.
- ์์ธํ ๋ด์ฉ์ ์ฒจ๋ถ๋ document ํ์ผ๋ค ์ฐธ์กฐ