Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
elpa
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
11
Issues
11
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Environments
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
elpa
elpa
Commits
2d684ef0
Commit
2d684ef0
authored
May 18, 2017
by
Andreas Marek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove duplicated routines for solve_tridi
parent
bd0fa35b
Changes
3
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
732 deletions
+34
-732
src/elpa1/elpa1_compute_template.X90
src/elpa1/elpa1_compute_template.X90
+19
-0
src/elpa1/elpa1_solve_tridi_real_template.X90
src/elpa1/elpa1_solve_tridi_real_template.X90
+15
-20
src/elpa1/elpa1_solve_tridi_real_template_legacy.X90
src/elpa1/elpa1_solve_tridi_real_template_legacy.X90
+0
-712
No files found.
src/elpa1/elpa1_compute_template.X90
View file @
2d684ef0
...
...
@@ -69,7 +69,26 @@
#include "elpa1_tridiag_template.X90"
#include "elpa1_trans_ev_template.X90"
! now comes a dirty hack:
! the file elpa1_solve_tridi_real_template.X90 must be included twice
! for the legacy and for the new API. In the new API, however, some routines
! must be named "..._impl"
#ifdef DOUBLE_PRECISION_REAL
#define PRECISION_AND_SUFFIX double
#else
#define PRECISION_AND_SUFFIX single
#endif
#include "elpa1_solve_tridi_real_template.X90"
#undef PRECISION_AND_SUFFIX
#ifdef DOUBLE_PRECISION_REAL
#define PRECISION_AND_SUFFIX double_impl
#else
#define PRECISION_AND_SUFFIX single_impl
#endif
#include "elpa1_solve_tridi_real_template.X90"
#undef PRECISION_AND_SUFFIX
#include "elpa1_merge_systems_real_template.X90"
#include "elpa1_tools_template.X90"
...
...
src/elpa1/elpa1_solve_tridi_real_template.X90
View file @
2d684ef0
...
...
@@ -55,8 +55,8 @@
#include "../general/sanity.X90"
subroutine solve_tridi_&
&PRECISION&
&_impl
( na, nev, d, e, q, ldq, nblk, matrixCols, mpi_comm_rows, &
&PRECISION
_AND_SUFFIX
&
( na, nev, d, e, q, ldq, nblk, matrixCols, mpi_comm_rows, &
mpi_comm_cols, wantDebug, success )
#ifdef HAVE_DETAILED_TIMINGS
...
...
@@ -146,8 +146,8 @@ subroutine solve_tridi_&
nev1 = MIN(nev,l_cols)
endif
call solve_tridi_col_&
&PRECISION&
&_impl
(l_cols, nev1, nc, d(nc+1), e(nc+1), q, ldq, nblk, &
&PRECISION
_AND_SUFFIX
&
(l_cols, nev1, nc, d(nc+1), e(nc+1), q, ldq, nblk, &
matrixCols, mpi_comm_rows, wantDebug, success)
if (.not.(success)) then
call timer%stop("solve_tridi" // PRECISION_SUFFIX)
...
...
@@ -349,12 +349,11 @@ subroutine solve_tridi_&
&PRECISION
end subroutine solve_tridi_&
&PRECISION&
&_impl
&PRECISION_AND_SUFFIX
subroutine solve_tridi_col_&
&PRECISION&
&_impl
( na, nev, nqoff, d, e, q, ldq, nblk, matrixCols, mpi_comm_rows, wantDebug, success )
&PRECISION
_AND_SUFFIX
&
( na, nev, nqoff, d, e, q, ldq, nblk, matrixCols, mpi_comm_rows, wantDebug, success )
! Solves the symmetric, tridiagonal eigenvalue problem on one processor column
! with the divide and conquer method.
...
...
@@ -451,9 +450,8 @@ subroutine solve_tridi_&
nlen = limits(n+1)-noff ! Size of subproblem
call solve_tridi_single_problem_&
&PRECISION&
&_impl &
(nlen,d(noff+1),e(noff+1), &
&PRECISION_AND_SUFFIX &
(nlen,d(noff+1),e(noff+1), &
q(nqoff+noff+1,noff+1),ubound(q,dim=1), wantDebug, success)
if (.not.(success)) return
...
...
@@ -483,9 +481,8 @@ subroutine solve_tridi_&
noff = limits(my_prow) ! Start of subproblem
nlen = limits(my_prow+1)-noff ! Size of subproblem
call solve_tridi_single_problem_&
&PRECISION&
&_impl &
(nlen,d(noff+1),e(noff+1),qmat1, &
&PRECISION_AND_SUFFIX &
(nlen,d(noff+1),e(noff+1),qmat1, &
ubound(qmat1,dim=1), wantDebug, success)
if (.not.(success)) return
...
...
@@ -580,12 +577,11 @@ subroutine solve_tridi_&
call timer%stop("solve_tridi_col" // PRECISION_SUFFIX)
end subroutine solve_tridi_col_&
&PRECISION&
&_impl
&PRECISION_AND_SUFFIX
recursive subroutine solve_tridi_single_problem_&
&PRECISION&
&_impl
(nlen, d, e, q, ldq, wantDebug, success)
&PRECISION
_AND_SUFFIX
&
(nlen, d, e, q, ldq, wantDebug, success)
! Solves the symmetric, tridiagonal eigenvalue problem on a single processor.
! Takes precautions if DSTEDC fails or if the eigenvalues are not ordered correctly.
...
...
@@ -712,6 +708,5 @@ subroutine solve_tridi_&
call timer%stop("solve_tridi_single" // PRECISION_SUFFIX)
end subroutine solve_tridi_single_problem_&
&PRECISION&
&_impl
&PRECISION_AND_SUFFIX
src/elpa1/elpa1_solve_tridi_real_template_legacy.X90
deleted
100644 → 0
View file @
bd0fa35b
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment