Another goal to make it easier to obtain a version of lldb (currently 3.9) with scripts and documentation for platforms/distros like Centos, Alpine, Fedora, etc. that by default provide really old versions.
-This repo will also allow out of band development of new SOS and lldb plugin features like symbol server support for the .NET Core runtime and solve the source build problem having SOS.NETCore (managed portion of SOS) in the coreclr repo.
+This repo will also allow out of band development of new SOS and lldb plugin features like symbol server support for the .NET Core runtime and solve the source build problem having SOS.NETCore (managed portion of SOS) in the runtime repo.
See the [GitHub Release tab](https://github.com/dotnet/diagnostics/releases) for notes on SOS and diagnostic tools releases.
The following instructions will install the required packages. This only needs to be done once per machine. These instructions assume that you already have "sudo" installed. It is also recommended to create a github fork of the diagnostics repo and cloning that instead of https://github.com/dotnet/diagnostics.git directly.
-To build or cross build for ARM on Windows or Linux see the instructions [here](https://github.com/dotnet/coreclr/blob/master/Documentation/building/cross-building.md#generating-the-rootfs) in the coreclr repo. You will need to clone the coreclr [repo](https://github.com/dotnet/coreclr.git) and build the appropriate "rootfs" for arm or arm64 using these instructions. You only need to do this once.
+To build or cross build for ARM on Windows or Linux see the instructions [here](https://github.com/dotnet/runtime/blob/master/docs/workflow/building/coreclr/cross-building.md#generating-the-rootfs) in the runtime repo. You will need to clone the runtime [repo](https://github.com/dotnet/runtime.git) and build the appropriate "rootfs" for arm or arm64 using these instructions. You only need to do this once.
#### Ubuntu 14.04 ####
Debugging Linux or MacOS Core Dump
==================================
-These instructions will lead you through getting symbols, loading and debugging a Linux or MacOS core dump. The best way to generate a core dump on Linux (only) is through the [createdump](https://github.com/dotnet/coreclr/blob/master/Documentation/botr/xplat-minidump-generation.md#configurationpolicy) facility.
+These instructions will lead you through getting symbols, loading and debugging a Linux or MacOS core dump. The best way to generate a core dump on Linux (only) is through the [createdump](https://github.com/dotnet/runtime/blob/master/docs/design/coreclr/botr/xplat-minidump-generation.md#configurationpolicy) facility.
Dumps created with gdb or gcore do not have all the managed state so various SOS or dotnet-dump commands may display "UNKNOWN" for type and function names. This can also happen with Linux system generated core dumps if the `coredump_filter` for the process is not set to at least 0x3f. See [core](http://man7.org/linux/man-pages/man5/core.5.html) for more information.
## Intro
The Diagnostics Client Library (currently named as "Runtime Client Library") - `Microsoft.Diagnostics.NetCore.Client.dll` - is a managed library that can be used to interact with the .NET runtime via the diagnostics IPC protocol as documented in https://github.com/dotnet/diagnostics/blob/master/documentation/design-docs/ipc-protocol.md. It provides managed classes for invoking the diagnostics IPC commands programmatically, and can be extended to write various diagnostics tools. It also comes with various classes that should facilitate interacting with the diagnostics IPC commands.
-The name "Diagnostics Client Library" comes from the fact that we call the runtime (CoreCLR) component responsible for accepting and handling the diagnostics IPC commands the "diagnostics server" - https://github.com/dotnet/coreclr/blob/master/src/vm/diagnosticserver.h. Since this library is a managed library on the other side of the IPC protocol responsible for communicating with the runtime's "diagnostics server", calling this the "Diagnostics Client Library" made sense.
+The name "Diagnostics Client Library" comes from the fact that we call the runtime (CoreCLR) component responsible for accepting and handling the diagnostics IPC commands the "diagnostics server" - https://github.com/dotnet/runtime/blob/master/src/coreclr/src/vm/diagnosticserver.h. Since this library is a managed library on the other side of the IPC protocol responsible for communicating with the runtime's "diagnostics server", calling this the "Diagnostics Client Library" made sense.
## Goals
## Using dotnet-dump
-The next step is to collect a dump. This can be skipped if a core dump has already been generated by the operating system or [createdump](https://github.com/dotnet/coreclr/blob/master/Documentation/botr/xplat-minidump-generation.md#configurationpolicy) on Linux.
+The next step is to collect a dump. This can be skipped if a core dump has already been generated by the operating system or [createdump](https://github.com/dotnet/runtime/blob/master/docs/design/coreclr/botr/xplat-minidump-generation.md#configurationpolicy) on Linux.
On Linux, the runtime version must be 3.0 or greater. On Windows, dotnet-dump collect will work with any version of the runtime.
```
~/diagnostics$ ./test.sh --privatebuildpath /home/user/runtime/artifacts/bin/coreclr/Linux.x64.Debug
```
-The private runtime will be copied to the diagnostics repo and the tests started. It can be just the coreclr binaries but this assumes that the private build is close to the latest published master build. If not, you can pass the runtime's testhost directory containing all the shared runtime bits i.e. `c:\runtime\artifacts\bin\testhost\netcoreapp5.0-Windows_NT-Debug-x64\shared\Microsoft.NETCore.App\5.0.0` or `/home/user/runtime/artifacts/bin/testhost/netcoreapp5.0-Linux-Release-x64/shared/Microsoft.NETCore.App/5.0.0`
+The private runtime will be copied to the diagnostics repo and the tests started. It can be just the runtime binaries but this assumes that the private build is close to the latest published master build. If not, you can pass the runtime's testhost directory containing all the shared runtime bits i.e. `c:\runtime\artifacts\bin\coreclr\testhost\netcoreapp5.0-Windows_NT-Debug-x64\shared\Microsoft.NETCore.App\5.0.0` or `/home/user/runtime/artifacts/bin/coreclr/testhost/netcoreapp5.0-Linux-Release-x64/shared/Microsoft.NETCore.App/5.0.0`
On Linux/MacOS it is recommended to test against Release runtime builds because of a benign assert in DAC (tracked by issue #[31897](https://github.com/dotnet/runtime/issues/31897)) that causes the tests to fail.
In both cases, you have to be careful to roughly match the environment up with the production server. For example, if I am running .net core preview 5 on Ubuntu 16.04 the core dump must be analyzed on the same architecture and environment.
-For the LLDB/SOS experience, please see - https://github.com/dotnet/coreclr/blob/master/Documentation/building/debugging-instructions.md.
+For the LLDB/SOS experience, please see - https://github.com/dotnet/runtime/blob/master/docs/workflow/building/coreclr/debugging-instructions.md.
To use the dotnet-dump tool to analyze the dump please run:
SET (CMAKE_C_FLAGS_DEBUG_INIT "-g -O0")
SET (CLR_C_FLAGS_CHECKED_INIT "-g -O1")
# Refer to the below instruction to support __thread with -O2/-O3 on Linux/ARM
-# https://github.com/dotnet/coreclr/blob/master/Documentation/building/linux-instructions.md
+# https://github.com/dotnet/runtime/blob/master/docs/workflow/building/coreclr/linux-instructions.md
SET (CMAKE_C_FLAGS_RELEASE_INIT "-g -O1")
SET (CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-g -O1")
SET (CMAKE_C_FLAGS_DEBUG_INIT "-g -O0")
SET (CLR_C_FLAGS_CHECKED_INIT "-g -O2")
# Refer to the below instruction to support __thread with -O2/-O3 on Linux/ARM
-# https://github.com/dotnet/coreclr/blob/master/Documentation/building/linux-instructions.md
+# https://github.com/dotnet/runtime/blob/master/docs/workflow/building/coreclr/linux-instructions.md
SET (CMAKE_C_FLAGS_RELEASE_INIT "-g -O3")
SET (CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-g -O2")
:call_vs
if not exist "%_VSCOMNTOOLS%" (
echo %__MsgPrefix%Error: Visual Studio 2017 or 2019 required.
- echo Please see https://github.com/dotnet/coreclr/blob/master/Documentation/building/windows-instructions.md for build instructions.
+ echo Please see https://github.com/dotnet/runtime/blob/master/docs/workflow/building/coreclr/windows-instructions.md for build instructions.
exit /b 1
)
echo %__MsgPrefix%"%_VSCOMNTOOLS%\VsDevCmd.bat"
*/
// ******************************************************************************
-// WARNING!!!: This code is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/gcdecoder.cpp
+// WARNING!!!: This code is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/gcdecoder.cpp
// ******************************************************************************
#ifdef _TARGET_X86_
*/
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/gcdump.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/gcdump.h
// ******************************************************************************
/*****************************************************************************/
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/gcinfo.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/gcinfo.h
// ******************************************************************************
/*****************************************************************************/
*****************************************************************/
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/gcinfodecoder.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/gcinfodecoder.h
// ******************************************************************************
#ifndef _GC_INFO_DECODER_
#include "gcinfodecoder.h"
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/gcinfodumper.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/gcinfodumper.h
// ******************************************************************************
//
#endif
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/gcinfotypes.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/gcinfotypes.h
// ******************************************************************************
#define PARTIALLY_INTERRUPTIBLE_GC_SUPPORTED
extention (eg. strike). There is no memory allocation system calls etc to purtub things */
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/stresslog.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/stresslog.h
// Parser: https://github.com/dotnet/diagnostics/blob/master/src/SOS/Strike/stressLogDump.cpp
// ******************************************************************************
//
// ******************************************************************************
-// WARNING!!!: This header is also used by the coreclr repo.
-// See: https://github.com/dotnet/coreclr/blob/master/src/inc/tls.h
+// WARNING!!!: This header is also used by the runtime repo.
+// See: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/inc/tls.h
// ******************************************************************************
#ifndef __tls_h__
| completed | functionality | location |
| --------- | ---------------- | -------- |
-| ✅ | IPC protocol | dotnet/coreclr |
-| ✅ | EventPipe Provider Enable/Disable | dotnet/coreclr |
-| ✅ | EventPipe Event-Provider coherence | dotnet/coreclr |
+| ✅ | IPC protocol | dotnet/runtime/src/coreclr |
+| ✅ | EventPipe Provider Enable/Disable | dotnet/runtime/src/coreclr |
+| ✅ | EventPipe Event-Provider coherence | dotnet/runtime/src/coreclr |
| ✅ | `dotnet trace` provider parsing | dotnet/diagnostics |
| ✅ | `dotnet trace` provider-profile merging | dotnet/diagnostics |