Slow assembly

John R. Wicks jwicks at cs.brown.edu
Fri Oct 26 13:56:15 CDT 2007


I am working on computing PageRank for a web scale graph which uses a square
matrix which is 1.2x10^8 dimensional with about 10^9 entries.  I have
partitioned the matrix for 32 processors myself into my own ascii format,
and I know the memory allocation, so I:

1) create the matrix with "A = MatCreateMPIAIJ(*n, *n, *N, *N, 0, nnz, 0,
onnz)", 
2) load the entries by repeatedly calling
"MatSetValues(A,1,&row,links,cols,vals,INSERT_VALUES)", and 
3) call MatAssemblyBegin/End.

Steps 1 and 2 complete in a couple minutes, but step 3 is taking several
hours.  What is going on?  Is there a way to speed up matrix assembly?

Thanks,
John




More information about the petsc-users mailing list