Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
elpa
elpa
Commits
23db9fa2
Commit
23db9fa2
authored
Mar 15, 2019
by
Pavel Kus
Browse files
legacy_api removed from the index
parent
20804b84
Changes
7
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/elpa1/legacy_interface/elpa_cholesky_template.F90
View file @
23db9fa2
...
...
@@ -120,12 +120,6 @@
stop
endif
call
e
%
set
(
"legacy_api"
,
1
,
error
)
if
(
error
.ne.
ELPA_OK
)
then
print
*
,
"Problem setting option. Aborting..."
stop
1
endif
!! the elpa object needs nev to be set (in case the EVP-solver is
!! called later. Thus it is set by user, do nothing, otherwise,
!! set it to na as default
...
...
@@ -133,6 +127,8 @@
! call e%set("nev", na)
!endif
call
e
%
creating_from_legacy_api
()
if
(
e
%
setup
()
.ne.
ELPA_OK
)
then
print
*
,
"Cannot setup ELPA instance"
success
=
.false.
...
...
src/elpa1/legacy_interface/elpa_invert_trm.F90
View file @
23db9fa2
...
...
@@ -143,12 +143,8 @@
print
*
,
"Problem setting option. Aborting..."
stop
endif
call
e
%
set
(
"legacy_api"
,
1
,
error
)
if
(
error
.ne.
ELPA_OK
)
then
print
*
,
"Problem setting option. Aborting..."
stop
endif
call
e
%
creating_from_legacy_api
()
if
(
e
%
setup
()
.ne.
ELPA_OK
)
then
print
*
,
"Cannot setup ELPA instance"
...
...
@@ -156,6 +152,7 @@
return
endif
if
(
wantDebug
)
then
call
e
%
set
(
"debug"
,
1
,
error
)
if
(
error
.ne.
ELPA_OK
)
then
...
...
src/elpa1/legacy_interface/elpa_multiply_a_b.F90
View file @
23db9fa2
...
...
@@ -158,11 +158,7 @@
stop
endif
call
e
%
set
(
"legacy_api"
,
1
,
error
)
if
(
error
.ne.
ELPA_OK
)
then
print
*
,
"Problem setting option. Aborting..."
stop
1
endif
call
e
%
creating_from_legacy_api
()
if
(
e
%
setup
()
.ne.
ELPA_OK
)
then
print
*
,
"Cannot setup ELPA instance"
...
...
src/elpa1/legacy_interface/elpa_solve_tridi.F90
View file @
23db9fa2
...
...
@@ -134,11 +134,8 @@
print
*
,
"Problem setting option. Aborting..."
stop
endif
call
obj
%
set
(
"legacy_api"
,
1
,
error
)
if
(
error
.ne.
ELPA_OK
)
then
print
*
,
"Problem setting option. Aborting..."
stop
endif
call
obj
%
creating_from_legacy_api
()
if
(
obj
%
setup
()
.ne.
ELPA_OK
)
then
print
*
,
"Cannot setup ELPA instance"
...
...
src/elpa_api.F90
View file @
23db9fa2
...
...
@@ -99,6 +99,10 @@ module elpa_api
procedure
(
elpa_is_set_i
),
deferred
,
public
::
is_set
!< method to check whether key/value is set
procedure
(
elpa_can_set_i
),
deferred
,
public
::
can_set
!< method to check whether key/value can be set
! call before setup if created from the legacy api
! remove this function completely after the legacy api is dropped
procedure
(
elpa_creating_from_legacy_api_i
),
deferred
,
public
::
creating_from_legacy_api
! Timer
procedure
(
elpa_get_time_i
),
deferred
,
public
::
get_time
!< method to get the times from the timer object
procedure
(
elpa_print_times_i
),
deferred
,
public
::
print_times
!< method to print the timings tree
...
...
@@ -773,6 +777,14 @@ module elpa_api
end
interface
#endif
abstract
interface
subroutine
elpa_creating_from_legacy_api_i
(
self
)
import
elpa_t
implicit
none
class
(
elpa_t
),
intent
(
inout
)
::
self
end
subroutine
end
interface
contains
...
...
src/elpa_impl.F90
View file @
23db9fa2
...
...
@@ -73,6 +73,9 @@ module elpa_impl
private
integer
::
communicators_owned
!This object has been created through the legacy api.
integer
::
from_legacy_api
!> \brief methods available with the elpa_impl_t type
contains
!> \brief the puplic methods
...
...
@@ -86,6 +89,9 @@ module elpa_impl
procedure
,
public
::
can_set
=>
elpa_can_set
!< a method to check whether a key/value pair can be set : implemented
!< in elpa_can_set
! call before setup if created from the legacy api
! remove this function completely after the legacy api is dropped
procedure
,
public
::
creating_from_legacy_api
=>
elpa_creating_from_legacy_api
! timer
procedure
,
public
::
get_time
=>
elpa_get_time
...
...
@@ -187,10 +193,13 @@ module elpa_impl
#endif
integer
::
error2
allocate
(
obj
,
stat
=
error2
)
if
(
error2
.ne.
0
)
then
write
(
error_unit
,
*
)
"elpa_allocate(): could not allocate object"
endif
endif
obj
%
from_legacy_api
=
0
! check whether init has ever been called
if
(
elpa_initialized
()
.ne.
ELPA_OK
)
then
...
...
@@ -514,7 +523,7 @@ module elpa_impl
#ifdef WITH_MPI
integer
::
mpi_comm_parent
,
mpi_comm_rows
,
mpi_comm_cols
,
np_rows
,
np_cols
,
my_id
,
&
mpierr
,
mpierr2
,
process_row
,
process_col
,
mpi_string_length
,
&
present_np_rows
,
present_np_cols
,
np_total
,
legacy_api
present_np_rows
,
present_np_cols
,
np_total
character
(
len
=
MPI_MAX_ERROR_STRING
)
::
mpierr_string
character
(
*
),
parameter
::
MPI_CONSISTENCY_MSG
=
&
"Provide mpi_comm_parent and EITHER process_row and process_col OR mpi_comm_rows and mpi_comm_cols. Aborting..."
...
...
@@ -546,11 +555,6 @@ module elpa_impl
! inconsistencies and is rather natural from the user point of view
#ifdef WITH_MPI
if
(
self
%
is_set
(
"legacy_api"
)
==
1
)
then
call
self
%
get
(
"legacy_api"
,
legacy_api
,
error
)
if
(
check_elpa_get
(
error
,
ELPA_ERROR_SETUP
))
return
endif
if
(
self
%
is_set
(
"mpi_comm_parent"
)
==
1
)
then
call
self
%
get
(
"mpi_comm_parent"
,
mpi_comm_parent
,
error
)
if
(
check_elpa_get
(
error
,
ELPA_ERROR_SETUP
))
return
...
...
@@ -563,7 +567,7 @@ module elpa_impl
call
self
%
set
(
"num_processes"
,
np_total
,
error
)
if
(
check_elpa_set
(
error
,
ELPA_ERROR_SETUP
))
return
else
if
(
legacy_api
.ne.
1
)
then
if
(
self
%
from_
legacy_api
.ne.
1
)
then
write
(
error_unit
,
*
)
MPI_CONSISTENCY_MSG
error
=
ELPA_ERROR
return
...
...
@@ -676,7 +680,7 @@ module elpa_impl
if
(
check_elpa_set
(
error
,
ELPA_ERROR_SETUP
))
return
endif
if
(
legacy_api
.ne.
1
)
then
if
(
self
%
from_
legacy_api
.ne.
1
)
then
if
(
np_total
.ne.
np_rows
*
np_cols
)
then
print
*
,
"MPI parent communicator and row/col communicators do not match. Aborting..."
stop
...
...
@@ -1735,4 +1739,10 @@ module elpa_impl
return
end
function
subroutine
elpa_creating_from_legacy_api
(
self
)
implicit
none
class
(
elpa_impl_t
),
intent
(
inout
)
::
self
self
%
from_legacy_api
=
1
end
subroutine
end
module
src/elpa_index.c
View file @
23db9fa2
...
...
@@ -187,7 +187,6 @@ static const elpa_index_int_entry_t int_entries[] = {
INT_ANY_ENTRY
(
"mpi_comm_cols"
,
"Communicator for inter-column communication"
,
PRINT_NO
),
INT_ANY_ENTRY
(
"mpi_comm_parent"
,
"Parent communicator"
,
PRINT_NO
),
INT_ANY_ENTRY
(
"blacs_context"
,
"BLACS context"
,
PRINT_NO
),
INT_ANY_ENTRY
(
"legacy_api"
,
"This object has been created through the legacy api. Parameter for internal use only"
,
PRINT_NO
),
INT_ENTRY
(
"solver"
,
"Solver to use"
,
ELPA_SOLVER_1STAGE
,
ELPA_AUTOTUNE_FAST
,
ELPA_AUTOTUNE_DOMAIN_ANY
,
\
number_of_solvers
,
solver_enumerate
,
solver_is_valid
,
elpa_solver_name
,
PRINT_YES
),
INT_ENTRY
(
"gpu"
,
"Use GPU acceleration"
,
0
,
ELPA_AUTOTUNE_MEDIUM
,
ELPA_AUTOTUNE_DOMAIN_ANY
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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