Re: pthreads

From: Paul H. Hargrove (PHHargrove_at_lbl_dot_gov)
Date: Fri Feb 13 2009 - 13:24:52 PST

  • Next message: Tahar Amari: "pthreads and UPC ...."
    Tahar,
      I regret that nobody appears to have replied to your questions yet (or 
    did not cc:ed the list if they did).
      The answer to your question is not a simple "Yes", but more a "probably".
    
      Out runtime can optionally use pthreads internally for implementing 
    UPC threads within a single node, both with and without a network.  So, 
    there is no fundamental problem with linking the pthreads libraries.  
    Additionally, I am aware of at least on project that uses pthreads in 
    *addition* to UPC threads (as I suspect you are asking).  In that case, 
    each individual UPC thread retains its own identity and can spawn 
    pthreads to execute C (or C++ or FORTRAN, I suppose) code, but the 
    pthreads spawned by the user code cannot execute UPC code because they 
    do not correspond to any MYTHREAD value.
      If you have more specific information about how you wish to mix 
    pthreads with UPC, let us know and we might be able to clarify further.
    
    -Paul
    
    Tahar Amari wrote:
    > Hello,
    >
    > One of my code use Pthreads.
    > Is it possible to still use this piece of code with UPC ?
    >
    > Many thanks
    >
    > Tahar
    
    
    -- 
    Paul H. Hargrove                          PHHargrove_at_lbl_dot_gov
    Future Technologies Group                 Tel: +1-510-495-2352
    HPC Research Department                   Fax: +1-510-486-6900
    Lawrence Berkeley National Laboratory     
    

  • Next message: Tahar Amari: "pthreads and UPC ...."