Microsoft.Diagnostics.Runtime
2.0.130507
Prefix Reserved
See the version list below for details.
dotnet add package Microsoft.Diagnostics.Runtime --version 2.0.130507
NuGet\Install-Package Microsoft.Diagnostics.Runtime -Version 2.0.130507
<PackageReference Include="Microsoft.Diagnostics.Runtime" Version="2.0.130507" />
paket add Microsoft.Diagnostics.Runtime --version 2.0.130507
#r "nuget: Microsoft.Diagnostics.Runtime, 2.0.130507"
// Install Microsoft.Diagnostics.Runtime as a Cake Addin #addin nuget:?package=Microsoft.Diagnostics.Runtime&version=2.0.130507 // Install Microsoft.Diagnostics.Runtime as a Cake Tool #tool nuget:?package=Microsoft.Diagnostics.Runtime&version=2.0.130507
ClrMD 2.0 Beta Release Notes
Over the last few weeks we have been rewriting a lot of the internal core of ClrMD to fix a lot of issues that have been problematic in the library. ClrMD 2.0 is faster, allows you to control how much memory the library uses, and is thread safe (with exceptions), but it has a lot of breaking changes which will require you to update existing code to use it.
Quick Notes
We plan to continue fixing bugs in ClrMD 1.1 for the forseeable future, so you are not forced to upgrade if you do not want to. I do plan to only add new features to ClrMD 2.0, but the community is welcome to submit Pull Requests to backport or add features to ClrMD 1.1.
Please note that the API surface area of ClrMD 2.0 is not finalized and there may be breaking changes between now and when the library is out of beta. I expect to release the non-beta version around March/April 2020.
Changes from ClrMD 1.1
Added features:
- Memory Usage/Performance - ClrMD has reduced its overall memory usage and improved performance.
- Cache Control - You can now control what ClrMD caches to via
DataTarget.CacheOptions
. Note that disabling caches does greatly slow the library down but it also drastically reduces memory usage. You can also callClrRuntime.FlushCachedData
at any time to empty ClrMD's caches and reclaim memory. - Thread Safety - If
ClrRuntime.IsThreadSafe
returns true then you are allowed to call all functions from multiple threads. Please note that you likely will not see much performance improvements by running algorithms in parallel. The CLR debugging layer, mscordaccore.dll, takes a giant lock around most operations which means we do not get easy performance gains. This should make your code much easier to write if you need to do work on another thread. - Nullable Reference Types - ClrMD fully implements nullable reference types so you will know exactly what you need to null check from the library.
- Architectural Overhaul - ClrMD is now much less internally coupled. Most implementation types are now public, allowing you to use those types directly or to use the I*Builder interfaces to "mock" objects more easily. While the changes aren't perfect for mocking the library, it's definitely better than were we were before.
- Clean up Exceptions Thrown by ClrMD - This is planned but not yet completed.
- Provide a set of Benchmarks - ClrMD will provide a reasonable set of benchmarks so you know how much an operation should cost. This is planned but not yet completed.
Removed:
- Removed Blocking Objects - This was buggy in its initial implementation and never worked right. We do not intend to support this or rebuild it in 2.0.
- SymbolLocator partially removed - ClrMD still supports communicating with a symbol server to locate binaries but it's no longer intended to be a general purpose symbol server client.
- CLR v2 and v4 (prior to 4.5) support removed - ClrMD supports all .Net Core versions and Desktop .Net 4.5 and beyond. If you need to debug earlier versions of CLR, please use ClrMD 1.1.
- PDB Reading Removed - The implementation I was carrying in ClrMD was buggy and did not support PortablePDBs. I do not intend to keep this functionality in ClrMD 2.0. It's just too difficult to keep working and it's not needed or used by the rest of the library.
Why did we make these changes?
The first version of ClrMD is nearly 10 years old now, and it's starting to show its age. Over the years I've made some bad design decisions and added some questionable features that I wish I could fix or move to another (supported) library, but I've tried to maintain compatibility for folks who already built tools on top of ClrMD and that's hamstrung development in a lot of areas.
Please feel free to file issues against this beta version of ClrMD if you have questions, a feature request, or a bug to report.
Better performance, less memory.
We use Span<T> in place of most byte[] data reading operations, and use ArrayPool instead of doing our own allocating. We have eliminated a ton of needless garbage generated at runtime.
Better architecture
The old ClrMD implementation had a deep, confusing, and poorly thought out internal class heirarchy. This mostly grew organically from years of development and not be cleaned up due to compatibility concerns. The entire library has been refactored from the ground up to fix this. We've also removed Lazy<T> usage throughout a lot of the codebase because it made debugging problems with ClrMD difficult to do. We still evaluate most properties lazily, just without the use of that class.
Thanks
Thank you to everyone who contributed feedback, issues, and code for ClrMD 2.0. Especially NextTurn, who submitted countless changes and pull requests to make this possible.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 is compatible. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 is compatible. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETCoreApp 3.1
- Microsoft.Diagnostics.NETCore.Client (>= 0.2.61701)
- System.Buffers (>= 4.5.1)
- System.Collections.Immutable (>= 1.7.1)
- System.Memory (>= 4.5.4)
- System.Reflection.Metadata (>= 1.8.1)
- System.Runtime.CompilerServices.Unsafe (>= 4.7.1)
-
.NETFramework 4.7.1
- Microsoft.Diagnostics.NETCore.Client (>= 0.2.61701)
- System.Buffers (>= 4.5.1)
- System.Collections.Immutable (>= 1.7.1)
- System.Memory (>= 4.5.4)
- System.Reflection.Metadata (>= 1.8.1)
- System.Runtime.CompilerServices.Unsafe (>= 4.7.1)
-
.NETStandard 2.0
- Microsoft.Diagnostics.NETCore.Client (>= 0.2.61701)
- System.Buffers (>= 4.5.1)
- System.Collections.Immutable (>= 1.7.1)
- System.Memory (>= 4.5.4)
- System.Reflection.Metadata (>= 1.8.1)
- System.Runtime.CompilerServices.Unsafe (>= 4.7.1)
NuGet packages (36)
Showing the top 5 NuGet packages that depend on Microsoft.Diagnostics.Runtime:
Package | Downloads |
---|---|
BenchmarkDotNet
Powerful .NET library for benchmarking |
|
ppy.osu.Framework
A 2D application/game framework written with rhythm games in mind. |
|
Backtrace
Backtrace's integration with C# applications allows customers to capture and report handled and unhandled C# exceptions to their Backtrace instance, instantly offering the ability to prioritize and debug software errors. |
|
Phoesion.Glow.SDK.Firefly.SrvHost.DotNet.Dependencies
Phoesion Glow SDK Firefly SrvHost Runner (DotNet) Dependencies |
|
DynaMD
Helper objects to browse complex structures returned by ClrMD |
GitHub repositories (38)
Showing the top 5 popular GitHub repositories that depend on Microsoft.Diagnostics.Runtime:
Repository | Stars |
---|---|
dnSpy/dnSpy
.NET debugger and assembly editor
|
|
winsw/winsw
A wrapper executable that can run any executable as a Windows service, in a permissive license.
|
|
dotnet/BenchmarkDotNet
Powerful .NET library for benchmarking
|
|
xoofx/markdig
A fast, powerful, CommonMark compliant, extensible Markdown processor for .NET
|
|
microsoft/perfview
PerfView is a CPU and memory performance-analysis tool
|
Version | Downloads | Last updated |
---|---|---|
4.0.0-beta.24360.3 | 512 | 7/11/2024 |
4.0.0-beta.24360.2 | 80 | 7/10/2024 |
4.0.0-beta.24320.3 | 225 | 6/20/2024 |
4.0.0-beta.24314.3 | 351 | 6/14/2024 |
3.1.512801 | 99,851 | 2/29/2024 |
3.1.506101 | 32,594 | 2/1/2024 |
3.1.456101 | 71,382 | 11/13/2023 |
3.1.456003 | 20,486 | 11/11/2023 |
3.1.455904 | 4,492 | 11/10/2023 |
3.0.442202 | 65,718 | 8/22/2023 |
3.0.0-beta.23214.4 | 1,330 | 4/17/2023 |
3.0.0-beta.23177.1 | 264 | 3/28/2023 |
3.0.0-beta.23165.1 | 254 | 3/16/2023 |
3.0.0-beta.23159.4 | 196 | 3/9/2023 |
3.0.0-beta.23158.2 | 193 | 3/9/2023 |
3.0.0-beta.23156.1 | 171 | 3/6/2023 |
2.4.416101 | 1,149,578 | 3/12/2023 |
2.3.405304 | 106,751 | 1/5/2023 |
2.2.343001 | 86,980 | 10/31/2022 |
2.2.332302 | 11,773,891 | 6/23/2022 |
2.2.332001 | 4,150 | 6/20/2022 |
2.1.327703 | 14,408 | 5/27/2022 |
2.0.226801 | 2,947,304 | 5/19/2021 |
2.0.226401 | 1,036 | 5/14/2021 |
2.0.222201 | 55,098 | 4/22/2021 |
2.0.221201 | 9,715 | 4/14/2021 |
2.0.217201 | 52,774 | 3/22/2021 |
2.0.161401 | 1,051,802 | 12/14/2020 |
2.0.156101 | 34,221 | 11/18/2020 |
2.0.151903 | 26,652 | 10/19/2020 |
2.0.145301 | 94,537 | 9/4/2020 |
2.0.142701 | 6,296 | 8/28/2020 |
2.0.142501 | 1,643 | 8/25/2020 |
2.0.142103 | 1,702 | 8/21/2020 |
2.0.141902 | 5,753 | 8/19/2020 |
2.0.137201 | 25,406 | 7/22/2020 |
2.0.130507 | 53,288 | 6/6/2020 |
2.0.0-rc.20303.6 | 450 | 6/4/2020 |
2.0.0-rc.20278.6 | 536 | 5/28/2020 |
2.0.0-beta.20276.4 | 374 | 5/27/2020 |
2.0.0-beta.20273.1 | 437 | 5/23/2020 |
2.0.0-beta.20272.2 | 448 | 5/22/2020 |
2.0.0-beta.20272.1 | 372 | 5/22/2020 |
2.0.0-beta.20268.2 | 455 | 5/18/2020 |
2.0.0-beta.20230.2 | 516 | 4/30/2020 |
2.0.0-beta.20230.1 | 374 | 4/30/2020 |
2.0.0-beta.20229.3 | 372 | 4/30/2020 |
2.0.0-beta.20223.2 | 374 | 4/23/2020 |
2.0.0-beta.20222.8 | 341 | 4/23/2020 |
2.0.0-beta.20222.7 | 336 | 4/23/2020 |
2.0.0-beta.20222.5 | 343 | 4/22/2020 |
2.0.0-beta.20220.3 | 353 | 4/20/2020 |
2.0.0-beta.20213.1 | 483 | 4/13/2020 |
2.0.0-beta.20174.2 | 479 | 3/24/2020 |
2.0.0-beta.20072.5 | 754 | 1/23/2020 |
2.0.0-beta.19618.7 | 518 | 12/19/2019 |
2.0.0-beta.19612.8 | 419 | 12/12/2019 |
1.1.142101 | 253,556 | 8/21/2020 |
1.1.132302 | 13,064 | 6/23/2020 |
1.1.127808 | 90,761 | 5/29/2020 |
1.1.126102 | 7,775,428 | 5/17/2020 |
1.1.122004 | 56,657 | 4/20/2020 |
1.1.116301 | 46,898 | 3/13/2020 |
1.1.61812 | 86,831 | 12/19/2019 |
1.1.57604 | 4,871,648 | 11/26/2019 |
1.1.57004 | 5,415 | 11/20/2019 |
1.1.46104 | 120,183 | 9/11/2019 |
1.1.37504 | 84,377 | 7/25/2019 |
1.1.35902 | 7,835 | 7/9/2019 |
1.1.35504 | 1,898 | 7/5/2019 |
1.0.5 | 1,795,025 | 3/19/2019 |
1.0.3 | 208,528 | 2/13/2019 |
1.0.2 | 24,455 | 12/17/2018 |
1.0.0 | 15,734 | 11/22/2018 |
0.9.180305.1 | 268,623 | 3/6/2018 |
0.9.170809.3 | 213,607 | 8/9/2017 |
0.9.170626.1 | 22,624 | 6/26/2017 |
0.8.31-beta | 712,675 | 10/15/2015 |
0.8.30-beta | 6,564 | 9/16/2015 |
0.8.27-beta | 40,823 | 9/30/2014 |
0.8.26-beta | 1,946 | 8/14/2014 |
0.8.25-beta | 3,358 | 3/12/2014 |
0.8.24-aamain00309 | 1,423 | 12/2/2014 |
0.7.1-beta | 3,503 | 5/3/2013 |
See https://github.com/Microsoft/clrmd/releases for the latest release notes