/[escript]/trunk/paso/src/Pattern.c
ViewVC logotype

Diff of /trunk/paso/src/Pattern.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1975 by artak, Mon Oct 27 01:31:28 2008 UTC revision 1976 by artak, Thu Nov 6 03:14:52 2008 UTC
# Line 31  Line 31 
31  /* allocates a Pattern  */  /* allocates a Pattern  */
32    
33  Paso_Pattern* Paso_Pattern_alloc(int type, dim_t input_block_size, dim_t output_block_size, dim_t numOutput, dim_t numInput, index_t* ptr, index_t* index) {  Paso_Pattern* Paso_Pattern_alloc(int type, dim_t input_block_size, dim_t output_block_size, dim_t numOutput, dim_t numInput, index_t* ptr, index_t* index) {
34    Paso_Pattern*out=NULL;    Paso_Pattern *out=NULL;
35    index_t index_offset=(type & PATTERN_FORMAT_OFFSET1 ? 1:0);    index_t index_offset=(type & PATTERN_FORMAT_OFFSET1 ? 1:0);
36    index_t loc_min_index,loc_max_index,min_index=index_offset,max_index=index_offset-1;    index_t loc_min_index,loc_max_index,min_index=index_offset,max_index=index_offset-1;
37    dim_t i, sum=0;    dim_t i;
38    Paso_resetError();    Paso_resetError();
39    
40    if (type & PATTERN_FORMAT_SYM) {    if (type & PATTERN_FORMAT_SYM) {
# Line 166  bool_t Paso_Pattern_isEmpty(Paso_Pattern Line 166  bool_t Paso_Pattern_isEmpty(Paso_Pattern
166    
167  Paso_Pattern* Paso_Pattern_multiply(int type, Paso_Pattern* A, Paso_Pattern* B) {  Paso_Pattern* Paso_Pattern_multiply(int type, Paso_Pattern* A, Paso_Pattern* B) {
168    Paso_Pattern*out=NULL;    Paso_Pattern*out=NULL;
   index_t index_offset=(type & PATTERN_FORMAT_OFFSET1 ? 1:0);  
169    index_t iptrA,iptrB;    index_t iptrA,iptrB;
170    dim_t i,j,k;    dim_t i,j,k;
171    Paso_IndexList* index_list=NULL;    Paso_IndexList* index_list=NULL;
# Line 219  return out; Line 218  return out;
218   *   *
219   */   */
220  Paso_Pattern* Paso_Pattern_binop(int type, Paso_Pattern* A, Paso_Pattern* B) {  Paso_Pattern* Paso_Pattern_binop(int type, Paso_Pattern* A, Paso_Pattern* B) {
221    Paso_Pattern*out=NULL;    Paso_Pattern *out=NULL;
222    index_t index_offset=(type & PATTERN_FORMAT_OFFSET1 ? 1:0);    index_t iptrA,iptrB;
   index_t iptrA,iptrB,*A_row=NULL,*B_row=NULL;  
223    dim_t i,j,k;    dim_t i,j,k;
224    
225    Paso_IndexList* index_list=NULL;    Paso_IndexList* index_list=NULL;

Legend:
Removed from v.1975  
changed lines
  Added in v.1976

  ViewVC Help
Powered by ViewVC 1.1.26