从地址池中分配count个连续页
| 14 | |
| 15 | // 从地址池中分配count个连续页 |
| 16 | int AddressPool::allocate(const int count) |
| 17 | { |
| 18 | int start = resources.allocate(count); |
| 19 | return (start == -1) ? -1 : (start * PAGE_SIZE + startAddress); |
| 20 | } |
| 21 | |
| 22 | // 释放若干页的空间 |
| 23 | void AddressPool::release(const int address, const int amount) |
nothing calls this directly
no outgoing calls
no test coverage detected