Closed pipiw33 closed 11 months ago
It quite doesn't work that way. The memory cache is located on the physical memory layer so it will have to be completely cleared anyway. In essence MemProcFS does not know which memory belongs to which process and which memory are shared between multiple processes.
Also some kernel-level structures have to be updated. Slow may be a bit overkill though in some scenarios so it may be possible to speed it up a tiny bit.
But is the half a second really an issue if you're changing DTBs?
I've looked into this some more.
It should be possible to greatly speed up this process if doing it on normal processes, (not the system pid 4 process).
that would be really cool.I just set the DTB on the user process
I did an update in 5.8.15 just published in the C/C++ API.
I added a new option VMMDLL_OPT_PROCESS_DTB_FAST_LOWINTEGRITY
that should do the same thing but pretty much instantly.
Note that it will also clear internal data which will have to be re-generated at first access. Examples of this is the list of modules and VADs. This may still take some time.
But the actual call to set the DTB should now at least be much faster.
Please let me know how it goes, or if you're using some other API than the C/C++ one.
I'll check it quickly
Awesome to see the issue was resolved and that it now works well :)
This one was a bit hard for me to test so many thanks for confirming it works fine.
delete