| 
            Last change
 on this file since ca4f2b2 was             5546f50b, checked in by Peter A. Buhr <pabuhr@…>, 20 months ago           | 
        
        
          | 
             
more switch to tabs 
 
           | 
        
        
          
            
              - 
Property                 mode
 set to                 
100644
               
             
           | 
        
        
          | 
            File size:
            282 bytes
           | 
        
      
      
| Line |   | 
|---|
| 1 | #include <array.hfa>
 | 
|---|
| 2 | 
 | 
|---|
| 3 | // traditional "naiive" loops
 | 
|---|
| 4 | forall( [M], [N], [P] )
 | 
|---|
| 5 | void matmul( array(float, M, P) & src1,
 | 
|---|
| 6 |                          array(float, P, N) & src2, 
 | 
|---|
| 7 |                          array(float, M, N) & tgt ) {
 | 
|---|
| 8 |         for (i; M) for (j; N) {
 | 
|---|
| 9 |                 tgt[i][j] = 0;
 | 
|---|
| 10 |                 for (k; P)
 | 
|---|
| 11 |                         tgt[i][j] += src1[i][k] * src2[k][j];
 | 
|---|
| 12 |         }
 | 
|---|
| 13 | }
 | 
|---|
       
      
  Note:
 See   
TracBrowser
 for help on using the repository browser.