Export (0) Print
Expand All

Thread.MemoryBarrier Method

Note: This namespace, class, or member is supported only in version 1.1 of the .NET Framework.

Synchronizes memory. In effect, flushes the contents of cache memory to main memory, for the processor executing the current thread.

[Visual Basic]
Public Shared Sub MemoryBarrier()
[C#]
public static void MemoryBarrier();
[C++]
public: static void MemoryBarrier();
[JScript]
public static function MemoryBarrier();

Remarks

MemoryBarrier is required only on multiprocessor systems with weak memory ordering (for example, a system employing multiple Intel Itanium processors).

For most purposes, the C# lock statement, the Visual Basic SyncLock statement, or the Monitor class provide easier ways to synchronize data.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

Thread Class | Thread Members | System.Threading Namespace

Show:
© 2014 Microsoft