3 ms·
I haven't tested but I would expect MS_INVALIDATE on a large buffer to be much faster than filling it a word at a time with __sync_val_compare_and_swap (each ca
by prodigal_erik 10y ago
I haven't tested but I would expect MS_INVALIDATE on a large buffer to be much faster than filling it a word at a time with __sync_val_compare_and_swap (each causing its own bus transaction).
- throwaway76543 10y agomsync() doesn't fill buffers at all. It has no function in the operation you've described. Even if it did, it's not atomic ...
- gpderetta 10y agoMS_INVALIDATE is likely a no-op on any modernish Unix, including Linux. It is there to accommodate old systems with non-coherent mapped files and page caches or even multiple mappings of the same file.