FLASH_Queue_main_prototypes.h

Go to the documentation of this file.
00001 /*
00002    libflame
00003    An object-based infrastructure for developing high-performance
00004    dense linear algebra libraries.
00005 
00006    Copyright (C) 2009, The University of Texas
00007 
00008    libflame is free software; you can redistribute it and/or modify
00009    it under the terms of the GNU Lesser General Public License as
00010    published by the Free Software Foundation; either version 2.1 of
00011    the License, or (at your option) any later version.
00012 
00013    libflame is distributed in the hope that it will be useful, but
00014    WITHOUT ANY WARRANTY; without even the implied warranty of
00015    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
00016    Lesser General Public License for more details.
00017 
00018    You should have received a copy of the GNU Lesser General Public
00019    License along with libflame; if you did not receive a copy, see
00020    http://www.gnu.org/licenses/.
00021 
00022    For more information, please contact us at flame@cs.utexas.edu or
00023    send mail to:
00024 
00025    Field G. Van Zee and/or
00026    Robert A. van de Geijn
00027    The University of Texas at Austin
00028    Department of Computer Sciences
00029    1 University Station C0500
00030    Austin TX 78712
00031 */
00032 
00033 #ifndef FLASH_QUEUE_MAIN_PROTOTYPES_H
00034 #define FLASH_QUEUE_MAIN_PROTOTYPES_H
00035 
00036 
00037 void           FLASH_Queue_begin( void );
00038 void           FLASH_Queue_end( void );
00039 
00040 FLA_Error      FLASH_Queue_enable( void );
00041 FLA_Error      FLASH_Queue_disable( void );
00042 FLA_Bool       FLASH_Queue_get_enabled( void );
00043 
00044 void           FLASH_Queue_set_num_threads( unsigned int n_threads );
00045 unsigned int   FLASH_Queue_get_num_threads( void );
00046 
00047 
00048 #ifdef FLA_ENABLE_SUPERMATRIX
00049 
00050 
00051 void           FLASH_Queue_init( void );
00052 void           FLASH_Queue_finalize( void );
00053 
00054 int            FLASH_Queue_get_num_tasks( void );
00055 
00056 void           FLASH_Queue_set_verbose_output( FLA_Bool verbose );
00057 FLA_Bool       FLASH_Queue_get_verbose_output( void );
00058 void           FLASH_Queue_set_sorting( FLA_Bool sorting );
00059 FLA_Bool       FLASH_Queue_get_sorting( void );
00060 void           FLASH_Queue_set_caching( FLA_Bool caching );
00061 FLA_Bool       FLASH_Queue_get_caching( void );
00062 void           FLASH_Queue_set_work_stealing( FLA_Bool work_stealing );
00063 FLA_Bool       FLASH_Queue_get_work_stealing( void );
00064 void           FLASH_Queue_set_data_affinity( FLASH_Data_aff data_affinity );
00065 FLASH_Data_aff FLASH_Queue_get_data_affinity( void );
00066 double         FLASH_Queue_get_total_time( void );
00067 double         FLASH_Queue_get_parallel_time( void );
00068 
00069 void           FLASH_Queue_exec( void );
00070 
00071 
00072 // --- helper functions -------------------------------------------------------
00073 
00074 void           FLASH_Queue_set_parallel_time( double dtime );
00075 int            FLASH_Queue_get_num_blocks( void );
00076 void           FLASH_Queue_set_block_size( int size );
00077 int            FLASH_Queue_get_block_size( void );
00078 void           FLASH_Queue_set_cache_size( int size );
00079 int            FLASH_Queue_get_cache_size( void );
00080 void           FLASH_Queue_set_cache_line_size( int size );
00081 int            FLASH_Queue_get_cache_line_size( void );
00082 void           FLASH_Queue_set_cores_per_cache( int cores );
00083 int            FLASH_Queue_get_cores_per_cache( void );
00084 void           FLASH_Queue_reset( void );
00085 FLASH_Task*    FLASH_Queue_get_head_task( void );
00086 FLASH_Task*    FLASH_Queue_get_tail_task( void );
00087 void           FLASH_Queue_push( void *func, void *cntl, char *name,
00088                                  int n_int_args, int n_fla_args,
00089                                  int n_input_args, int n_output_args, ... );
00090 FLASH_Task*    FLASH_Task_alloc( void *func, void *cntl, char *name,
00091                                  int n_int_args, int n_fla_args,
00092                                  int n_input_args, int n_output_args );
00093 void           FLASH_Task_free( FLASH_Task *t );
00094 void           FLASH_Queue_exec_task( FLASH_Task *t );
00095 void           FLASH_Queue_verbose_output( void );
00096 void           FLASH_Queue_visualization( void );
00097 
00098 void           FLASH_Queue_init_tasks( void *arg );
00099 void           FLASH_Queue_wait_enqueue( FLASH_Task *t, void *arg );
00100 FLASH_Task*    FLASH_Queue_wait_dequeue( int queue, int thread, void *arg );
00101 void           FLASH_Queue_exec_parallel( void *arg );
00102 void*          FLASH_Queue_exec_parallel_function( void *arg );
00103 FLASH_Task*    FLASH_Task_update_dependencies( FLASH_Task *t, void *arg );
00104 void           FLASH_Task_free_parallel( FLASH_Task *t, void *arg );
00105 void           FLASH_Queue_exec_simulation( void *arg );
00106 
00107 
00108 #endif // FLA_ENABLE_SUPERMATRIX
00109 
00110 
00111 #endif // FLASH_QUEUE_MAIN_PROTOTYPES_H

Generated on Mon Jul 6 05:45:48 2009 for libflame by  doxygen 1.5.9