[petsc-users] Pthread support

Alexander Goncharov alexvg77 at gmail.com
Tue Jul 24 13:26:10 CDT 2012


Shri,

thank you for your answers. I think the current affinity settings
explain my problem. It basically means that I can run only one job per
node if I compile with pthreadclasses=1. It is not optimal if I have
motherboard with two CPU sockets, isn't it? Are you planning to change
it in the next release. How can I know, when it is changed in the
petsc-dev? I used petsc-3.3.

best regards,
Alex. 

On Mon, 2012-07-23 at 23:46 -0700, Shri wrote:
> The current "crude" default affinity setting is that for each process the first thread gets assigned to core number 0, second to core number 1, and so on (assuming that the OS numbers the cores sequentially).  However, the OS could number the cores differently. For example on Intel Nehalem Architecture, cores on one socket have even numbers (0,2,4,6) and that on the other socket have odd (1,3,5,7). We currently don't have any mechanism by which we can figure out how the OS numbers the cores and set affinity accordingly.
> 
> Shri
> 
> On Jul 23, 2012, at 8:33 PM, Barry Smith wrote:
> 
> > 
> > On Jul 23, 2012, at 10:22 PM, Jed Brown wrote:
> > 
> >> On Mon, Jul 23, 2012 at 10:19 PM, Barry Smith <bsmith at mcs.anl.gov> wrote:
> >> Yes, but is PETSc built with MPI?  PETSc does not decide on which core to run the program, but MPI might.
> >> 
> >> Well, PETSc is setting affinity if it can when you use threads.
> > 
> >  Jed,
> > 
> >   So maybe that is the problem. PETSc is forcing affinity to a hardware number core regardless of whether another PETSc program is running and has also forced that same core?
> > 
> >   Barry
> > 
> > 
> > 
> > 
> 




More information about the petsc-users mailing list