Can the dirtiness of pages of a mmap be found from userspace?

前端 未结 5 533
感动是毒
感动是毒 2020-12-15 07:36

Can dirtiness of pages of a (non-shared) mmap be accessed from userspace under linux 2.6.30+? Platform-specific hacks and kludges welcome.

Ideally, I\'m looking for

5条回答
  •  余生分开走
    2020-12-15 08:22

    The traditional solution is to mprotect to read only, and then handle the sigsegv and mark dirty before reprotecting to allow writes. We did this at ObjectStore a long time ago for this very purpose.

提交回复
热议问题