mmap in a thread?
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Programming > mmap in a thread?




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    mmap in a thread?  
sgsnewsgrp@gmail.com


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-28-07 12:21 AM


Does anyone know if mmap is thread safe? I didn't catch any thread
references in the man page.

I'm using mmap on a local file which is read into memory for searching
- no updates

Thanks






[ Post a follow-up to this message ]



    Re: mmap in a thread?  
Scott Lurndal


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-28-07 06:24 AM

sgsnewsgrp@gmail.com writes:
>
>Does anyone know if mmap is thread safe? I didn't catch any thread
>references in the man page.
>
>I'm using mmap on a local file which is read into memory for searching
>- no updates
>
>Thanks
>

Yes, it is safe.  Do be aware that it is up to the application to arbitrate
access to the mapped pages.

scott





[ Post a follow-up to this message ]



    Re: mmap in a thread?  
sgsnewsgrp@gmail.com


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-31-07 12:19 AM

> Yes, it is safe.  Do be aware that it is up to the application to arbitrate
> access to the mapped pages.

Each mapped file is accessed at most by a single thread so I should
not have any issues

Thanks






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 07:59 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register