Fix use of remap

This commit is contained in:
sfilippone
2026-04-15 15:13:04 +02:00
parent 0e1d7de857
commit b1c4b08d6e
12 changed files with 20 additions and 21 deletions
+3 -3
View File
@@ -491,7 +491,7 @@ subroutine amg_c_hierarchy_bld(a,desc_a,prec,info,cpymat)
!write(0,*) 'Should we remap? '
if (amg_get_do_remap().and.(np>=4)) then
write(0,*) 'Going for remapping '
!!$ write(0,*) 'Going for remapping '
if (.true.) then
associate(lv=>prec%precv(iszv), rmp => prec%precv(iszv)%remap_data)
call lv%desc_ac%clone(rmp%desc_ac_pre_remap,info)
@@ -503,8 +503,8 @@ subroutine amg_c_hierarchy_bld(a,desc_a,prec,info,cpymat)
call psb_remap(np/2,rmp%desc_ac_pre_remap,rmp%ac_pre_remap,&
& rmp%idest,rmp%isrc,rmp%nrsrc,rmp%naggr,lv%desc_ac,lv%ac,info)
end if
write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
& lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
!!$ write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
!!$ & lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
lv%linmap%naggr(:) = rmp%naggr(:)
lv%linmap%p_desc_V => rmp%desc_ac_pre_remap
lv%base_a => lv%ac
+3 -4
View File
@@ -434,7 +434,6 @@ subroutine amg_d_hierarchy_bld(a,desc_a,prec,info,cpymat)
& ilaggr,nlaggr,op_prol,info)
if (do_timings) call psb_toc(idx_matasb)
end if
if (info /= psb_success_) then
write(ch_err,'(a,i7)') 'Mat asb fail @ level ',i
call psb_errpush(psb_err_internal_error_,name,&
@@ -492,7 +491,7 @@ subroutine amg_d_hierarchy_bld(a,desc_a,prec,info,cpymat)
!write(0,*) 'Should we remap? '
if (amg_get_do_remap().and.(np>=4)) then
write(0,*) 'Going for remapping '
!!$ write(0,*) 'Going for remapping '
if (.true.) then
associate(lv=>prec%precv(iszv), rmp => prec%precv(iszv)%remap_data)
call lv%desc_ac%clone(rmp%desc_ac_pre_remap,info)
@@ -504,8 +503,8 @@ subroutine amg_d_hierarchy_bld(a,desc_a,prec,info,cpymat)
call psb_remap(np/2,rmp%desc_ac_pre_remap,rmp%ac_pre_remap,&
& rmp%idest,rmp%isrc,rmp%nrsrc,rmp%naggr,lv%desc_ac,lv%ac,info)
end if
write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
& lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
!!$ write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
!!$ & lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
lv%linmap%naggr(:) = rmp%naggr(:)
lv%linmap%p_desc_V => rmp%desc_ac_pre_remap
lv%base_a => lv%ac
+3 -3
View File
@@ -491,7 +491,7 @@ subroutine amg_s_hierarchy_bld(a,desc_a,prec,info,cpymat)
!write(0,*) 'Should we remap? '
if (amg_get_do_remap().and.(np>=4)) then
write(0,*) 'Going for remapping '
!!$ write(0,*) 'Going for remapping '
if (.true.) then
associate(lv=>prec%precv(iszv), rmp => prec%precv(iszv)%remap_data)
call lv%desc_ac%clone(rmp%desc_ac_pre_remap,info)
@@ -503,8 +503,8 @@ subroutine amg_s_hierarchy_bld(a,desc_a,prec,info,cpymat)
call psb_remap(np/2,rmp%desc_ac_pre_remap,rmp%ac_pre_remap,&
& rmp%idest,rmp%isrc,rmp%nrsrc,rmp%naggr,lv%desc_ac,lv%ac,info)
end if
write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
& lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
!!$ write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
!!$ & lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
lv%linmap%naggr(:) = rmp%naggr(:)
lv%linmap%p_desc_V => rmp%desc_ac_pre_remap
lv%base_a => lv%ac
+3 -3
View File
@@ -491,7 +491,7 @@ subroutine amg_z_hierarchy_bld(a,desc_a,prec,info,cpymat)
!write(0,*) 'Should we remap? '
if (amg_get_do_remap().and.(np>=4)) then
write(0,*) 'Going for remapping '
!!$ write(0,*) 'Going for remapping '
if (.true.) then
associate(lv=>prec%precv(iszv), rmp => prec%precv(iszv)%remap_data)
call lv%desc_ac%clone(rmp%desc_ac_pre_remap,info)
@@ -503,8 +503,8 @@ subroutine amg_z_hierarchy_bld(a,desc_a,prec,info,cpymat)
call psb_remap(np/2,rmp%desc_ac_pre_remap,rmp%ac_pre_remap,&
& rmp%idest,rmp%isrc,rmp%nrsrc,rmp%naggr,lv%desc_ac,lv%ac,info)
end if
write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
& lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
!!$ write(0,*) me,' Out of remapping ',rmp%desc_ac_pre_remap%get_fmt(),' ',&
!!$ & lv%desc_ac%get_fmt(),sum(lv%linmap%naggr),sum(rmp%naggr)
lv%linmap%naggr(:) = rmp%naggr(:)
lv%linmap%p_desc_V => rmp%desc_ac_pre_remap
lv%base_a => lv%ac
@@ -125,7 +125,7 @@ subroutine amg_c_base_onelev_map_prol_a(lv,alpha,v,beta,u,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap P handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_V2U(alpha,v,beta,u,info,&
@@ -119,7 +119,7 @@ subroutine amg_c_base_onelev_map_rstr_a(lv,alpha,u,beta,v,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap R handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_U2V(alpha,u,beta,v,info,&
@@ -125,7 +125,7 @@ subroutine amg_d_base_onelev_map_prol_a(lv,alpha,v,beta,u,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap P handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_V2U(alpha,v,beta,u,info,&
@@ -119,7 +119,7 @@ subroutine amg_d_base_onelev_map_rstr_a(lv,alpha,u,beta,v,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap R handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_U2V(alpha,u,beta,v,info,&
@@ -125,7 +125,7 @@ subroutine amg_s_base_onelev_map_prol_a(lv,alpha,v,beta,u,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap P handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_V2U(alpha,v,beta,u,info,&
@@ -119,7 +119,7 @@ subroutine amg_s_base_onelev_map_rstr_a(lv,alpha,u,beta,v,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap R handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_U2V(alpha,u,beta,v,info,&
@@ -125,7 +125,7 @@ subroutine amg_z_base_onelev_map_prol_a(lv,alpha,v,beta,u,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap P handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_V2U(alpha,v,beta,u,info,&
@@ -119,7 +119,7 @@ subroutine amg_z_base_onelev_map_rstr_a(lv,alpha,u,beta,v,info,work)
!
! Remap has happened, deal with it
!
write(0,*) 'Remap handling not implemented yet '
write(0,*) 'Remap R handling not implemented yet for A'
else
! Default transfer
call lv%linmap%map_U2V(alpha,u,beta,v,info,&