dimanche 1 mars 2015

Is it possible that memcpy/memset can be block or lock in window server?


I developed a sever code using c++ in windows server 2008. This application blocked (or locked) everyday one or two times, so i have to restart this process. I made a full dump file when the process blocked, analyze the dump file using windbg, then I'm so confused. Because block(lock or hang) point is memcpy/memset. Is it possible????


Here is the stackcall in windbg.



DEFAULT_BUCKET_ID: APPLICATION_HANG_BusyHang

PRIMARY_PROBLEM_CLASS: APPLICATION_HANG_BusyHang

LAST_CONTROL_TRANSFER: from 0042143c to 733674a0

STACK_TEXT:
0379f858 0042143c 02ed86a0 02ed86a0 00002ff0 msvcr80!_VEC_memcpy+0x7c
0379f870 00565f7d 02f072a8 0379fa84 005660fb RelaySvr!ArrayBuffer::flip+0x3c
0379f87c 005660fb 00000000 a656c112 00000000 RelaySvr!CMParser::JBufferDrop+0x2d
0379fa84 0041d138 02df8084 00000fff a656c0fa RelaySvr!CMParser::Parse+0x14b
0379fdd0 00564b3f 02e9f004 02e96d9c 00001015 RelaySvr!MainFactory::Critical_ClientMsg+0x37
0379fdf8 1007a797 00000344 0379fe7c 0241ec40 RelaySvr!ReadHandler::handle_input+0x12f
WARNING: Stack unwind information not available. Following frames may be wrong.
0379fe10 1007a86e 0379fe28 00000001 0241ec40 ACE_5_8_3!ACE_TP_Reactor::dispatch_socket_event+0x27
00000000 00000000 00000000 00000000 00000000 ACE_5_8_3!ACE_TP_Reactor::handle_socket_events+0xbe


ArrayBuffer::flip() function work like this.



{
if ( m_ReadPointer < m_WritePointer )
{
memmove(m_Buffer, (m_Buffer + m_ReadPointer), sizeof(char) * (m_WritePointer m_ReadPointer));
}

m_WritePointer -= m_ReadPointer;
if ( m_WritePointer < 0 )
{
m_WritePointer = 0;
}

m_ReadPointer = 0;
}


And, This is a MS DebugDiag Analysis Result.



Thread 10 - System ID 5684

Entry point msvcr80!_threadstartex
Create time 2015-02-13 PM 11:11:46
Time spent in user mode 1 Days 22:09:57.599
Time spent in kernel mode 0 Days 00:00:00.062


This thread is not fully resolved and may or may not be a problem. Further analysis of these threads may be required.


Is it possible can be blocked memcpy??? Could be plz give me some idea??




Aucun commentaire:

Enregistrer un commentaire