MCPcopy Create free account
hub / github.com/BoevaLab/FREEC / rmatrixsyrk2

Function rmatrixsyrk2

src/ablas.cpp:2547–2676  ·  view source on GitHub ↗

Level 2 subrotuine *************************************************************************/

Source from the content-addressed store, hash-verified

2545Level 2 subrotuine
2546*************************************************************************/
2547static void rmatrixsyrk2(int n,
2548 int k,
2549 double alpha,
2550 const ap::real_2d_array& a,
2551 int ia,
2552 int ja,
2553 int optypea,
2554 double beta,
2555 ap::real_2d_array& c,
2556 int ic,
2557 int jc,
2558 bool isupper)
2559{
2560 int i;
2561 int j;
2562 int j1;
2563 int j2;
2564 double v;
2565
2566
2567 //
2568 // Fast exit (nothing to be done)
2569 //
2570 if( (ap::fp_eq(alpha,0)||k==0)&&ap::fp_eq(beta,1) )
2571 {
2572 return;
2573 }
2574
2575 //
2576 // Try to call fast SYRK
2577 //
2578 if( rmatrixsyrkf(n, k, alpha, a, ia, ja, optypea, beta, c, ic, jc, isupper) )
2579 {
2580 return;
2581 }
2582
2583 //
2584 // SYRK
2585 //
2586 if( optypea==0 )
2587 {
2588
2589 //
2590 // C=alpha*A*A^H+beta*C
2591 //
2592 for(i = 0; i <= n-1; i++)
2593 {
2594 if( isupper )
2595 {
2596 j1 = i;
2597 j2 = n-1;
2598 }
2599 else
2600 {
2601 j1 = 0;
2602 j2 = i;
2603 }
2604 for(j = j1; j <= j2; j++)

Callers 1

rmatrixsyrkFunction · 0.85

Calls 4

rmatrixsyrkfFunction · 0.85
vdotproductFunction · 0.85
vmulFunction · 0.85
vaddFunction · 0.85

Tested by

no test coverage detected