gpt4 book ai didi

c - mmap 和 munmap 行为

转载 作者:太空狗 更新时间:2023-10-29 15:07:36 27 4
gpt4 key购买 nike

Open Group 标准规定应使用页对齐地址调用 munmap,但似乎没有任何要求 mmap 应返回页对齐地址。这是您在编写可移植代码时需要处理的事情吗?

最佳答案

mmap 只会映射整个页面,因此只能返回页面边界。它在简短的描述中:

mmap - 映射内存的

(强调我的)

关于c - mmap 和 munmap 行为,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7620568/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com