Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

segflush(2) [plan9 man page]

SEGFLUSH(2)							System Calls Manual						       SEGFLUSH(2)

NAME
segflush - flush instruction and data caches SYNOPSIS
#include <u.h> #include <libc.h> int segflush(void *va, ulong len) DESCRIPTION
Segflush invalidates any instruction cache and writes back any data cache associated with pages contained in a segment. All subsequent new pages in the segment will also be flushed when first referenced. Va is an address within the segment to be flushed; it is rounded down to the nearest page boundary. Len specifies the length in bytes of the memory to flush; va+len is rounded up to the nearest page boundary. Segflush works correctly when the memory straddles multiple seg- ments. Correct use of segflush depends on an understanding of the cache architecture of the specific machine. SOURCE
/sys/src/libc/9syscall SEE ALSO
segattach(2), segbrk(2) /proc/*/segment DIAGNOSTICS
Sets errstr. SEGFLUSH(2)

Check Out this Related Man Page

RENDEZVOUS(2)							System Calls Manual						     RENDEZVOUS(2)

NAME
rendezvous - user level process synchronization SYNOPSIS
#include <u.h> #include <libc.h> ulong rendezvous(ulong tag, ulong value) DESCRIPTION
The rendezvous system call allows two processes to synchronize and exchange a value. In conjunction with the shared memory system calls (see segattach(2) and fork(2)), it enables parallel programs to control their scheduling. Two processes wishing to synchronize call rendezvous with a common tag, typically an address in memory they share. One process will arrive at the rendezvous first; it suspends execution until a second arrives. When a second process meets the rendezvous the value arguments are exchanged between the processes and returned as the result of the respective rendezvous system calls. Both processes are awakened when the rendezvous succeeds. The tag space is common to processes in the same file name space, so rendezvous only works between processes in the same file name space. If a rendezvous is interrupted the return value is ~0, so that value should not be used in normal communication. SOURCE
/sys/src/libc/9syscall SEE ALSO
segattach(2), fork(2) DIAGNOSTICS
Sets errstr. BUGS
The correlation of rendezvous tags and file name space is a historical accident. If two unrelated processes happen to be in the same name space and do a rendezvous, trouble will result. The solution is to call rfork(RFNAMEG) (see fork(2)) in programs that use rendezvous unless they need to share the name space with their parent. This is especially important in Alef programs. RENDEZVOUS(2)
Man Page

2 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Shopt -s histappend

What is the point of this? Whenever I close my shell it appends to the history file without adding this. I have never seen it overwrite my history file. # When the shell exits, append to the history file instead of overwriting it shopt -s histappend (3 Replies)
Discussion started by: cokedude
3 Replies

2. UNIX for Advanced & Expert Users

What's your most useful shell?

What's your most useful shell? /bin/sh /bin/csh /bin/ksh /bin/tcsh /bin/bash (249 Replies)
Discussion started by: zylwyz
249 Replies