Test if two memtypes are equal
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(dbcsr_memtype_type), | intent(in) | :: | mt1 | |||
type(dbcsr_memtype_type), | intent(in) | :: | mt2 |
FUNCTION dbcsr_memtype_equal(mt1, mt2) RESULT(res) !! Test if two memtypes are equal TYPE(dbcsr_memtype_type), INTENT(in) :: mt1, mt2 LOGICAL :: res res = (mt1%mpi .EQV. mt2%mpi) .AND. & (mt1%acc_hostalloc .EQV. mt2%acc_hostalloc) .AND. & (mt1%acc_devalloc .EQV. mt2%acc_devalloc) .AND. & (ASSOCIATED(mt1%pool) .EQV. ASSOCIATED(mt2%pool)) .AND. & (.NOT. ASSOCIATED(mt1%pool) .OR. ASSOCIATED(mt1%pool, mt2%pool)) END FUNCTION dbcsr_memtype_equal