HCC
HCC is a single-source, C/C++ compiler for heterogeneous computing. It's optimized with HSA (http://www.hsafoundation.com/).
Public Member Functions | Friends | List of all members
hc::tile_barrier Class Reference

The tile_barrier class is a capability class that is only creatable by the system, and passed to a tiled parallel_for_each function object as part of the tiled_index parameter. More...

#include <hc.hpp>

Collaboration diagram for hc::tile_barrier:
Collaboration graph

Public Member Functions

 tile_barrier (const tile_barrier &other) __CPU__ __HC__
 Copy constructor. More...
 
void wait () const __HC__
 Blocks execution of all threads in the thread tile until all threads in the tile have reached this call. More...
 
void wait_with_all_memory_fence () const __HC__
 Blocks execution of all threads in the thread tile until all threads in the tile have reached this call. More...
 
void wait_with_global_memory_fence () const __HC__
 Blocks execution of all threads in the thread tile until all threads in the tile have reached this call. More...
 
void wait_with_tile_static_memory_fence () const __HC__
 Blocks execution of all threads in the thread tile until all threads in the tile have reached this call. More...
 

Friends

template<int N>
class tiled_index
 

Detailed Description

The tile_barrier class is a capability class that is only creatable by the system, and passed to a tiled parallel_for_each function object as part of the tiled_index parameter.

It provides member functions, such as wait, whose purpose is to synchronize execution of threads running within the thread tile.

Constructor & Destructor Documentation

hc::tile_barrier::tile_barrier ( const tile_barrier other)
inline

Copy constructor.

Constructs a new tile_barrier from the supplied argument "other".

Parameters
[in]otherAn object of type tile_barrier from which to initialize this.

Member Function Documentation

void hc::tile_barrier::wait ( ) const
inline

Blocks execution of all threads in the thread tile until all threads in the tile have reached this call.

Establishes a memory fence on all tile_static and global memory operations executed by the threads in the tile such that all memory operations issued prior to hitting the barrier are visible to all other threads after the barrier has completed and none of the memory operations occurring after the barrier are executed before hitting the barrier. This is identical to wait_with_all_memory_fence().

void hc::tile_barrier::wait_with_all_memory_fence ( ) const
inline

Blocks execution of all threads in the thread tile until all threads in the tile have reached this call.

Establishes a memory fence on all tile_static and global memory operations executed by the threads in the tile such that all memory operations issued prior to hitting the barrier are visible to all other threads after the barrier has completed and none of the memory operations occurring after the barrier are executed before hitting the barrier. This is identical to wait().

void hc::tile_barrier::wait_with_global_memory_fence ( ) const
inline

Blocks execution of all threads in the thread tile until all threads in the tile have reached this call.

Establishes a memory fence on global memory operations (but not tile-static memory operations) executed by the threads in the tile such that all global memory operations issued prior to hitting the barrier are visible to all other threads after the barrier has completed and none of the global memory operations occurring after the barrier are executed before hitting the barrier.

void hc::tile_barrier::wait_with_tile_static_memory_fence ( ) const
inline

Blocks execution of all threads in the thread tile until all threads in the tile have reached this call.

Establishes a memory fence on tile-static memory operations (but not global memory operations) executed by the threads in the tile such that all tile_static memory operations issued prior to hitting the barrier are visible to all other threads after the barrier has completed and none of the tile-static memory operations occurring after the barrier are executed before hitting the barrier.

References hc::all_memory_fence(), hc::global_memory_fence(), and hc::tile_static_memory_fence().


The documentation for this class was generated from the following file: