<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div class=""><br class=""></div>  Please send -log_view for the ilu and GAMG case.<div class=""><br class=""></div><div class="">  Barry</div><div class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Apr 12, 2021, at 10:34 AM, Milan Pelletier via petsc-users <<a href="mailto:petsc-users@mcs.anl.gov" class="">petsc-users@mcs.anl.gov</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Dear all,<br class=""></div><div class=""><br class=""></div><div class="">I am currently trying to use PETSc with CG solver and GAMG preconditioner.<br class=""></div><div class="">I have started with the following set of parameters:<br class=""></div><div class="">-ksp_type cg<br class=""></div><div class="">-pc_type gamg<br class=""></div><div class="">-pc_gamg_agg_nsmooths 1 <br class=""></div><div class="">-pc_gamg_threshold 0.02 <br class=""></div><div class="">-mg_levels_ksp_type chebyshev <br class=""></div><div class="">-mg_levels_pc_type sor <br class=""></div><div class="">-mg_levels_ksp_max_it 2<b class=""><br class=""></b></div><div class=""><br class=""></div><div class="">Unfortunately, the preconditioning seems to run extremely slowly. I tried to play around with the numbers, to check if I could notice some difference, but could not observe significant changes. <br class=""></div><div class="">As a comparison, the KSPSetup call with GAMG PC takes more than 10 times longer than completing the whole computation (preconditioning + ~400 KSP iterations to convergence) of the similar case using the following parameters :<br class=""></div><div class="">-ksp_type cg<br class=""></div><div class="">-pc_type ilu<br class=""></div><div class="">-pc_factor_levels 0<br class=""></div><div class=""><br class=""></div><div class="">The matrix size for my case is ~1,850,000*1,850,000 elements, with ~38,000,000 non-zero terms (i.e. ~20 per row). For both ILU and AMG cases I use matseqaij/vecseq storage (as a first step I work with only 1 MPI process).<br class=""></div><div class=""><br class=""></div><div class="">Is there something wrong in the parameter set I have been using?<br class=""></div><div class="">I understand that the preconditioning overhead with AMG is higher than with ILU, but I would also expect CG/GAMG to be competitive against CG/ILU, especially considering the relatively big problem size.<br class=""></div><div class=""><br class=""></div><div class="">For information, I am using the PETSc version built from commit 6840fe907c1a3d26068082d180636158471d79a2 (release branch from April 7, 2021). <br class=""></div><div class=""><br class=""></div><div class="">Any clue or idea would be greatly appreciated!<br class=""></div><div class="">Thanks for your help,<br class=""></div><div class=""><br class=""></div><div class="">Best regards,<br class=""></div><div class="protonmail_signature_block"><div class="protonmail_signature_block-user"><div class=""><span style="color:rgb(107, 107, 107)" class="">Milan Pelletier</span><br class=""></div></div><div class="protonmail_signature_block-proton protonmail_signature_block-empty"><br class=""></div></div><div class=""><br class=""></div></div></blockquote></div><br class=""></div></body></html>