Program analyses debugger information file (PDB, so Microsoft Visual C++ only) and presents info about user defined structures (size, padding, etc).
Original blog post: http://msinilo.pl/blog/?p=425
- Clone the repo
git clone https://github.com/BenHoffmanEpic/crunchersharp.git
- Open command prompt or PowerShell as Admin
- Find the directory where your
msdia
dll is located, which by default is loacted with you Visual Studio installation:
cd C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE
- Register the
msdia140
dll manually:
regsvr32 msdia140.dll
- Build the MSVC Project that you want with full debug symbols. By default in VS 2019/2017 it is set to
use
/debug:fast
, we need/debug:full
. This setting is located in Visual Studio project settings atLinker > Debugging > Generate Debug Info
.
- To change this in UE projects you will need set the Unreal Build Tool flag called
bUseFastPDBLinking
. Currently (4.24) the default value is to be turned off, which is what you want for using Cruncher.
- Open up Cruncher in Visual Studio
- Right click on the C# Project and select "Properties"
- Go to "Debug" and Select
Enable native code debugging
at the bottom.
- Make sure you have "All Configurations" selected here to ensure you have it in both Release and Debug
- Create an
x86
build configuration by clicking the Solution Platforms dropdown and selectingConfiguration Manager...
then clicking on theActive Solution Platform
and creating a newx86
setting.
- This has to be x86 due to the
msdia140
DLL, if you don't do this you may get unresolved symbols in Release modes.