[petsc-users] Pthread support

Barry Smith bsmith at mcs.anl.gov
Tue Jul 24 13:44:59 CDT 2012


  Shri,

    For now you could simply turn off setting affinities when only a single thread is requested. 

   Thanks

     Barry

On Jul 24, 2012, at 1:46 AM, 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