multhread coredumps
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 > multhread coredumps




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

    multhread coredumps  
mike


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


 
12-17-04 12:45 AM

Hi,
I have strange problem on UnixWare system:
Let's consider simple two threads program:
- two threads, each executes the function:
while(1)
{
string s="something";
s+=:"foo";
map<string, integer> mp;
//some operations on mp;
//calling poll function to sleep for 100ms
}

If I exectue one instance of this program everything works OK.
But when I execute two or more instances all of them coredumps.
The examination of the stacks indicates that in the funtion  block() SIGSEGV
was received.
I used the truss command and just before the crush function prepblock()
failes (EINVAL).
The situation is strange, because if I remove the operations on string and
map it works.
Moreover it also works when I don't call poll fuction.
But when there are both it fails....
This problem only appears on HP platform (I check two machines).
Program was compiled by g++ ver 2.65 or something.
If those troubles are caused by string or map why it works well on single
process instance ??

Btw. Do you know what for are the funcitons (I suppose kernel function):
block(), prepblock(), unblock() ?

Regards








[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 01:00 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