Question

ogdenk on Thu, 27 Mar 2014 14:16:40


Hi,

I am having a problem debugging a dll written to be used in Matlab (which calls them mex files).  I have two computers that I work on, a new laptop running Win 7 64 bit and a new Dell Workstation with the same OS.  I am using VS 2012.  The project is configured using Cmake, and runs fine on both systems.  The problem is that I can not debug the dll on the workstation.  I have checked lots of forums and understand the issues with having the correct .pdb files etc.  Since I am doing exactly the same thing on both computers, I would expect problems on both if I am doing something wrong.

The big difference I see between the two systems are which modules are loaded when I Attach to Matlab.exe to enable debugging.  On my laptop, I see over 200 modules loaded, maybe half of which are dll's from the Matlab installation directories.  I don't see my dll in that list until I invoke it from Matlab, but when I do it shows up and I jump into VS to the first breakpoint I set.  On my workstation, I only get a dozen or so modules loaded, and none of them are for Matlab.  What is odd to me is that I see modules for Dell Backup and Recovery, I don't understand why they would be there.  I don't have that software on my laptop, so maybe that creates a problem loading modules in the debugger? 

Any suggestions appreciated, Thanks!

Kent

These are the loaded modules on the workstation:

mscorlib.dllC:\Windows\Microsoft.Net\assembly\GAC_64\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll        

DBROverlayIcon.dll         C:\Program Files (x86)\Dell Backup and Recovery\Components\Shell\DBROverlayIcon.dll            

STCommonShellIntegration.dll  C:\Program Files (x86)\Dell Backup and Recovery\Components\Shell\STCommonShellIntegration.dll                    

System.dll           C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System\v4.0_4.0.0.0__b77a5c561934e089\System.dll                               

System.Data.SQLite.dll  C:\Program Files (x86)\Dell Backup and Recovery\Components\Shell\System.Data.SQLite.dll)                   

System.Data.dll C:\Windows\Microsoft.Net\assembly\GAC_64\System.Data\v4.0_4.0.0.0__b77a5c561934e089\System.Data.dll                             

System.Core.dll C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Core\v4.0_4.0.0.0__b77a5c561934e089\System.Core.dll

System.Transactions.dll C:\Windows\Microsoft.Net\assembly\GAC_64\System.Transactions\v4.0_4.0.0.0__b77a5c561934e089\System.Transactions.dll               

System.Configuration.dll C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Configuration\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Configuration.dll

System.Xml.dll C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Xml\v4.0_4.0.0.0__b77a5c561934e089\System.Xml.dll

System.EnterpriseServices.dll                C:\Windows\Microsoft.Net\assembly\GAC_64\System.EnterpriseServices\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.EnterpriseServices.dll

System.EnterpriseServices.Wrapper.dll C:\Windows\Microsoft.Net\assembly\GAC_64\System.EnterpriseServices\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.EnterpriseServices.Wrapper.dll               

DBROverlayNotBackuped.dll      C:\Program Files (x86)\Dell Backup and Recovery\Components\Shell\DBROverlayNotBackuped.dll


Sponsored



Replies

Carl Cai on Fri, 28 Mar 2014 09:28:19


Hi,

According to your description, I got that you developed a dll with VS2012, and generated mexw64 files, and you were able to step into the breakpoints on your laptop, but you could not get that work on Dell Workstation .

If I misunderstood you, please feel free to let me know.

>>On my laptop, I see over 200 modules loaded, maybe half of which are dll's from the Matlab installation directories.  I don't see my dll in that list until I invoke it from Matlab, but when I do it shows up and I jump into VS to the first breakpoint I set.  On my workstation, I only get a dozen or so modules loaded, and none of them are for Matlab. <<

First, I would suggest you regenerate the mexw64 files on your Dell Workstation , then debug it with the same steps used on your laptop to test.

>>What is odd to me is that I see modules for Dell Backup and Recovery, I don't understand why they would be there.  I don't have that software on my laptop, so maybe that creates a problem loading modules in the debugger? <<

I noticed that just exists in Dell Workstation , you could run your VS2012 as admin, and follow my first suggestion to test. In my opinion, loading these dll files are mainly related to Dell Workstation , I think that should not be related to these dll files.

Regards.