|
|
Subscribe / Log in / New account

sys_membarrier()

sys_membarrier()

Posted Jan 20, 2010 23:26 UTC (Wed) by compudj (subscriber, #43335)
In reply to: sys_membarrier() by ikm
Parent article: sys_membarrier()

In essence, yes, the read-side memory barriers are only executed when the updater requires that synchronization. With RCU, we only have to execute the barriers each time a synchronize_rcu() is called, which occurs typically far less often than variable updates.

Rephrasing what you said: "the idea is to make CPUs execute memory barriers only when synchronization is required by the updater thread, as opposed to executing them each time before and after accessing it from a reader thread".

Thanks,

Mathieu


to post comments


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds