Level 2 subroutine *************************************************************************/
| 2410 | Level 2 subroutine |
| 2411 | *************************************************************************/ |
| 2412 | static void cmatrixsyrk2(int n, |
| 2413 | int k, |
| 2414 | double alpha, |
| 2415 | const ap::complex_2d_array& a, |
| 2416 | int ia, |
| 2417 | int ja, |
| 2418 | int optypea, |
| 2419 | double beta, |
| 2420 | ap::complex_2d_array& c, |
| 2421 | int ic, |
| 2422 | int jc, |
| 2423 | bool isupper) |
| 2424 | { |
| 2425 | int i; |
| 2426 | int j; |
| 2427 | int j1; |
| 2428 | int j2; |
| 2429 | ap::complex v; |
| 2430 | |
| 2431 | |
| 2432 | // |
| 2433 | // Fast exit (nothing to be done) |
| 2434 | // |
| 2435 | if( (ap::fp_eq(alpha,0)||k==0)&&ap::fp_eq(beta,1) ) |
| 2436 | { |
| 2437 | return; |
| 2438 | } |
| 2439 | |
| 2440 | // |
| 2441 | // Try to call fast SYRK |
| 2442 | // |
| 2443 | if( cmatrixsyrkf(n, k, alpha, a, ia, ja, optypea, beta, c, ic, jc, isupper) ) |
| 2444 | { |
| 2445 | return; |
| 2446 | } |
| 2447 | |
| 2448 | // |
| 2449 | // SYRK |
| 2450 | // |
| 2451 | if( optypea==0 ) |
| 2452 | { |
| 2453 | |
| 2454 | // |
| 2455 | // C=alpha*A*A^H+beta*C |
| 2456 | // |
| 2457 | for(i = 0; i <= n-1; i++) |
| 2458 | { |
| 2459 | if( isupper ) |
| 2460 | { |
| 2461 | j1 = i; |
| 2462 | j2 = n-1; |
| 2463 | } |
| 2464 | else |
| 2465 | { |
| 2466 | j1 = 0; |
| 2467 | j2 = i; |
| 2468 | } |
| 2469 | for(j = j1; j <= j2; j++) |
no test coverage detected