| | 116 | === Types |
| | 117 | * `$gbarrier` |
| | 118 | * A data type representing a handle to a global barrier object. |
| | 119 | |
| | 120 | * `$barrier` |
| | 121 | * A data type representing a process-local handle used to operate a global barrier |
| | 122 | |
| | 123 | === Functions |
| | 124 | * `$atomic_f $gbarrier $gbarrier_create($scope scope, int size)` |
| | 125 | * Creates a new global barrier object and returns a handle to it. The barrier has the specified `size`. The new object will be allocated in the given `scope`. |
| | 126 | * `$atomic_f void $gbarrier_destroy($gbarrier gbarrier)` |
| | 127 | * Destroys the global barrier object referred by the handle `gbarrier` |
| | 128 | * `int $get_nprocs($gbarrier gbarrier)` |
| | 129 | * Returns the size of the global barrier object |
| | 130 | * `$atomic_f $barrier $barrier_create($scope scope, $gbarrier gbarrier, int place)` |
| | 131 | * Creates a process-local handle for operating the global barrier referred by `gbarrier`. The `place` must be in [0,`get_nprocs(gbarrier)`-1]. It specifies the place in the global barrier that will be occupied by the local handle. |
| | 132 | * `$atomic_f void $barrier_destroy($barrier barrier)` |
| | 133 | * Destroys the local handle to a global barrier |
| | 134 | * `void $barrier_call($barrier barrier)` |
| | 135 | * Calls the barrier referred by `barrier` |
| | 136 | * `void $barrier_call_yield($barrier barrier)` |
| | 137 | * Calls the barrier from within an atomic section: this will yield at the point where process is waiting to exit barrier. |
| | 138 | * `void $barrier_call_subset($barrier barrier, int nprocs)` |
| | 139 | * under construction |
| | 140 | * `void $barrier_call_execute($barrier barrier, void foo(void))` |
| | 141 | * under construction |