Matlab Crash

2 views (last 30 days)
Ten Tan
Ten Tan on 2 Aug 2011
Hi, whenever I try to run a program, my Matlab has been crashed. Stack trace are as follows:
MATLAB crash file:C:\DOCUME~1\user\LOCALS~1\Temp\matlab_crash_dump.2560
------------------------------------------------------------------------
Segmentation violation detected at Mon Aug 01 20:42:10 2011
------------------------------------------------------------------------
Configuration:
MATLAB Version: 7.9.0.529 (R2009b)
MATLAB License: 161051
Operating System: Microsoft Windows XP
Window System: Version 5.1 (Build 2600: Service Pack 2)
Processor ID: x86 Family 6 Model 7 Stepping 10, GenuineIntel
Virtual Machine: Java 1.6.0_12-b04 with Sun Microsystems Inc. Java HotSpot(TM) Client VM mixed mode
Default Encoding: windows-1252
Fault Count: 1
Register State:
EAX = 00001b7f EBX = 182ba4d0
ECX = 23e7af70 EDX = 00000257
ESI = 00000000 EDI = 00c3c33a
EBP = 00c3c354 ESP = 00c3c2f8
EIP = 0eab0000 FLG = 00210212
Stack Trace:
[0] 0x0eab0000(0x182ba4d0, 0x36ee0030, 0x22541540, 300)
[1] fast_kmeans_step.mexw32:0x1eab179d(4, 0x00c3cb38, 4, 0x00c3caa8)
[2] libmex.dll:_mexRunMexFile(4, 0x00c3cb38, 4, 0x00c3caa8) + 132 bytes
[3] libmex.dll:private: void __thiscall Mfh_mex::runMexFileWithSignalProtection(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(4, 0x00c3cb38, 4, 0x00c3caa8) + 73 bytes
[4] libmex.dll:public: virtual void __thiscall Mfh_mex::dispatch_file(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(4, 0x00c3cb38, 4, 0x00c3caa8) + 321 bytes
[5] m_dispatcher.dll:public: virtual void __thiscall Mfh_file::dispatch_fh(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(4, 0x00c3cb38, 4, 0x00c3caa8) + 204 bytes
[6] m_interpreter.dll:public: void __thiscall ResolverFunctionDesc::CallFunction(int,struct mxArray_tag * * const,int,struct mxArray_tag * * const)(4, 0x00c3cb38, 4, 0x00c3d2f8 "øÕÃ") + 81 bytes
[7] m_interpreter.dll:public: bool __thiscall Resolver::CallMFunction(int,int,class _m_operand * const,union m_operand_storage *,int,class _m_operand * const,union m_operand_storage *,int *)(4, 4, 0x21d84de0, 4) + 1213 bytes
[8] m_interpreter.dll:private: bool __thiscall accelImpl::MFunctionCall(struct _accelOp * *)(0x00c3d30c, 0xffffffff, 0x1af72260, 0x23d47640) + 544 bytes
[9] m_interpreter.dll:public: enum jitReturnFlags __thiscall accelImpl::Exec(void)(0x00c3d2f8 "øÕÃ", 0xffffffff, 0xffffffff, 0x23d47640) + 170 bytes
[10] m_interpreter.dll:public: enum jitReturnFlags __thiscall accelCode::Call(enum inMarshalType *,int *)const (0x00c3d5d4, 0xffffffff, 0, 0) + 133 bytes
[11] m_interpreter.dll:public: static bool __cdecl inJit::ExecuteHotSegment(struct _inJitAccelInfo *,enum opcodes *,int *,int *)(0x00c3d7f4 "@1Ä#¬ØÃ", 0x00c3d940, 0x00c3d8e0, 0x00c3dabc) + 2532 bytes
[12] m_interpreter.dll:int __cdecl inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag volatile *,int *)(1, 2515, 141, 0) + 810 bytes
[13] m_interpreter.dll:int __cdecl protected_inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 2515, 59, 0) + 39 bytes
[14] m_interpreter.dll:int __cdecl inInterPcodeSJ(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 2515, 59, 0) + 251 bytes
[15] m_interpreter.dll:int __cdecl inExecuteMFunctionOrScript(class Mfh_mp *,bool)(0x78134c00, 0xffffffff, 0x23c43140, 1) + 924 bytes
[16] m_interpreter.dll:void __cdecl inRunMfile(int,struct mxArray_tag * *,int,struct mxArray_tag * *,class Mfh_mp *,struct inWorkSpace_tag *)(1, 0x00c3ddec, 2, 0x00c3de4c) + 466 bytes
[17] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(struct _mdUnknown_workspace *,int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 1, 0x00c3ddec, 2) + 23 bytes
[18] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(1, 0x00c3ddec, 2, 0x00c3de4c) + 25 bytes
[19] m_dispatcher.dll:public: virtual void __thiscall Mfh_file::dispatch_fh(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(1, 0x00c3ddec, 2, 0x00c3de4c) + 204 bytes
[20] m_interpreter.dll:int __cdecl inDispatchFromStack(int,char const *,int,int)(1082, 0x22528b3c "ss_kmeans", 1, 2) + 623 bytes
[21] m_interpreter.dll:int __cdecl inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag volatile *,int *)(1, 1205, 81, 0) + 1295 bytes
[22] m_interpreter.dll:int __cdecl protected_inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 1205, 45, 0) + 39 bytes
[23] m_interpreter.dll:int __cdecl inInterPcodeSJ(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 1205, 45, 0) + 251 bytes
[24] m_interpreter.dll:int __cdecl inExecuteMFunctionOrScript(class Mfh_mp *,bool)(0x78134c00, 0xffffffff, 0x23c42db0, 1) + 924 bytes
[25] m_interpreter.dll:void __cdecl inRunMfile(int,struct mxArray_tag * *,int,struct mxArray_tag * *,class Mfh_mp *,struct inWorkSpace_tag *)(1, 0x00c3e66c, 1, 0x00c3e6cc) + 466 bytes
[26] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(struct _mdUnknown_workspace *,int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 1, 0x00c3e66c, 1) + 23 bytes
[27] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(1, 0x00c3e66c, 1, 0x00c3e6cc) + 25 bytes
[28] m_dispatcher.dll:public: virtual void __thiscall Mfh_file::dispatch_fh(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(1, 0x00c3e66c, 1, 0x00c3e6cc) + 204 bytes
[29] m_interpreter.dll:int __cdecl inDispatchFromStack(int,char const *,int,int)(1080, 0x1a9d7f93 "ss_outliers", 1, 1) + 623 bytes
[30] m_interpreter.dll:_inCallFcnFromReference(0x1b4bd270, 0x1b4a8040, 0, 0x7c90e920) + 80 bytes
[31] m_interpreter.dll:int __cdecl inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag volatile *,int *)(1, 0, 156, 0) + 6204 bytes
[32] m_interpreter.dll:int __cdecl protected_inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 0, 105, 0) + 39 bytes
[33] m_interpreter.dll:int __cdecl inInterPcodeSJ(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 0, 105, 0) + 251 bytes
[34] m_interpreter.dll:int __cdecl inExecuteMFunctionOrScript(class Mfh_mp *,bool)(0x78134c01, 0xffffffff, 0x1b328398, 0) + 924 bytes
[35] m_interpreter.dll:void __cdecl inRunMfile(int,struct mxArray_tag * *,int,struct mxArray_tag * *,class Mfh_mp *,struct inWorkSpace_tag *)(0, 0x00c3ef04, 0, 0x00c3ef64) + 466 bytes
[36] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(struct _mdUnknown_workspace *,int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 0, 0x00c3ef04, 0) + 23 bytes
[37] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 0x00c3ef04, 0, 0x00c3ef64) + 25 bytes
[38] m_dispatcher.dll:public: virtual void __thiscall Mfh_file::dispatch_fh(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 0x00c3ef04, 0, 0x00c3ef64) + 204 bytes
[39] m_interpreter.dll:int __cdecl inDispatchFromStack(int,char const *,int,int)(897, 0, 0, 0) + 623 bytes
[40] m_interpreter.dll:_inCallFcnFromReference(0x1b4bc790, 0x1b4a2a60, 0, 0x011b0000) + 80 bytes
[41] m_interpreter.dll:int __cdecl inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag volatile *,int *)(1, 0, 1, 0) + 6204 bytes
[42] m_interpreter.dll:int __cdecl protected_inInterp(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 0, 1, 0) + 39 bytes
[43] m_interpreter.dll:int __cdecl inInterPcodeSJ(enum inDebugCheck,int,int,enum opcodes,struct inPcodeNest_tag *,int *)(1, 0, 1, 0) + 251 bytes
[44] m_interpreter.dll:int __cdecl inExecuteMFunctionOrScript(class Mfh_mp *,bool)(0x011b0001, 0xffffffff, 0x1b505ed8, 0) + 924 bytes
[45] m_interpreter.dll:void __cdecl inRunMfile(int,struct mxArray_tag * *,int,struct mxArray_tag * *,class Mfh_mp *,struct inWorkSpace_tag *)(0, 0x00c3f988, 0, 0) + 466 bytes
[46] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(struct _mdUnknown_workspace *,int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 0, 0x00c3f988, 0) + 23 bytes
[47] m_interpreter.dll:public: virtual void __thiscall Mfh_mp::dispatch_file(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 0x00c3f988, 0, 0) + 25 bytes
[48] m_dispatcher.dll:public: virtual void __thiscall Mfh_file::dispatch_fh(int,struct mxArray_tag * *,int,struct mxArray_tag * *)(0, 0x00c3f988, 0, 0) + 204 bytes
[49] m_interpreter.dll:void __cdecl inEvalPcodeHeaderToWord(struct _memory_context *,int,struct mxArray_tag * * const,struct _pcodeheader *,class Mfh_mp *,unsigned long)(0x7bb796d4, 0, 0x00c3f988, 0x00c3f898) + 73 bytes
[50] m_interpreter.dll:enum inExecutionStatus __cdecl in_local_call_script_function(struct _memory_context *,struct _pcodeheader *,int,struct mxArray_tag * * const,unsigned long,bool)(0x7bb796d4, 0x00c3f898, 0, 0x00c3f988) + 70 bytes
[51] m_interpreter.dll:__catch$??1inProtectHotSegment@@QAE@XZ$0(0x7bb796d4, 0x024f4cf8 "SpikeSortingDemo\n", 0, 0) + 888 bytes
[52] m_interpreter.dll:enum inExecutionStatus __cdecl inEvalCmdWithLocalReturn(char const *,int *,bool,bool,bool (__cdecl*)(void *,char const *))(0x024f4cf8 "SpikeSortingDemo\n", 0, 0, 1) + 80 bytes
[53] m_interpreter.dll:public: virtual enum inExecutionStatus __thiscall InterpBridge::EvalCmdWithLocalReturn(char const *,int *,bool,bool)(0x024f4cf8 "SpikeSortingDemo\n", 0, 0, 1) + 25 bytes
[54] m_interpreter.dll:_inEvalCmdWithLocalReturn(0x024f4cf8 "SpikeSortingDemo\n", 0, 0, 1) + 30 bytes
[55] bridge.dll:enum inExecutionStatus __cdecl evalCommandWithLongjmpSafety(char const *)(0x024f4cf8 "SpikeSortingDemo\n", 0, 0x182ab2c8, 0) + 67 bytes
[56] bridge.dll:__catch$_mnParser$0(0x026a5b78, 0, 0x74730f01, 1) + 300 bytes
[57] mcr.dll:private: void __thiscall mcrInstance::mnParser_on_interpreter_thread(void)(0x182ab300, 0x7ffdf000 "ľÃ", 0x00c3fb3c, 0x77d4ecc3) + 51 bytes
[58] mcr.dll:public: void __thiscall boost::function0<void>::operator()(void)const (0, 0x182ab2c8, 0, 0x182ab2c8) + 63 bytes
[59] mcr.dll:public: virtual void __thiscall mcr::runtime::InterpreterThread::Impl::NoResultInvocationRequest::run(void)(0x7a27a800, 0x7c90e473, 0x00c3fb70, 48) + 53 bytes
[60] mcr.dll:private: static void __cdecl mcr::runtime::InterpreterThread::Impl::invocation_request_handler(int)(0x182ab2c8, 0, 196608, 0x00c3fcb4) + 40 bytes
[61] uiw.dll:bool __cdecl UIW_DispatchUserMessage(int,int)(9225, 0x182ab2c8, 0x00c3fcb4, 9) + 81 bytes
[62] uiw.dll:long __stdcall HandleUserMsgHook(int,unsigned int,long)(0, 1, 0x00c3fcb4, 0x79c73540) + 95 bytes
[63] USER32.dll:0x77d56e46(196608, 1, 0x00c3fcb4, 0x7b38edd0)
[64] USER32.dll:0x77d4ecc3(0x00c3fca4, 0x00c3fcb4, 0x00c3fcd0, 0)
[65] USER32.dll:0x77d56ddb(0x00c3fca4, 48, 196608, 1)
[66] ntdll.dll:0x7c90e473(0x00c3fd20, 0, 0, 0)
[67] uiw.dll:void __cdecl UIW_GetAndDispatchMessage(struct tagMSG *)(0x00c3fd20, 9, 9, 0x182ab2c8) + 20 bytes
[68] uiw.dll:void __cdecl UIW_GetAndDispatchMessage(void)(0x02677cf0, 0, 0x026daca0, 0) + 15 bytes
[69] uiw.dll:void __cdecl ws_ProcessPendingEventsMainLoop(int,bool)(1, 0, 0x00c3fdbc "üýÃ", 0x7a27d26a) + 356 bytes
[70] uiw.dll:void __cdecl ws_ProcessPendingEvents(int,int)(1, 0xffffffff, 0x02677cf0, 0x026daca0) + 14 bytes
[71] mcr.dll:public: void __thiscall mcr::runtime::InterpreterThread::Impl::process_events(class boost::shared_ptr<class mcr::runtime::InterpreterThread::Impl> const &)(0x00c3fe14, 2, 0x026da738, 0x0360dd8c) + 138 bytes
[72] mcr.dll:__catch$?run@Impl@InterpreterThread@runtime@mcr@@QAEKABV?$shared_ptr@VImpl@InterpreterThread@runtime@mcr@@@boost@@PAUinit_context@1234@@Z$0(0x00c3fe14, 0x026dd2b0, 0x7a27d630, 0x026d77b0) + 128 bytes
[73] mcr.dll:unsigned long __cdecl run_init_and_handle_events(void *)(0x0360dd8c, 0, 0x026da6a8, 0) + 76 bytes
[74] mcr.dll:private: void __thiscall mcr::runtime::InterpreterThreadFactory::runThreadFunction(void)(0x00c3fec8, 0x00c3fe80, 0x00c3fe84 "ðþÃ", 0x7bafb34c) + 108 bytes
[75] MATLAB.exe:public: void __thiscall boost::function0<void>::operator()(void)const (467782, 0x0040b7f4, 0, 0x78131731) + 63 bytes
[76] MATLAB.exe:int __cdecl mcrMain(int,char const * * const)(1, 0x026ddb78, 4194304, 10) + 230 bytes
[77] MATLAB.exe:_WinMain@16(4194304, 0, 467782, 10) + 75 bytes
[78] MATLAB.exe:___tmainCRTStartup(0, 0, 0x7ffd9000, 0) + 320 bytes
[79] kernel32.dll:0x7c816fe7(0x00406faa, 0, 0x00905a4d, 3)
This error was detected while a MEX-file was running. If the MEX-file
is not an official MathWorks function, please examine its source code
for errors. Please consult the External Interfaces Guide for information
on debugging MEX-files.
Is it a problem for libmex.dll? I have the files libmex.dll and libmx.dll in my mex folder. Can anyone please tell me what could be the possible solution? Thanks in advance for your help.
  1 Comment
Andreas Goser
Andreas Goser on 2 Aug 2011
Can you contact Technical Support for this one?

Sign in to comment.

Answers (2)

Jan
Jan on 2 Aug 2011
It seems like fast_kmeans_step.mexw32 is buggy. But this can be caused by errors in another Mex function also: If the memory manager is confused by any unintentionally freed array, the problems can appear at any time later in the program. So at first check the integrity of your Mex functions. It is very likely not a problem of the extremly well tested libmex.dll and libmx.dll.

Walter Roberson
Walter Roberson on 2 Aug 2011
The problem appears to be something in fast_kmeans_step which might perhaps have been called as part of SpikeSortingDemo
  2 Comments
Ten Tan
Ten Tan on 2 Aug 2011
yes, it is..problem is related to a dll file fast_kmeans_step.mexw32. but what's the exact reason for this crash? should I replace any depended dll file?
Walter Roberson
Walter Roberson on 2 Aug 2011
What does Dependency Walker tell you about it?
What does a debugger tell you?
There are many many different possible code reasons for a crash; there is no reasonable way to tell you the *exact* reason for the crash without at least seeing the code involved.

Sign in to comment.

Categories

Find more on MATLAB Compiler in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!