netbsd man page for __insn_barrier

Query: __insn_barrier

OS: netbsd

Section: 3

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

__INSN_BARRIER(3)					   BSD Library Functions Manual 					 __INSN_BARRIER(3)

NAME
__insn_barrier -- compiler reorder barrier
SYNOPSIS
#include <sys/cdefs.h> void __insn_barrier();
DESCRIPTION
The __insn_barrier() macro prevents GCC from moving code across the barrier. In other words, the compiler is not allowed to reorder read and write commands below the barrier with the code preceding the barrier. Like with the volatile type qualifier, __insn_barrier() may be neces- sary in some corner cases to prevent the compiler from misoptimizing.
SEE ALSO
gcc(1), cdefs(3), mb(9) Paul E. McKenney, Memory Barriers: a Hardware View for Software Hackers, http://www.rdrop.com/users/paulmck/scalability/paper/whymb.2010.06.07c.pdf, June 7, 2010.
HISTORY
The __insn_barrier() macro first appeared in NetBSD 2.0.
BSD
January 2, 2011 BSD
Related Man Pages
mb_read(9) - netbsd
membar_consumer(3) - netbsd
membar_exit(3) - netbsd
mb(9) - netbsd
mb_write(9) - netbsd
Similar Topics in the Unix Linux Community
Memory Leaks
How to install PGX32 on Sparc 10 Ultra?
RFC - Korn shell prompt
BSD Unix Toolbox: 1000+ Commands for FreeBSD, OpenBSD, and NetBSD
Grep command to show the number of results