hpl_panel.h 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148
  1. /*
  2. * -- High Performance Computing Linpack Benchmark (HPL)
  3. * HPL - 2.0 - September 10, 2008
  4. * Antoine P. Petitet
  5. * University of Tennessee, Knoxville
  6. * Innovative Computing Laboratory
  7. * (C) Copyright 2000-2008 All Rights Reserved
  8. *
  9. * -- Copyright notice and Licensing terms:
  10. *
  11. * Redistribution and use in source and binary forms, with or without
  12. * modification, are permitted provided that the following conditions
  13. * are met:
  14. *
  15. * 1. Redistributions of source code must retain the above copyright
  16. * notice, this list of conditions and the following disclaimer.
  17. *
  18. * 2. Redistributions in binary form must reproduce the above copyright
  19. * notice, this list of conditions, and the following disclaimer in the
  20. * documentation and/or other materials provided with the distribution.
  21. *
  22. * 3. All advertising materials mentioning features or use of this
  23. * software must display the following acknowledgement:
  24. * This product includes software developed at the University of
  25. * Tennessee, Knoxville, Innovative Computing Laboratory.
  26. *
  27. * 4. The name of the University, the name of the Laboratory, or the
  28. * names of its contributors may not be used to endorse or promote
  29. * products derived from this software without specific written
  30. * permission.
  31. *
  32. * -- Disclaimer:
  33. *
  34. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  35. * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  36. * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  37. * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY
  38. * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  39. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  40. * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  41. * DATA OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  42. * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  43. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  44. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  45. */
  46. #ifndef HPL_PANEL_H
  47. #define HPL_PANEL_H
  48. /*
  49. * ---------------------------------------------------------------------
  50. * Include files
  51. * ---------------------------------------------------------------------
  52. */
  53. #include "hpl_pmisc.h"
  54. #include "hpl_grid.h"
  55. /*
  56. * ---------------------------------------------------------------------
  57. * Data Structures
  58. * ---------------------------------------------------------------------
  59. */
  60. typedef struct HPL_S_panel
  61. {
  62. struct HPL_S_grid * grid; /* ptr to the process grid */
  63. struct HPL_S_palg * algo; /* ptr to the algo parameters */
  64. struct HPL_S_pmat * pmat; /* ptr to the local array info */
  65. double * A; /* ptr to trailing part of A */
  66. double * WORK; /* work space */
  67. double * L2; /* ptr to L */
  68. double * L1; /* ptr to jb x jb upper block of A */
  69. double * DPIV; /* ptr to replicated jb pivot array */
  70. double * DINFO; /* ptr to replicated scalar info */
  71. double * U; /* ptr to U */
  72. int * IWORK; /* integer workspace for swapping */
  73. void * * * buffers[2]; /* buffers for panel bcast */
  74. int counts [2]; /* counts for panel bcast */
  75. MPI_Datatype dtypes [2]; /* data types for panel bcast */
  76. MPI_Request request[1]; /* requests for panel bcast */
  77. MPI_Status status [1]; /* status for panel bcast */
  78. int nb; /* distribution blocking factor */
  79. int jb; /* panel width */
  80. int m; /* global # of rows of trailing part of A */
  81. int n; /* global # of cols of trailing part of A */
  82. int ia; /* global row index of trailing part of A */
  83. int ja; /* global col index of trailing part of A */
  84. int mp; /* local # of rows of trailing part of A */
  85. int nq; /* local # of cols of trailing part of A */
  86. int ii; /* local row index of trailing part of A */
  87. int jj; /* local col index of trailing part of A */
  88. int lda; /* local leading dim of array A */
  89. int prow; /* proc. row owning 1st row of trail. A */
  90. int pcol; /* proc. col owning 1st col of trail. A */
  91. int msgid; /* message id for panel bcast */
  92. int ldl2; /* local leading dim of array L2 */
  93. int len; /* length of the buffer to broadcast */
  94. #ifdef HPL_CALL_VSIPL
  95. vsip_block_d * Ablock; /* A block */
  96. vsip_block_d * L1block; /* L1 block */
  97. vsip_block_d * L2block; /* L2 block */
  98. vsip_block_d * Ublock; /* U block */
  99. #endif
  100. } HPL_T_panel;
  101. /*
  102. * ---------------------------------------------------------------------
  103. * panel function prototypes
  104. * ---------------------------------------------------------------------
  105. */
  106. #include "hpl_pgesv.h"
  107. void HPL_pdpanel_new
  108. STDC_ARGS( (
  109. HPL_T_grid *,
  110. HPL_T_palg *,
  111. const int,
  112. const int,
  113. const int,
  114. HPL_T_pmat *,
  115. const int,
  116. const int,
  117. const int,
  118. HPL_T_panel * *
  119. ) );
  120. void HPL_pdpanel_init
  121. STDC_ARGS( (
  122. HPL_T_grid *,
  123. HPL_T_palg *,
  124. const int,
  125. const int,
  126. const int,
  127. HPL_T_pmat *,
  128. const int,
  129. const int,
  130. const int,
  131. HPL_T_panel *
  132. ) );
  133. int HPL_pdpanel_disp
  134. STDC_ARGS( (
  135. HPL_T_panel * *
  136. ) );
  137. int HPL_pdpanel_free
  138. STDC_ARGS( (
  139. HPL_T_panel *
  140. ) );
  141. #endif
  142. /*
  143. * End of hpl_panel.h
  144. */