Matlab Plugin – Matlab crashes on 2nd call

Front page Forums Plug-ins Matlab Plugin – Matlab crashes on 2nd call

This topic contains 6 replies, has 2 voices, and was last updated by  Matthaios 9 months ago.

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1299

    Matthaios
    Member

    Dear Paralution Developers/Community,

    Congratulations with the great work you have done with Paralution and thanks for providing an open source version.

    I am facing a problem when I compile Paralution funtcions in to .mex files to run from Matlab: All works fine the first time the mex is called, but the second call always crashes Matlab.

    This is happening with the provided Matlab Plugin example, and with any other modified versions I made, everything works fine for one call, then Matlab just crushes. No matter if I clear the workspace in Matlab, the second call is always crashing it – the only way I found to re-run a mex is shut-down Matlab(or let crash) and re-open it.

    I tried to change through debug/release modes (I am compiling from VS10) and OpenCL/CUDA Paralusion versions, but I am getting the same problem.

    As far as I understand it is a memory corruption issue, but unfortunately my programming skills are not very strong, so I am unable to find what goes wrong.

    Has anybody experienced this issue before? Anybody knows how to fix it?
    If not, please could you advice me in what further tests I could do in order to find what is causing this problem?
    (It might be something obvious that I am missing)

    I include the Matlab crash log bellow (not that I believe will be of any use – but just in case), please let me know if there is any other information that would be useful to provide.

    Thanks in advance,
    Matthaios

    —————————Matlab Crash Report ——————————
    Configuration:
    Crash Decoding : Disabled
    Crash Mode : continue (default)
    Current Graphics Driver: Unknown hardware
    Default Encoding : windows-1252
    Graphics card 1 : NVIDIA ( 0x10de ) NVIDIA GeForce GTX 970 Version 10.18.13.5891
    Graphics card 2 : Intel Corporation ( 0x8086 ) Intel(R) HD Graphics 4600 Version 10.18.10.3412
    Host Name : Matt-UNI-PC
    MATLAB Architecture : win64
    MATLAB Root : C:\Program Files\MATLAB\R2015b
    MATLAB Version : 8.6.0.267246 (R2015b)
    OpenGL : hardware
    Operating System : Microsoft Windows 7 Professional N
    Processor ID : x86 Family 6 Model 60 Stepping 3, GenuineIntel
    Virtual Machine : Java 1.7.0_60-b19 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode
    Window System : Version 6.1 (Build 7601: Service Pack 1)

    Fault Count: 1

    Abnormal termination:
    std::terminate()

    Register State (captured):
    RAX = 00000000fe9f2f01 RBX = 0000000004025c60
    RCX = 0000000004025620 RDX = 0000000000000000
    RSP = 0000000004025190 RBP = 0000000004026410
    RSI = 00000000fe9e2f30 RDI = 00000000fe9f2f80

    R8 = 000007fffffde000 R9 = 000007fef3790000
    R10 = 00000000fe9e2f80 R11 = 00000000fe9e2f80
    R12 = 000000000f7900b8 R13 = 0000000004026228
    R14 = 0000000000000000 R15 = 0000000000000000

    RIP = 00000000fe80462a EFL = 00000206

    CS = 0033 FS = 0053 GS = 002b

    Stack Trace (captured):
    [ 0] 0x00000000fe80462a C:\Program Files\MATLAB\R2015b\bin\win64\libmwfl.dll+00083498 fl::diag::windows::context_base::capture_data+00000010
    [ 1] 0x00000000fe800ee4 C:\Program Files\MATLAB\R2015b\bin\win64\libmwfl.dll+00069348 fl::diag::thread_context::unspecified_bool+00006628
    [ 2] 0x00000000fe8033f6 C:\Program Files\MATLAB\R2015b\bin\win64\libmwfl.dll+00078838 fl::test::terminate_handler::~terminate_handler+00003462
    [ 3] 0x000000000894dae5 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00449253 mnShutdownMCR+00021173
    [ 4] 0x000000000894d8b4 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00448692 mnShutdownMCR+00020612
    [ 5] 0x000000000894d99a C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00448922 mnShutdownMCR+00020842
    [ 6] 0x000000000894ad4a C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00437578 mnShutdownMCR+00009498
    [ 7] 0x000000000894e598 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00451992 mnSetSegvServiceUrl+00000168
    [ 8] 0x000007fef37fd56c C:\Program Files\MATLAB\R2015b\bin\win64\MSVCR110.dll+00447852 purecall+00000024
    [ 9] 0x00000000ec769da7 C:\Program Files\MATLAB\R2015b\bin\win64\libmwconfig.dll+00433575 QueryMLFcnTable_libmwconfig+00426039
    [ 10] 0x00000000ec7742ab C:\Program Files\MATLAB\R2015b\bin\win64\libmwconfig.dll+00475819 QueryMLFcnTable_libmwconfig+00468283
    [ 11] 0x00000000ec778f93 C:\Program Files\MATLAB\R2015b\bin\win64\libmwconfig.dll+00495507 QueryMLFcnTable_libmwconfig+00487971
    [ 12] 0x000000000739fa20 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00129568 Mlm_MATLAB_fn::is_loaded+00000048
    [ 13] 0x000000000739f9e3 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00129507 Mdispatcher::cleanupAllFcns+00000147
    [ 14] 0x0000000008afae55 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00896597 MathWorks::lxe::ReleaseCurrentMcrContext+00002725
    [ 15] 0x00000000fd750a28 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01313320 mlutil::contextmgr::ContextRegistry::getInstance+00011528
    [ 16] 0x00000000fd749b55 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01284949 mlutil::contextmgr::NullResourceException::rethrow+00024917
    [ 17] 0x00000000fd7a16f6 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01644278 mlutil::ScopedFactoryRegistration::Impl::unregister+00000070
    [ 18] 0x00000000fd7a13db C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01643483 mlutil::ScopedFactoryRegistration::Impl::~Impl+00000027
    [ 19] 0x00000000fd74b5f8 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01291768 mlutil::contextmgr::NullResourceException::rethrow+00031736
    [ 20] 0x00000000fd6bc763 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+00706403 mlutil::ScopedFactoryRegistration::~ScopedFactoryRegistration+00000035
    [ 21] 0x0000000008c4f5e0 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02291168 boost::serialization::singleton<boost::serialization::extended_type_info_typeid<boost_132::detail::shared_count> >::get_instance+00016976
    [ 22] 0x0000000008c4f5b0 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02291120 boost::serialization::singleton<boost::serialization::extended_type_info_typeid<boost_132::detail::shared_count> >::get_instance+00016928
    [ 23] 0x0000000008c4f592 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02291090 boost::serialization::singleton<boost::serialization::extended_type_info_typeid<boost_132::detail::shared_count> >::get_instance+00016898
    [ 24] 0x0000000008c57a20 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02325024 boost::serialization::singleton<boost::archive::detail::archive_serializer_map<boost::archive::binaryTerm_oarchive> >::get_instance+00018240
    [ 25] 0x0000000008c57ca2 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02325666 boost::serialization::singleton<boost::archive::detail::archive_serializer_map<boost::archive::binaryTerm_oarchive> >::get_instance+00018882
    [ 26] 0x0000000077213a81 C:\Windows\SYSTEM32\ntdll.dll+00146049 LdrShutdownProcess+00000465
    [ 27] 0x0000000077213890 C:\Windows\SYSTEM32\ntdll.dll+00145552 RtlExitUserProcess+00000144
    [ 28] 0x0000000069e60ccd C:\Program Files\MATLAB\R2015b\bin\win64\MSVCR100.dll+00134349 get_pgmptr+00000585
    [ 29] 0x000007fef00a2bb0 D:\Ligh Propagation Software\NirFast\toolbox\solvers\Paralusion_BicgS_FixR.mexw64+00011184 paralution::init_paralution+00000464
    [ 30] 0x000007fef00a144c D:\Ligh Propagation Software\NirFast\toolbox\solvers\Paralusion_BicgS_FixR.mexw64+00005196 mexFunction+00001004
    [ 31] 0x00000000fc5f7551 C:\Program Files\MATLAB\R2015b\bin\win64\libmex.dll+00095569 mexRunMexFile+00000129
    [ 32] 0x00000000fc5f6872 C:\Program Files\MATLAB\R2015b\bin\win64\libmex.dll+00092274 inSwapMexfileReader+00000594
    [ 33] 0x00000000fc5f6426 C:\Program Files\MATLAB\R2015b\bin\win64\libmex.dll+00091174 mexUnlock+00004998
    [ 34] 0x0000000007384cc3 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00019651 Mfh_file::dispatch_fh_impl+00000531
    [ 35] 0x000000000738488e C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00018574 Mfh_file::dispatch_fh+00000062
    [ 36] 0x00000000073851e8 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00020968 Mfunction_handle::dispatch+00000968
    [ 37] 0x0000000008a47942 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00162114
    [ 38] 0x0000000008a7ab5f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00371551
    [ 39] 0x0000000008a79810 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00366608
    [ 40] 0x0000000008aa96e1 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562913
    [ 41] 0x0000000008aa9406 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562182
    [ 42] 0x0000000008b0c23f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00967231 MathWorks::lxe::ReleaseCurrentMcrContext+00073359
    [ 43] 0x0000000008b0c146 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00966982 MathWorks::lxe::ReleaseCurrentMcrContext+00073110
    [ 44] 0x0000000008b0bc56 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00965718 MathWorks::lxe::ReleaseCurrentMcrContext+00071846
    [ 45] 0x0000000008b0ba19 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00965145 MathWorks::lxe::ReleaseCurrentMcrContext+00071273
    [ 46] 0x0000000008a91d08 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00466184
    [ 47] 0x000000000746ef1d C:\Program Files\MATLAB\R2015b\bin\win64\m_interpreter.dll+00061213 inFullEvalFcn+00000061
    [ 48] 0x00000000073856fe C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00022270 Mdispatcher::GetPushableExecutionStack+00000142
    [ 49] 0x0000000007385094 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00020628 Mfunction_handle::dispatch+00000628
    [ 50] 0x0000000008a466de C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00157406
    [ 51] 0x0000000008a4839d C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00164765
    [ 52] 0x0000000008a7ab5f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00371551
    [ 53] 0x0000000008a79810 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00366608
    [ 54] 0x0000000008aa96e1 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562913
    [ 55] 0x0000000008aa9406 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562182
    [ 56] 0x0000000008b7f71b C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+01439515 MathWorks::lxe::ReleaseCurrentMcrContext+00545643
    [ 57] 0x0000000008a4a1e8 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00172520
    [ 58] 0x0000000008a4bd7d C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00179581
    [ 59] 0x0000000007384dd6 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00019926 Mfh_file::dispatch_fh_impl+00000806
    [ 60] 0x000000000738488e C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00018574 Mfh_file::dispatch_fh+00000062
    [ 61] 0x00000000073851e8 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00020968 Mfunction_handle::dispatch+00000968
    [ 62] 0x0000000008a466de C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00157406
    [ 63] 0x0000000008a4839d C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00164765
    [ 64] 0x0000000008a7ab5f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00371551
    [ 65] 0x0000000008a79810 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00366608
    [ 66] 0x0000000008aa96e1 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562913
    [ 67] 0x0000000008aa9406 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562182
    [ 68] 0x0000000008b0c23f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00967231 MathWorks::lxe::ReleaseCurrentMcrContext+00073359
    [ 69] 0x0000000008b0c146 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00966982 MathWorks::lxe::ReleaseCurrentMcrContext+00073110
    [ 70] 0x0000000008b0bc56 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00965718 MathWorks::lxe::ReleaseCurrentMcrContext+00071846
    [ 71] 0x0000000008a90b14 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00461588
    [ 72] 0x0000000008a90adc C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00461532
    [ 73] 0x0000000008a9091a C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00461082
    [ 74] 0x0000000008a90802 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00460802
    [ 75] 0x00000000075060a1 C:\Program Files\MATLAB\R2015b\bin\win64\m_interpreter.dll+00680097 inEvalCmdWithLocalReturn+00000065
    [ 76] 0x00000000089e29bd C:\Program Files\MATLAB\R2015b\bin\win64\libmwbridge.dll+00076221 mnGetPrompt+00003597
    [ 77] 0x00000000089e3597 C:\Program Files\MATLAB\R2015b\bin\win64\libmwbridge.dll+00079255 mnParser+00001079
    [ 78] 0x00000000089387a4 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00362404 mcrInstance::mnParser_on_interpreter_thread+00000036
    [ 79] 0x000000000890c477 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00181367 mcr::runtime::setInterpreterThreadToCurrent+00019751
    [ 80] 0x000000000890c4b3 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00181427 mcr::runtime::setInterpreterThreadToCurrent+00019811
    [ 81] 0x000000000890ccb1 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00183473 mcr::runtime::setInterpreterThreadToCurrent+00021857
    [ 82] 0x00000000fab62aa6 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00535206 UIW_AttachThreadInput+00001270
    [ 83] 0x00000000fab62335 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00533301 wsd_to_MSW+00004181
    [ 84] 0x00000000fab623b9 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00533433 wsd_to_MSW+00004313
    [ 85] 0x0000000076ff87fe C:\Windows\system32\USER32.dll+00165886 GetMenuBarInfo+00000638
    [ 86] 0x0000000076fdf5fb C:\Windows\system32\USER32.dll+00062971 SystemParametersInfoW+00000235
    [ 87] 0x0000000076fe4895 C:\Windows\system32\USER32.dll+00084117 IsProcessDPIAware+00000465
    [ 88] 0x000000007723d8f5 C:\Windows\SYSTEM32\ntdll.dll+00317685 KiUserCallbackDispatcher+00000031
    [ 89] 0x0000000076fe908a C:\Windows\system32\USER32.dll+00102538 PeekMessageW+00000186
    [ 90] 0x0000000076fe50fe C:\Windows\system32\USER32.dll+00086270 GetKeyState+00000238
    [ 91] 0x0000000076fe3a6f C:\Windows\system32\USER32.dll+00080495 PeekMessageA+00000087
    [ 92] 0x00000000fab0e1cb C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00188875 UIW_ShowMenuItem+00005547
    [ 93] 0x00000000fab634c2 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00537794 UIW_SuspendAttachThreadInput+00000690
    [ 94] 0x00000000044c0ad3 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01510099 services::system_events::PpeDispatchHook::dispatchOne+00032291
    [ 95] 0x00000000044cc785 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01558405 sysq::addProcessPendingEventsUnitTestHook+00006101
    [ 96] 0x00000000044cc830 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01558576 sysq::addProcessPendingEventsUnitTestHook+00006272
    [ 97] 0x00000000044ce475 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01565813 sysq::getCondition+00004197
    [ 98] 0x00000000044cfe22 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01572386 svWS_ProcessPendingEvents+00000162
    [ 99] 0x000000000890d3cd C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00185293 mcr::runtime::setInterpreterThreadToCurrent+00023677
    [100] 0x000000000890e03a C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00188474 mcr::runtime::setInterpreterThreadToCurrent+00026858
    [101] 0x0000000008905c95 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00154773 mcr_process_events+00007557
    [102] 0x00000000089075a2 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00161186 mcr_process_events+00013970
    [103] 0x00000000073037ae C:\Program Files\MATLAB\R2015b\bin\win64\MVMLocal.dll+00210862 mvm_server::inproc::LocalFactory::terminate+00081678
    [104] 0x00000000fa924d99 C:\Program Files\MATLAB\R2015b\bin\win64\mvm.dll+01002905 mvm::detail::initLocalMvmHack+00000537
    [105] 0x00000000fa925368 C:\Program Files\MATLAB\R2015b\bin\win64\mvm.dll+01004392 mvm::detail::SessionImpl::privateSession+00000376
    [106] 0x00000000fa9255b2 C:\Program Files\MATLAB\R2015b\bin\win64\mvm.dll+01004978 mvm::detail::SessionImpl::privateSession+00000962
    [107] 0x0000000140006247 C:\Program Files\MATLAB\R2015b\bin\win64\MATLAB.exe+00025159
    [108] 0x0000000140007cf4 C:\Program Files\MATLAB\R2015b\bin\win64\MATLAB.exe+00031988
    [109] 0x00000000770e5a4d C:\Windows\system32\kernel32.dll+00088653 BaseThreadInitThunk+00000013
    [110] 0x000000007721b831 C:\Windows\SYSTEM32\ntdll.dll+00178225 RtlUserThreadStart+00000033

    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.

    If this problem is reproducible, please submit a Service Request via:
    http://www.mathworks.com/support/contact_us/

    A technical support engineer might contact you with further information.

    Thank you for your help.

    • This topic was modified 2 years ago by  Matthaios.
    • This topic was modified 2 years ago by  Matthaios.
    #1302

    nico
    Participant

    Hi Matthaios,

    thanks for reporting this issue. To get a working copy for MATLAB you will have to disable the object tracking feature of PARALUTION. You can do this in the file /src/utils/def.hpp by enabling the define “OBJ_TRACKING_OFF”. You will have to recompile PARALUTION afterwards. I hope this will fix the issue for you.
    In any case, please do not hesitate to contact me, if you have further issues / questions.

    Best regards,
    Nico

    #1303

    Matthaios
    Member

    Hey Nico,

    Thanks for your quick response! I don’t think I would have ever solved this by myself.
    Unfortunately, I am away for the weekend, with no access to my PC, I will try this on Monday, thanks again!

    Best wishes,
    Matthaios

    #1304

    Matthaios
    Member

    Hi Nico,

    Just made the change you recommended and the problem is fixed!
    Thank you so much!

    Best wishes,
    Matthaios

    #1361

    Matthaios
    Member

    Hi Nico,

    I am trying out the OpenMP backend, and I am afraid I have the same problem again:
    the mex file is working fine, but Matlab crashes when I call the .mex file a second time.

    The Paralution library is compiled with the change in the “def.hpp” file you suggested previously (may I note that it works fine for CUDA or OpenCL backends, and I am working with is the latest Paralution, version 1.1).

    Is there something extra I should do for the OpenMP backend to work with Matlab (by the way it seems to be working fine on a C++ testing routine, when compiling an .exe instead)?

    Thanks for all your help,

    Best wishes,
    Matthaios

    PS: Copying the Matlab crush report bellow
    ————————————————————–
    MATLAB crash file:C:\Users\Matt\AppData\Local\Temp\matlab_crash_dump.7480-1:

    ————————————————————————
    std::terminate() detected at Tue Mar 08 17:28:12 2016
    ————————————————————————

    Configuration:
    Crash Decoding : Disabled
    Crash Mode : continue (default)
    Current Graphics Driver: Unknown hardware
    Default Encoding : windows-1252
    Graphics card 1 : NVIDIA ( 0x10de ) NVIDIA GeForce GTX 970 Version 10.18.13.6191
    Graphics card 2 : Intel Corporation ( 0x8086 ) Intel(R) HD Graphics 4600 Version 10.18.10.3412
    Host Name : Matt-UNI-PC
    MATLAB Architecture : win64
    MATLAB Root : C:\Program Files\MATLAB\R2015b
    MATLAB Version : 8.6.0.267246 (R2015b)
    OpenGL : hardware
    Operating System : Microsoft Windows 7 Professional N
    Processor ID : x86 Family 6 Model 60 Stepping 3, GenuineIntel
    Virtual Machine : Java 1.7.0_60-b19 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode
    Window System : Version 6.1 (Build 7601: Service Pack 1)

    Fault Count: 1

    Abnormal termination:
    std::terminate()

    Register State (captured):
    RAX = 0000000004502f01 RBX = 0000000004025a30
    RCX = 00000000040253f0 RDX = 0000000000000000
    RSP = 0000000004024f60 RBP = 00000000040261e0
    RSI = 00000000044f2f30 RDI = 0000000004502f80

    R8 = 000007fffffde000 R9 = 000007fef16f0000
    R10 = 00000000044f2f80 R11 = 00000000044f2f80
    R12 = 000000000ea9dac8 R13 = 0000000004025ff8
    R14 = 0000000000000000 R15 = 0000000000000000

    RIP = 000000000431462a EFL = 00000206

    CS = 0033 FS = 0053 GS = 002b

    Stack Trace (captured):
    [ 0] 0x000000000431462a C:\Program Files\MATLAB\R2015b\bin\win64\libmwfl.dll+00083498 fl::diag::windows::context_base::capture_data+00000010
    [ 1] 0x0000000004310ee4 C:\Program Files\MATLAB\R2015b\bin\win64\libmwfl.dll+00069348 fl::diag::thread_context::unspecified_bool+00006628
    [ 2] 0x00000000043133f6 C:\Program Files\MATLAB\R2015b\bin\win64\libmwfl.dll+00078838 fl::test::terminate_handler::~terminate_handler+00003462
    [ 3] 0x0000000008e2dae5 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00449253 mnShutdownMCR+00021173
    [ 4] 0x0000000008e2d8b4 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00448692 mnShutdownMCR+00020612
    [ 5] 0x0000000008e2d99a C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00448922 mnShutdownMCR+00020842
    [ 6] 0x0000000008e2ad4a C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00437578 mnShutdownMCR+00009498
    [ 7] 0x0000000008e2e598 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00451992 mnSetSegvServiceUrl+00000168
    [ 8] 0x000007fef175d56c C:\Program Files\MATLAB\R2015b\bin\win64\MSVCR110.dll+00447852 purecall+00000024
    [ 9] 0x00000000ec769da7 C:\Program Files\MATLAB\R2015b\bin\win64\libmwconfig.dll+00433575 QueryMLFcnTable_libmwconfig+00426039
    [ 10] 0x00000000ec7742ab C:\Program Files\MATLAB\R2015b\bin\win64\libmwconfig.dll+00475819 QueryMLFcnTable_libmwconfig+00468283
    [ 11] 0x00000000ec778f93 C:\Program Files\MATLAB\R2015b\bin\win64\libmwconfig.dll+00495507 QueryMLFcnTable_libmwconfig+00487971
    [ 12] 0x00000000077ffa20 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00129568 Mlm_MATLAB_fn::is_loaded+00000048
    [ 13] 0x00000000077ff9e3 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00129507 Mdispatcher::cleanupAllFcns+00000147
    [ 14] 0x0000000008fdae55 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00896597 MathWorks::lxe::ReleaseCurrentMcrContext+00002725
    [ 15] 0x00000000fd750a28 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01313320 mlutil::contextmgr::ContextRegistry::getInstance+00011528
    [ 16] 0x00000000fd749b55 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01284949 mlutil::contextmgr::NullResourceException::rethrow+00024917
    [ 17] 0x00000000fd7a16f6 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01644278 mlutil::ScopedFactoryRegistration::Impl::unregister+00000070
    [ 18] 0x00000000fd7a13db C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01643483 mlutil::ScopedFactoryRegistration::Impl::~Impl+00000027
    [ 19] 0x00000000fd74b5f8 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+01291768 mlutil::contextmgr::NullResourceException::rethrow+00031736
    [ 20] 0x00000000fd6bc763 C:\Program Files\MATLAB\R2015b\bin\win64\mlutil.dll+00706403 mlutil::ScopedFactoryRegistration::~ScopedFactoryRegistration+00000035
    [ 21] 0x000000000912f5e0 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02291168 boost::serialization::singleton<boost::serialization::extended_type_info_typeid<boost_132::detail::shared_count> >::get_instance+00016976
    [ 22] 0x000000000912f5b0 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02291120 boost::serialization::singleton<boost::serialization::extended_type_info_typeid<boost_132::detail::shared_count> >::get_instance+00016928
    [ 23] 0x000000000912f592 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02291090 boost::serialization::singleton<boost::serialization::extended_type_info_typeid<boost_132::detail::shared_count> >::get_instance+00016898
    [ 24] 0x0000000009137a20 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02325024 boost::serialization::singleton<boost::archive::detail::archive_serializer_map<boost::archive::binaryTerm_oarchive> >::get_instance+00018240
    [ 25] 0x0000000009137ca2 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+02325666 boost::serialization::singleton<boost::archive::detail::archive_serializer_map<boost::archive::binaryTerm_oarchive> >::get_instance+00018882
    [ 26] 0x00000000779a35f1 C:\Windows\SYSTEM32\ntdll.dll+00144881 LdrShutdownProcess+00000465
    [ 27] 0x00000000779a3400 C:\Windows\SYSTEM32\ntdll.dll+00144384 RtlExitUserProcess+00000144
    [ 28] 0x000007fef37329a7 C:\Windows\system32\MSVCR120.dll+00141735 initterm_e+00000539
    [ 29] 0x000007fee7664969 D:\Ligh Propagation Software\NirFast\toolbox\solvers\para_bicgstab_IC_omp.mexw64+00018793 mexFunction+00004169
    [ 30] 0x000007fee7663c65 D:\Ligh Propagation Software\NirFast\toolbox\solvers\para_bicgstab_IC_omp.mexw64+00015461 mexFunction+00000837
    [ 31] 0x00000000fc5f7551 C:\Program Files\MATLAB\R2015b\bin\win64\libmex.dll+00095569 mexRunMexFile+00000129
    [ 32] 0x00000000fc5f6872 C:\Program Files\MATLAB\R2015b\bin\win64\libmex.dll+00092274 inSwapMexfileReader+00000594
    [ 33] 0x00000000fc5f6426 C:\Program Files\MATLAB\R2015b\bin\win64\libmex.dll+00091174 mexUnlock+00004998
    [ 34] 0x00000000077e4cc3 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00019651 Mfh_file::dispatch_fh_impl+00000531
    [ 35] 0x00000000077e488e C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00018574 Mfh_file::dispatch_fh+00000062
    [ 36] 0x00000000077e51e8 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00020968 Mfunction_handle::dispatch+00000968
    [ 37] 0x0000000008f27942 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00162114
    [ 38] 0x0000000008f5ab5f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00371551
    [ 39] 0x0000000008f59810 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00366608
    [ 40] 0x0000000008f896e1 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562913
    [ 41] 0x0000000008f89406 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562182
    [ 42] 0x0000000008fec23f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00967231 MathWorks::lxe::ReleaseCurrentMcrContext+00073359
    [ 43] 0x0000000008fec146 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00966982 MathWorks::lxe::ReleaseCurrentMcrContext+00073110
    [ 44] 0x0000000008febc56 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00965718 MathWorks::lxe::ReleaseCurrentMcrContext+00071846
    [ 45] 0x0000000008feba19 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00965145 MathWorks::lxe::ReleaseCurrentMcrContext+00071273
    [ 46] 0x0000000008f71d08 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00466184
    [ 47] 0x00000000078def1d C:\Program Files\MATLAB\R2015b\bin\win64\m_interpreter.dll+00061213 inFullEvalFcn+00000061
    [ 48] 0x00000000077e56fe C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00022270 Mdispatcher::GetPushableExecutionStack+00000142
    [ 49] 0x00000000077e5094 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00020628 Mfunction_handle::dispatch+00000628
    [ 50] 0x0000000008f266de C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00157406
    [ 51] 0x0000000008f2839d C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00164765
    [ 52] 0x0000000008f5ab5f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00371551
    [ 53] 0x0000000008f59810 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00366608
    [ 54] 0x0000000008f896e1 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562913
    [ 55] 0x0000000008f89406 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562182
    [ 56] 0x000000000905f71b C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+01439515 MathWorks::lxe::ReleaseCurrentMcrContext+00545643
    [ 57] 0x0000000008f2a1e8 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00172520
    [ 58] 0x0000000008f2bd7d C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00179581
    [ 59] 0x00000000077e4dd6 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00019926 Mfh_file::dispatch_fh_impl+00000806
    [ 60] 0x00000000077e488e C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00018574 Mfh_file::dispatch_fh+00000062
    [ 61] 0x00000000077e51e8 C:\Program Files\MATLAB\R2015b\bin\win64\m_dispatcher.dll+00020968 Mfunction_handle::dispatch+00000968
    [ 62] 0x0000000008f266de C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00157406
    [ 63] 0x0000000008f2839d C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00164765
    [ 64] 0x0000000008f5ab5f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00371551
    [ 65] 0x0000000008f59810 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00366608
    [ 66] 0x0000000008f896e1 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562913
    [ 67] 0x0000000008f89406 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00562182
    [ 68] 0x0000000008fec23f C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00967231 MathWorks::lxe::ReleaseCurrentMcrContext+00073359
    [ 69] 0x0000000008fec146 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00966982 MathWorks::lxe::ReleaseCurrentMcrContext+00073110
    [ 70] 0x0000000008febc56 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00965718 MathWorks::lxe::ReleaseCurrentMcrContext+00071846
    [ 71] 0x0000000008f70b14 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00461588
    [ 72] 0x0000000008f70adc C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00461532
    [ 73] 0x0000000008f7091a C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00461082
    [ 74] 0x0000000008f70802 C:\Program Files\MATLAB\R2015b\bin\win64\m_lxe.dll+00460802
    [ 75] 0x00000000079760a1 C:\Program Files\MATLAB\R2015b\bin\win64\m_interpreter.dll+00680097 inEvalCmdWithLocalReturn+00000065
    [ 76] 0x0000000008ec29bd C:\Program Files\MATLAB\R2015b\bin\win64\libmwbridge.dll+00076221 mnGetPrompt+00003597
    [ 77] 0x0000000008ec3597 C:\Program Files\MATLAB\R2015b\bin\win64\libmwbridge.dll+00079255 mnParser+00001079
    [ 78] 0x0000000008e187a4 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00362404 mcrInstance::mnParser_on_interpreter_thread+00000036
    [ 79] 0x0000000008dec477 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00181367 mcr::runtime::setInterpreterThreadToCurrent+00019751
    [ 80] 0x0000000008dec4b3 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00181427 mcr::runtime::setInterpreterThreadToCurrent+00019811
    [ 81] 0x0000000008deccb1 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00183473 mcr::runtime::setInterpreterThreadToCurrent+00021857
    [ 82] 0x00000000fab62aa6 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00535206 UIW_AttachThreadInput+00001270
    [ 83] 0x00000000fab62335 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00533301 wsd_to_MSW+00004181
    [ 84] 0x00000000fab623b9 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00533433 wsd_to_MSW+00004313
    [ 85] 0x00000000778a8802 C:\Windows\system32\USER32.dll+00165890 GetMenuBarInfo+00000626
    [ 86] 0x000000007788f5e7 C:\Windows\system32\USER32.dll+00062951 SystemParametersInfoW+00000247
    [ 87] 0x0000000077894869 C:\Windows\system32\USER32.dll+00084073 IsProcessDPIAware+00000453
    [ 88] 0x00000000779cd2f5 C:\Windows\SYSTEM32\ntdll.dll+00316149 KiUserCallbackDispatcher+00000031
    [ 89] 0x00000000778990ca C:\Windows\system32\USER32.dll+00102602 PeekMessageW+00000186
    [ 90] 0x00000000778950de C:\Windows\system32\USER32.dll+00086238 GetKeyState+00000238
    [ 91] 0x0000000077893a47 C:\Windows\system32\USER32.dll+00080455 PeekMessageA+00000087
    [ 92] 0x00000000fab0e1cb C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00188875 UIW_ShowMenuItem+00005547
    [ 93] 0x00000000fab634c2 C:\Program Files\MATLAB\R2015b\bin\win64\uiw.dll+00537794 UIW_SuspendAttachThreadInput+00000690
    [ 94] 0x0000000004860ad3 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01510099 services::system_events::PpeDispatchHook::dispatchOne+00032291
    [ 95] 0x000000000486c785 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01558405 sysq::addProcessPendingEventsUnitTestHook+00006101
    [ 96] 0x000000000486c830 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01558576 sysq::addProcessPendingEventsUnitTestHook+00006272
    [ 97] 0x000000000486e475 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01565813 sysq::getCondition+00004197
    [ 98] 0x000000000486fe22 C:\Program Files\MATLAB\R2015b\bin\win64\libmwservices.dll+01572386 svWS_ProcessPendingEvents+00000162
    [ 99] 0x0000000008ded3cd C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00185293 mcr::runtime::setInterpreterThreadToCurrent+00023677
    [100] 0x0000000008dee03a C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00188474 mcr::runtime::setInterpreterThreadToCurrent+00026858
    [101] 0x0000000008de5c95 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00154773 mcr_process_events+00007557
    [102] 0x0000000008de75a2 C:\Program Files\MATLAB\R2015b\bin\win64\mcr.dll+00161186 mcr_process_events+00013970
    [103] 0x00000000057037ae C:\Program Files\MATLAB\R2015b\bin\win64\MVMLocal.dll+00210862 mvm_server::inproc::LocalFactory::terminate+00081678
    [104] 0x00000000fa924d99 C:\Program Files\MATLAB\R2015b\bin\win64\mvm.dll+01002905 mvm::detail::initLocalMvmHack+00000537
    [105] 0x00000000fa925368 C:\Program Files\MATLAB\R2015b\bin\win64\mvm.dll+01004392 mvm::detail::SessionImpl::privateSession+00000376
    [106] 0x00000000fa9255b2 C:\Program Files\MATLAB\R2015b\bin\win64\mvm.dll+01004978 mvm::detail::SessionImpl::privateSession+00000962
    [107] 0x0000000140006247 C:\Program Files\MATLAB\R2015b\bin\win64\MATLAB.exe+00025159
    [108] 0x0000000140007cf4 C:\Program Files\MATLAB\R2015b\bin\win64\MATLAB.exe+00031988
    [109] 0x00000000777759ed C:\Windows\system32\kernel32.dll+00088557 BaseThreadInitThunk+00000013
    [110] 0x00000000779ab371 C:\Windows\SYSTEM32\ntdll.dll+00177009 RtlUserThreadStart+00000033

    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.

    #1362

    nico
    Participant

    Hi Matthaios,

    during your first tests, when you initially disabled the object tracking and everything was working as intended, did you explicitly disable the OpenMP backend? Because it is enabled by default by the cmake compilation process.

    If matlab crashes on the second run, its very likely to happen because of the re-initialization of the backend. Working as intended with OpenCL/CUDA but not with OpenMP however, sounds very strange. I cannot reproduce this error on our machines, so I will need some more information on what exactly happens.
    I assume you have set “#define OBJ_TRACKING_OFF” in the def.hpp, right?

    Best regards
    Nico

    #1480

    Matthaios
    Member

    Did a fresh project and solved this, I guess I was linking to a previously compiled Paralution library where I didn’t have the “#define OBJ_TRACKING_OFF” set.

    Thanks.

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.