Compiling and debuging mscorlib: [Solved]


#1

I’m not sure where to post my question.

I have seen that mscorlib source is present in this GitHub repo, but I’m unsure if I can use this forum to ask the following question (actually I’m refererring to .Net 4.6 so I guess the correct category is Full Framework).

How can I compile and debug a C++ part of mscorlib so that I can submit a change for review?

I’m specifically referring to (debugging, compiling and locally testing) this implementation that (I assume) is called from here.


#2

to debug the runtime use these instructions from the same repository https://github.com/dotnet/coreclr/blob/775003a4c72f0acc37eab84628fcef541533ba4e/Documentation/building/debugging-instructions.md


#3

@shahid_pk Sorry for the late reply.

Thank you very much for the link :relaxed: It can been useful for the C++ part of mscorlib, but I’d like to add some comments.

Visual Studio and mscorlib managed C# part debugging

Last paragraph reads

To step into and debug managed code of Mscorlib.dll … using Visual Studio, is something that will be supported with Visual Studio 2015. We are actively working to enable this support.

Any updates about it??

mscorlib for unit test

Also, I discovered that I needed to copy (overwrite) the more recently compiled files from the Product x64 directory into the CoreRun (test runtime) directory to make the changes of mscorlib effective during the unit tests (I prepared a new unit test in the readytorun group).

quick rebuild

Another problem was the long time it took to build -rebuild everything from scratch: I’ve noticed that I could use the much more effective build windowsmscorlib followed by build nativemscorlib for C# changes in mscorlib, while build skiptests was the way to go for the C++ part.

Still I don’t know how to rebuild only the readytorun part without taking the long way of a full (and very slow) build-test.cmd? (solved the only mandatory folders are baseservices, Common, TestWrappersConfig so it can be made faster…)


.NET Foundation Website | Blog | Projects | Code of Conduct