| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | /* | ||
| 2 | - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
| 3 | SLEPc - Scalable Library for Eigenvalue Problem Computations | ||
| 4 | Copyright (c) 2002-, Universitat Politecnica de Valencia, Spain | ||
| 5 | |||
| 6 | This file is part of SLEPc. | ||
| 7 | SLEPc is distributed under a 2-clause BSD license (see LICENSE). | ||
| 8 | - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||
| 9 | */ | ||
| 10 | |||
| 11 | #include <slepc/private/svdimpl.h> /*I "slepcsvd.h" I*/ | ||
| 12 | |||
| 13 | SLEPC_EXTERN PetscErrorCode SVDCreate_Cross(SVD); | ||
| 14 | SLEPC_EXTERN PetscErrorCode SVDCreate_Cyclic(SVD); | ||
| 15 | SLEPC_EXTERN PetscErrorCode SVDCreate_LAPACK(SVD); | ||
| 16 | SLEPC_EXTERN PetscErrorCode SVDCreate_Lanczos(SVD); | ||
| 17 | SLEPC_EXTERN PetscErrorCode SVDCreate_TRLanczos(SVD); | ||
| 18 | SLEPC_EXTERN PetscErrorCode SVDCreate_Randomized(SVD); | ||
| 19 | #if defined(SLEPC_HAVE_SCALAPACK) | ||
| 20 | SLEPC_EXTERN PetscErrorCode SVDCreate_ScaLAPACK(SVD); | ||
| 21 | #endif | ||
| 22 | #if defined(SLEPC_HAVE_KSVD) | ||
| 23 | SLEPC_EXTERN PetscErrorCode SVDCreate_KSVD(SVD); | ||
| 24 | #endif | ||
| 25 | #if defined(SLEPC_HAVE_ELEMENTAL) | ||
| 26 | SLEPC_EXTERN PetscErrorCode SVDCreate_Elemental(SVD); | ||
| 27 | #endif | ||
| 28 | #if defined(SLEPC_HAVE_PRIMME) | ||
| 29 | SLEPC_EXTERN PetscErrorCode SVDCreate_PRIMME(SVD); | ||
| 30 | #endif | ||
| 31 | |||
| 32 | /*@C | ||
| 33 | SVDRegisterAll - Registers all the singular value solvers in the `SVD` package. | ||
| 34 | |||
| 35 | Not Collective | ||
| 36 | |||
| 37 | Level: advanced | ||
| 38 | |||
| 39 | .seealso: [](ch:svd), `SVDRegister()` | ||
| 40 | @*/ | ||
| 41 | 4547 | PetscErrorCode SVDRegisterAll(void) | |
| 42 | { | ||
| 43 |
1/2✓ Branch 0 taken 2 times.
✗ Branch 1 not taken.
|
4547 | PetscFunctionBegin; |
| 44 |
8/14✓ Branch 0 taken 10 times.
✓ Branch 1 taken 10 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
✓ Branch 6 taken 2 times.
✗ Branch 7 not taken.
✓ Branch 8 taken 2 times.
✗ Branch 9 not taken.
✓ Branch 10 taken 2 times.
✗ Branch 11 not taken.
✗ Branch 12 not taken.
✓ Branch 13 taken 2 times.
|
4547 | if (SVDRegisterAllCalled) PetscFunctionReturn(PETSC_SUCCESS); |
| 45 | 2326 | SVDRegisterAllCalled = PETSC_TRUE; | |
| 46 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDRegister(SVDCROSS,SVDCreate_Cross)); |
| 47 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDRegister(SVDCYCLIC,SVDCreate_Cyclic)); |
| 48 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDRegister(SVDLAPACK,SVDCreate_LAPACK)); |
| 49 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDRegister(SVDLANCZOS,SVDCreate_Lanczos)); |
| 50 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDRegister(SVDTRLANCZOS,SVDCreate_TRLanczos)); |
| 51 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDRegister(SVDRANDOMIZED,SVDCreate_Randomized)); |
| 52 | #if defined(SLEPC_HAVE_SCALAPACK) | ||
| 53 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 4 times.
|
977 | PetscCall(SVDRegister(SVDSCALAPACK,SVDCreate_ScaLAPACK)); |
| 54 | #endif | ||
| 55 | #if defined(SLEPC_HAVE_KSVD) | ||
| 56 | PetscCall(SVDRegister(SVDKSVD,SVDCreate_KSVD)); | ||
| 57 | #endif | ||
| 58 | #if defined(SLEPC_HAVE_ELEMENTAL) | ||
| 59 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 2 times.
|
505 | PetscCall(SVDRegister(SVDELEMENTAL,SVDCreate_Elemental)); |
| 60 | #endif | ||
| 61 | #if defined(SLEPC_HAVE_PRIMME) | ||
| 62 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 4 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
1450 | PetscCall(SVDRegister(SVDPRIMME,SVDCreate_PRIMME)); |
| 63 | #endif | ||
| 64 |
6/12✓ Branch 0 taken 2 times.
✗ Branch 1 not taken.
✗ Branch 2 not taken.
✓ Branch 3 taken 2 times.
✓ Branch 4 taken 2 times.
✗ Branch 5 not taken.
✓ Branch 6 taken 2 times.
✗ Branch 7 not taken.
✓ Branch 8 taken 2 times.
✗ Branch 9 not taken.
✗ Branch 10 not taken.
✓ Branch 11 taken 2 times.
|
455 | PetscFunctionReturn(PETSC_SUCCESS); |
| 65 | } | ||
| 66 | |||
| 67 | /*@C | ||
| 68 | SVDMonitorRegisterAll - Registers all the monitors in the `SVD` package. | ||
| 69 | |||
| 70 | Not Collective | ||
| 71 | |||
| 72 | Level: advanced | ||
| 73 | |||
| 74 | .seealso: [](ch:svd), `SVDMonitorRegister()` | ||
| 75 | @*/ | ||
| 76 | 2326 | PetscErrorCode SVDMonitorRegisterAll(void) | |
| 77 | { | ||
| 78 |
1/2✓ Branch 0 taken 2 times.
✗ Branch 1 not taken.
|
2326 | PetscFunctionBegin; |
| 79 |
2/14✓ Branch 0 taken 8 times.
✓ Branch 1 taken 2 times.
✗ Branch 2 not taken.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✗ Branch 5 not taken.
✗ Branch 6 not taken.
✗ Branch 7 not taken.
✗ Branch 8 not taken.
✗ Branch 9 not taken.
✗ Branch 10 not taken.
✗ Branch 11 not taken.
✗ Branch 12 not taken.
✗ Branch 13 not taken.
|
2326 | if (SVDMonitorRegisterAllCalled) PetscFunctionReturn(PETSC_SUCCESS); |
| 80 | 2326 | SVDMonitorRegisterAllCalled = PETSC_TRUE; | |
| 81 | |||
| 82 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("first_approximation",PETSCVIEWERASCII,PETSC_VIEWER_DEFAULT,SVDMonitorFirst,NULL,NULL)); |
| 83 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("first_approximation",PETSCVIEWERDRAW,PETSC_VIEWER_DRAW_LG,SVDMonitorFirstDrawLG,SVDMonitorFirstDrawLGCreate,NULL)); |
| 84 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("all_approximations",PETSCVIEWERASCII,PETSC_VIEWER_DEFAULT,SVDMonitorAll,NULL,NULL)); |
| 85 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("all_approximations",PETSCVIEWERDRAW,PETSC_VIEWER_DRAW_LG,SVDMonitorAllDrawLG,SVDMonitorAllDrawLGCreate,NULL)); |
| 86 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("convergence_history",PETSCVIEWERASCII,PETSC_VIEWER_DEFAULT,SVDMonitorConverged,SVDMonitorConvergedCreate,SVDMonitorConvergedDestroy)); |
| 87 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("convergence_history",PETSCVIEWERDRAW,PETSC_VIEWER_DRAW_LG,SVDMonitorConvergedDrawLG,SVDMonitorConvergedDrawLGCreate,SVDMonitorConvergedDestroy)); |
| 88 |
4/6✓ Branch 0 taken 2 times.
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 2 times.
✗ Branch 3 not taken.
✗ Branch 4 not taken.
✓ Branch 5 taken 2 times.
|
2326 | PetscCall(SVDMonitorRegister("conditioning",PETSCVIEWERASCII,PETSC_VIEWER_DEFAULT,SVDMonitorConditioning,NULL,NULL)); |
| 89 |
6/12✓ Branch 0 taken 2 times.
✗ Branch 1 not taken.
✗ Branch 2 not taken.
✓ Branch 3 taken 2 times.
✓ Branch 4 taken 2 times.
✗ Branch 5 not taken.
✓ Branch 6 taken 2 times.
✗ Branch 7 not taken.
✓ Branch 8 taken 2 times.
✗ Branch 9 not taken.
✗ Branch 10 not taken.
✓ Branch 11 taken 2 times.
|
455 | PetscFunctionReturn(PETSC_SUCCESS); |
| 90 | } | ||
| 91 |