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 | 29 | 30 |
31 |
Tags
- 카프카
- fastpath
- blk-mq
- strex
- spinlock
- pmap
- vm_area_struct
- BLOCK
- buddy_system
- vmalloc
- Android
- commit
- Kernel
- proc
- lruvec
- slowpath
- Network
- kmalloc
- Linux
- devicedriver
- mm_struct
- page
- slub
- memory
- allocator
- NDK
- Apache
- multiqueue
- slab
- kafka
Archives
- Today
- Total
목록2020/05/15 (1)
Art of Pr0gr4m
[Linux Kernel 5] Slab & Slub Allocator #1
1. Basis 슬랩은 자주 사용하는 메모리 타입을 부팅 시 미리 할당하여 동적 메모리 할당/해제의 비용과 메모리 fragmentation을 최소화하는 일종의 캐시다. `# cat /proc/slabinfo` 명령의 결과로 아래와 같이 슬랩 할당자의 정보를 볼 수 있다. 친숙한(?) task_struct 구조체나, 이 전 포스트들에서 공부했던 request_queue, blkdev_requests, vm_area_struct, mm_struct, anon_vma(_chain) 등이 보인다. 즉, 슬랩은 이렇게 자주 사용하는 데이터 컨테이너를 미리 할당해두고 해당 데이터 할당 요청 시 할당 오버헤드를 최소화한다. Slab Allocator의 최소 할당 단위는 slab object이다. 그리고 slab ob..
IT/Linux Kernel
2020. 5. 15. 10:53