Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
|
|
* Ensure Environment.ExitCode works correctly after app domain unloaded.
This PR addresses 2 problems of Environment.ExitCode:
1. Can't get correct exit code of main function.
2. Can't set %errorlevel%.
Details can be found on #6206
Fix #6206
|
|
* [x86/Linux] CDECL as default P/Invoke Calling Convetion
|
|
|
|
|
|
This reverts commit 751771a8976f909af772e35c167bd7e3ffbe44c8.
|
|
|
|
|
|
WIP, fix compile error for x86/Linux
- fix to use STDMETHODVCALLTYPE
|
|
|
|
Methods that contain no metadata (e.g. of sources are IL Stubs,
DynamicMethod, Expression Trees, etc.) also known as LCG methods are not
reported to profilers via the Profiling API. LCG, introduced in .NET 2.0
timeframe is unique in that it doesn't require the method to be hosted
in an assembly > module > type heirarchy and is GCable in of itself.
This change adds new APIs that notify the profiler of such methods but
since there is no metadata to go lookup, it provides some useful pieces
of information that the profiler author may want to expose to the
profiler user.
In the compilation start method we provide a className (always
dynamicClass), a methodName that can be a set of few predetermined names
like (ILStub_COMToCLR, etc.) or if the user has set the name for the LCG
method that can show up here. For example, when using the Expression
Trees API, the user can specify a friendly name which would be returned
here.
In the jit completed callback we provide information for the native code
start address and size. This is particularly useful to get more accurate
accounting of what the (previously unidentified) code is. At least the
user would know it is JITTed if nothing more (but most likely more
information like what kind of stub).
Furthermore, since this is going to be a profiler callback, the profiler
can initiate a stackwalk and give more contextual information to its
users beyond the pieces of information we can provide here that could
identify what they're encountering.
Finally, there is also the case that today the profiling APIs
underreport JITTed code in the process. Considerable amount of LCG code
can now be present in the program and in security-sensitive environments
where tracking JITTed code for security reasons is important the
profiling apis fall short. In such environments there is also often
restrictions on running with elevated privileges, so procuring this data
through other means (like ETW) may pose a challenge.
|
|
* add typeID APIs
* add variable home API
|
|
executables on Nano Server (#7317)
Needed to add back a dummy version of ICorDebugLegacyNetCFHostCallbackInvoker_PrivateWindowsPhoneOnly interface so
VS doesn't get the QI failure and stop working by not calling the "Continue" method.
Issue #7316
|
|
building entire project as C++ for Unix (#6801)
Enable building CoreCLR as C++ project on Unix
This series of patches fixes the strict aliasing violation from
the conditional typedef of wchar_t in src/pal/inc/pal_char16.h:40
* rename c files to cpp
* modify all cmake files to change .c files to .cpp
* apply c++ linkage to templates
|
|
Instruction emulation for Break Points
Debugger::FuncEvalSetup
NativeWalker
ExceptionHijack
Exception intercept
Managed Return Value
|
|
|
|
Currently only enabled for arm64
|
|
|
|
|
|
- Delete BINDER, STANDALONE_BINDER and MDIL ifdefs
|
|
Added a SOS DAC interface (ISOSDacInterface4::GetClrNotification) to get the exception
notification arguments instead of using the GetLastExceptionInformation function from the lldb
sosplugin that depends on coreclr symbols being present.
On the coreclr side, the clr notification arguments are saved in a global variable that is DAC
accessible. A critical section was added to protect this global variable while the special
exception is raised.
Setting the internal COMPlus_DebugBreakOnAssert environment variable causes 3 or 4 breaks in
the debugger with no reason. It was breaking in the function that was determining whether it
should break. I was using COMPlus_BreakOnEELoad=2 to break after coreclr was loaded and initialized
to set managed breakpoints and on a debug build it generates an assert (on release just a DebugBreak).
|
|
Enabling profiling on Unix/OS X
|
|
|
|
|
|
required for Event Logging
will be generated as part of build
|
|
Add and implement new ICorDebugDataTarget4 unwind interface using lldb stack unwinder ABIs. The implementation
does a linear search of the native frames for the stack pointer provided. It doesn't happen often so the
performance is fine.
Stub out the DBI's ICorDebugDataTarget4 (in ShimDataTarget::VirtualUnwind) for now. Since PAL_VirtualUnwindOutOfProc
is disabled it makes sense to just return E_NOTIMPL.
Fix bpmd command so it doesn't stop in lldb when it isn't a CLRN exception (continues).
|
|
Core runtime and GC changes from https://github.com/Microsoft/dotnet/blob/master/docs/releases/net461/dotnet461-changes.md that are not in CoreCLR yet
[tfs-changeset: 1543382]
|
|
|
|
Adding an environment variable COMPlus_EnableEventLog to turn on/off
Xplat Event Logging, by default Xplat Event logging is turned off
|
|
The Tracepoint Providers are built as a separate shared object called libcoreclrtraceptprovider and it is
available in the same directory as libcoreclr.so
By Default the ability of Tracing will not be present
To enable the ability of Tracing, the apps need to be run like:
LD_PRELOAD=libcoreclrtraceptprovider.so ./corerun HelloWorld.exe
For now to change Xplat Event Logging mechanism add any events to:
<root>/src/vm/ClrEtwAll.man
Then regenerate files by running :
<root>/src/inc/genXplatLtnng.pl
Conflicts:
Documentation/building/linux-instructions.md
|
|
corresponds to the following user story: 1200238. As a profiler developer, I want to access PDB content for dynamic assemblies in the ETW event stream, so that I can show my users source for their callstack frames.
The main function in eventtrace.cpp, EmitCodeSymbols, divides the pdb stream into appropriate chunks and transmits them as events in order. There are helper functions which have been taken from the corresponding code in Desktop (Netfxdev1) to provide a dynamically loaded pdb through the profiler authored by Noah.
The test uses EventToSymbols, which is based on TraceEventParser to turn on the CodeSymbols and ModuleLoad keywords and listens for events that send out pdb chunks. It then concatenates the chunks to create the pdb on disk. The BigPdb.cs program loads a dll and pdb dynamically, which triggers the events by the runtime. Once the pdb is recreated, it is compared with the original to make sure there are no differences and if not, the test is declared as passed. The test also uses an EventSource event to transmit a unique cookie to make sure the pdb created corresponds to the process under test, in case there are mulitple instances of the test running.
[tfs-changeset: 1535373]
|
|
Implementation of PAL_VirtualUnwindOutOfProc that uses ptrace libunwind
to be able to unwind native stack in debugee. This allows to get valid managed
stack for threads that passed HelperMethodFrames.
|
|
The "gcroot" command currently doesn't work with lldb 3.6 (our default package), but
works fine with lldb 3.7.0.
lldb 3.6 terminates with
(lldb) sos GCRoot 00007fffcc004ce8
*** Error in `lldb-3.6': munmap_chunk(): invalid pointer: 0x000000000184cde8 ***
PAL_STDCPP_COMPAT is the define that the VS team added to allow the xplat
headers to be used. This is neccessary for the whole SOS directory now
because gcroot and other gc commands need unorderd_map, unorderd_set, etc.
from the stdlib.
Had to change all wchar_t to WCHAR because the xplat stdlib default is UTF32.
Had to rename and provide macros that conflict with the stdlib:
wcslen -> _wcslen
wcsncmp -> _wcsncmp
wcsrchr -> _wcsrchr
wcscmp -> _wcscmp
wcschr -> _wcschr
wcscspn -> _wcscspn
wcscat -> _wcscat
__in -> ___in
__out -> ___out
max(a, b) -> _max(a, b)
min(a, b) -> _min(a, b)
Had to ifdef PAL_STDCPP_COMPAT a lot more of pal.h, palrt.h and some other header files.
Changed a bunch of L"" to W("").
|
|
[tfs-changeset: 1509924]
|
|
|
|
It matches what we do in the legacy build environment. The x64 version of the header file is causing build breaks on x86 as @mikedn found out.
[tfs-changeset: 1509675]
|
|
[tfs-changeset: 1466545]
|
|
|
|
|
|
.rc and .def files were missing the MIT license headers, so this
change adds them.
|
|
|
|
This change fixes:
1) Member initiazalization order in class constructor didn't correspond to the member order in some classes
2) Objects with vtables were copied via memcpy. While this is intentional, cast of the pointers to void*
is required to silence clang warning
3) Switch case statements containing values of different enums
4) Casting int to pointer
5) Missing return value in methods with _ASSERTE
6) Class name classifier on methods in the .h
7) Invalid position of the DECLSPEC_ALIGN at few places - it had no effect
8) Invalid position of the 'used' attribute
9) Issue with comparing holders to NULL
10) Operator 'new' returning NULL without being marked with throw() or noexcept
11) Variables marked as 'extern' at the declaration / initialization place
12) Data structure declared as struct at one place and forward declared as class at another
Some disabled warnings were no longer happening, so options to disable them were removed too
|
|
|
|
A lot of security transparency annotations in corefx is missing or inconsistent. People keep running into MethodAccessExceptions because of that. It is not easy (nor cheap) to fix the annotations to make them consistent, and they are not actually required for any of the .NET Core scenarios.
This change is introducing a hosting flag to disable security transparency checks on CoreCLR, and adds this flag to all .NET Core hosts. The .NET Core hosts outside of the CoreCLR tree (e.g. ASP.NET 5) will need this flag added as well.
[tfs-changeset: 1437325]
|
|
Add new nuget package that can be developed against. Also modify the cmake lists of a few directories to add in missing PDBs.
|
|
- Compile DBI on Linux.
- Link DBI on Linux to the point when only symbols related to INativePipeline are missing.
In order to completely link DBI we'll have to do some development, and it will be addressed by a separate change.
[tfs-changeset: 1411066]
|
|
[tfs-changeset: 1407945]
|