[Overview][Constants][Types][Procedures and functions][Index] |
Perform a futex operation
Source position: linux.pp line 114
function futex( |
uaddr: pcint; |
op: cint; |
val: cint; |
timeout: ptimespec; |
addr2: pcint; |
val3: cint |
):cint; |
var uaddr; |
op: cint; |
val: cint; |
timeout: ptimespec; |
var addr2; |
val3: cint |
):cint; |
var uaddr; |
op: cint; |
val: cint; |
var timeout: TTimeSpec; |
var addr2; |
val3: cint |
):cint; |
uaddr: pcint; |
op: cint; |
val: cint; |
timeout: ptimespec |
):cint; |
var uaddr; |
op: cint; |
val: cint; |
timeout: ptimespec |
):cint; |
var uaddr; |
op: cint; |
val: cint; |
var timeout: TTimeSpec |
):cint; |
futex performs an operation on a memory futex as described in the kernel manual page for futex. The mutex is located at uaddr, the operation op is one of the following constants:
The value to check for is indicated in val, and a timeout can be specified in timeout. The optional arguments addr2 and val3 are used only with the FUTEX_REQUEUE and FUTEX_CMP_REQUEUE operations.
In case of an error, -1 is return. All other return values must be interpreted according to the operation performed.
This call directly interfaces with the Linux kernel, more information can be found in the kernel manual pages.
On error, -1 is returned. Use #rtl.baseunix.fpgeterrno to get the error code.