Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/dotnet/runtime.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-07-12Add crash report to createdump for Linux Watson (#55438)Mike McLaughlin
Add crash report to createdump for Linux Watson For Linux Watson the crash report will contains the .NET Core version, the faulting process name (the module/assembly containing Main) and the managed exception info (including the exception HRESULT) and thread stack trace of the thread the caused the crash. Add the CLRDATA_MODULE_IS_MAIN_MODULE flag to the DAC's IXCLRDataModule::GetFlags API. Add code to get the managed method name and write it out as "method_name" (even on MacOS). Add native frame symbolization (unmanaged_name) using dladdr. Only get the image info once and save in a global Demangle the stack frame symbols Only write PH_HDR_CANARY section if neccessary
2021-07-11Support filtering ObjectAllocated callback for pinned object heap allocation ↵Yauk
only (#55448) * Prototype allocation profiler * Add callback for pinned objects * Fix the build issue caused by corprof.idl change * Improve the test * Misc changes for the tests Co-authored-by: Andrew Au <andrewau@microsoft.com> Co-authored-by: Yauk Jia <yaujia@microsoft.com>
2021-07-08Add crash report file for VS4Mac Watson (#54934)Mike McLaughlin
Add crash report file for VS4Mac Watson Add the --crashreport createdump command line option to enable this feature. Add crash thread (--crashthread) and signal number (--signal) command line options. Use std::vector for g_argCreateDump. Add the COMPlus_EnableCrashReport environment variable to enable this feature. Add simple json writer (JsonWriter). Remote unwinder: special case when encoding == 0 and IP after syscall opcode to popping return address Remove unwinder: add functionStart return from remote unwind API Add ModuleInfo struct containing the info about a native or managed module. Add StackFrame struct containing the info about a native or managed stack frame. Add signal number to PROCAbort. Currently the Linux crash report is stubbed out (empty). Better createdump logging. Add CrashReportWriter class.
2021-07-02Add support to DAC for reading tagged memory on tracked types (#54994)Aaron Robinson
* Add support to DAC for reading tagged memory on tracked types * Build error on macOS. * DACize the relevant SyncBlock APIs. Create helper function for tagged memory API querying.
2021-06-29InternalCanonicalizeRealPath: don't call strstr with uninitialized lpBuffer. ↵Tom Deseyn
(#54824)
2021-06-28Add YieldProcessor implementation for arm (#54829)Gleb Balykov
2021-06-18Fix Linux x86 build (#50836)Gleb Balykov
2021-06-15Add the concept of "notification profilers" to the runtime (#53122)David Mason
2021-06-15Fix PAL_JitWriteProtect export on Linux (#54190)Jan Vorlicek
* Fix PAL_JitWriteProtect export on Linux I have not realized that we actually export that symbol on Linux too and that mscordac then have the dummy function missing. * Code review feedback * Disable PAL_JitWriteEnable usage in DBI / DAC * Fix typo in amd64 version Co-authored-by: Mike McLaughlin <mikem@microsoft.com>
2021-06-12Unify macOS ARM64 write protection holders with W^X ones (#54067)Jan Vorlicek
* Unify macOS ARM64 write protection holders with W^X ones This change removes the original holders that were added for changing memory protection for executable code and moves the actual switching to the recently added W^X holders. The unixexports files don't support target specific symbols. So I needed to export a dummy version of the PAL_JitWriteProtect for macOS x64.
2021-06-10Fix gcc armel/arm64 build (#53220)Gleb Balykov
* Fix gcc armel build Mostly signed/unsigned comparisons, etc. * Fix gcc arm64 build
2021-06-09Build support for s390x: libunwind (#53286)Ulrich Weigand
* Merge https://github.com/libunwind/libunwind/pull/245 * Add s390x support to local CMake files
2021-06-09Build support for s390x: PAL layer (#53287)Ulrich Weigand
* Add PAL implementation for Linux on s390x * Define BIGENDIAN on s390x when compiling coreclr * Provide a default HAVE_FUNCTIONAL_PTHREAD_ROBUST_MUTEXES_EXITCODE value in eng/native/tryrun.cmake
2021-06-01Fix42292 (#52463)Steve MacLean
* Fix issue 42292 * Cleanup PAL issues.targets
2021-05-26Build support for s390x: Fix a few paltests (#53288)Ulrich Weigand
* Accommodate platforms (like s390x) where the SIGSEGV fault address is only provided on a page granularity by the HW/OS * All paltests now pass on s390x
2021-05-13Low level API support for Objective-C interop. (#52146)Aaron Robinson
* Add Objective-C interop support. * Include handling of HNDTYPE_REFCOUNTED when FEATURE_OBJCMARSHAL is defined (#47534) * Allow overriding of Objective-C message send P/Invokes (#47721) * Add new flag to MethodTable for types with ObjectiveCTrackedTypeAttribute. Discover attribute during type load and set bit. Update EagerFinalizer callout to query bit. * Add testing for API * Bridge API for propagating managed exception to native. * Update GCEE interface to support GCServer scenario for Objective-C. The new callbacks now fire when before the GC scans handles and is non-concurrent. * Comment added for ExceptionTracker non-NULL condition. Co-authored-by: Jeremy Koritzinsky <jekoritz@microsoft.com> Co-authored-by: Elinor Fung <elfung@microsoft.com> Co-authored-by: Rolf Bjarne Kvinge <rolf@xamarin.com>
2021-05-13Stresslog fixes (#52601)Peter Sollich
- Make regular (non-memory-mapped file based) stresslog work for clrgc.dll - Fix interaction issue between GC and thread filters in StressLogAnalyzer - Interpret small numbers for COMPlus_StressLogSize and COMPlus_TotalStressLogSize as GB rather than bytes - Increment SOS_BREAKING_CHANGE_VERSION
2021-05-07Do not count page cache towards cgroup’s memory load (#51738)Marcin Krystianc
* Do not consider file cache pages as used memory Since file cache pages can be easily evicted and re-used they should not be considered as used memory. * free stat_filename * consider dirty pages * diff noise * use memory.stat only * unix/cgroup.cpp * diff noise * use array * PR remarks
2021-05-04Generate coredumps on signals (#52024)Mike McLaughlin
Generate coredumps on signals On MacOS, coredumps are generated if there is an unhandled managed exception but signals don't generate them. Enable a stripped down version of the Linux signal handlers for MacOS. Add a SIGABRT handler so calls to abort() in other native code causes dump to be generated. Add COMPlus_EnableDumpOnSigTerm that enables dump generation on SIGTERM. Moved the "generate dump on SIGTERM" logic out of the PAL into runtime's HandleTerminationRequest callback and passed a new SCA enum down to SafeExitProcess that calls TerminateProcess instead of ExitProcess which generates a core dump.
2021-04-28Add an implementation of `RestoreContext` for Windows/amd64 for use with ↵Koundinya Veluri
shadow stacks (#51887) * Add an implementation of `RestoreContext` for Windows/amd64 for use with shadow stacks - Added `ClrRestoreNonvolatileContext` to Windows/amd64 similar to the PAL's `RtlRestoreContext` but allowing for example continuing from exception in managed code when shadow stacks are enabled - Updated to use the new implementation for cases that don't need the volatile register state restored. The two remaining cases that still use `RtlRestoreContext` would have to be changed later to use a different mechanism. - For other targets, forwarded `ClrRestoreNonvolatileContext` to `RtlRestoreContext` for now
2021-04-16Fail the GCHeap initialization if large page is specified without a heap ↵Andrew Au
hard limit (#51282)
2021-04-13Rely on initial pthread_jit_write_protect_np state (#51135)Steve MacLean
2021-04-08cruntime/*printf*: free temporary string buffers also on failure (#50469)Tom Deseyn
2021-04-07Remove extraneous CMake version requirement. (#50805)Jeremy Koritzinsky
2021-04-07Remove IAssemblyName (and various fusion remnants) (#50755)Elinor Fung
2021-04-06Reorganize CoreCLR native build to reduce CMake reconfigures when the build ↵Jeremy Koritzinsky
system is untouched (#49906)
2021-03-26 Block debugger attach after any ApplyUpdate changes (#50200)Mike McLaughlin
* Block debugger attach after any ApplyUpdate changes * Add better error message for ApplyUpdate while debugging * Code review feedback * Fix arm32/arm64 builds * Code review feedback * Code review feedback
2021-03-24Fix Alpine 3.13 ARM build (#50105)Jan Vorlicek
* Fix Alpine 3.13 ARM build Alpine 3.13 is the first version of Alpine Linux that uses 64 bit time_t on both 64 and 32 bit platforms. That breaks the build as we assumed that 32 bit platforms use always 32 bit time_t. This change fixes it by making the PAL time_t type always 64 bit. Everything still works fine on non-Alpine ARM / x86 Linuxes, since it only changes the time_t type size outside of PAL. * Fix case when time function gets NULL argument
2021-03-22Apple Silicon fix remote unwinding (#49974)Steve MacLean
2021-03-19Fix or disable warnings on latest VS dogfood (#49799)Jan Kotas
* Fix or disable warnings on latest VS dogfood * Delete JIT local warning disables
2021-03-12[mono][debugger] Implementing mscordbi to support iCorDebug on mono runtime ↵Thays Grazia
(#47639) * Implementing mscordbi on mono to support icordebug * Fix eval, fix step and cancel step, remove suspend status on mscordbi * Using log from coreclr as mscordbi does * Missing files * Removing eglib from implementation * Compiling on Mac * Compiling and Working on windows. Changing what @lambdageek suggested about mono_atomic_inc_i32 * Generating libmscordbi on mac * Fix socket on mac * Counting references, deleting objects, removing unecessary properties, formating with cland-format, renaming properties to follow the used pattern. * Checking error when get reply from debugger * Fix format, reuse regmeta from coreclr and try to fix compilation on windows * Dont build when target is android or ios or wasm * Fix error unused variable * Fixing error: 'CFUserNotificationDisplayAlert' is unavailable: not available on macCatalyst * Fix compilation error on Linux * Fix function not found in maccatalyst Fix warning as error of macro redefinition * Dont compile mscordbi on maccatalyst * Fix compilation on linux * Fix compilation on android, ios and browser * Fix compilation on linux * Fix cross compiling * Fix compilation x86 windows * Fix x86 compilation * Fix compilation on windows * Fix cmake error * Fix cmake * Fix arm64 mac * Fix windows compilation * Fix memory leak * Returning E_NOTIMPL where it was possible and it's not implemented as suggested by @cshung * Fix what @cshung * Use only one ref count * Adding ex_try everywhere that we could have an allocation failure. * Implementing get class * Apply suggestions from code review Co-authored-by: Noah Falk <noahfalk@users.noreply.github.com> * Fix what @noahfalk suggested in his review. * Fixing what was suggested by @viniciusjarina * Fix what was suggested by @viniciusjarina * Changing what @noahfalk suggested * Accept more than 1 stepper per thread * Changing what was suggested by @noahfalk * Using CORDB_ADDRESS to return addresses from debugged process * Fix eval * Update src/mono/mono/mini/debugger-agent.c Co-authored-by: Aleksey Kliger (λgeek) <akliger@gmail.com> * Using 1:1 with runtime for cordbtype and cordbclass * Rnaming methods as suggested by @lambdageek * Update src/mono/dbi/cordb-process.h Co-authored-by: Aleksey Kliger (λgeek) <akliger@gmail.com> * Update CMakeLists.txt * Fix arm64 compilation * Fix arm64 compilation * Fix error cmake * fix arm64 compilation * Fix arm64 compilation * Fix arm64 compilation * Fix arm64 compilation * Revert "Fix arm64 compilation" This reverts commit 25f24bc7ac66966fe59805e54e4009c909608b2c. * Revert "Fix arm64 compilation" This reverts commit a8f0318881d7b3e6b5a69b1b56c17478a71fdb4f. * Revert "fix arm64 compilation" This reverts commit b5de06dcf00bf296f2c8f4b47aa2492afbd73acd. * Revert "Fix error cmake" This reverts commit 2aae4636499d073ca5aa6fb9319d84875be6e08e. * Revert "Fix arm64 compilation" This reverts commit ae5f701589c3bd8ca04b9d9369af2b285a5d9bd0. * Revert "Fix arm64 compilation" This reverts commit 94d957c7416a900c9e90dec53900a104572ea6a1. * Removing arm64 compilation * Remove arm64 compilation Co-authored-by: Noah Falk <noahfalk@users.noreply.github.com> Co-authored-by: Aleksey Kliger (λgeek) <akliger@gmail.com>
2021-03-12Remote unwinder's put_unwind_info function needs to cleanup for ↵Mike McLaughlin
FEATURE_USE_SYSTEM_LIBUNWIND (#49444) Fixes issue: https://github.com/dotnet/runtime/issues/42561
2021-03-02Delete low-value PAL test (#48932)Jan Kotas
This partially reverts commit 77c939c9c9acfc49fcb7dc695ff33d03ca06f99e. Fixes #48496
2021-03-02Setup OSX.1100.ARM64.* helix queues (#47919)Steve MacLean
* Setup OSX.1100.ARM64.* helix queues * Enable Apple Silicon test on initial set of several CI pipelines (no-PR). * Disable failing Apple Silicon PAL tests * Revert "Apple Silicon disable failing PAL tests (#48782)"
2021-03-02cgroup: fix memory leak in GetCGroupMemoryUsage (#48911)Tom Deseyn
2021-02-26Apple Silicon disable failing PAL tests (#48782)Steve MacLean
2021-02-19Probe libnuma.so.1.0.0 before its symlinks (#48133)Adeel Mujahid
On Linux, libnuma.so{.1} are symlinks to libnuma.so.1.0.0. When installed from default package manager; Ubuntu (libnuma-dev) and Alpine (numactl-dev), found these two symlinks: `{libnuma.so,libnuma.so.1} -> libnuma.so.1.0.0` On Fedora (numactl-libs): `libnuma.so.1 -> libnuma.so.1.0.0` (there is no version-less variant) PR adjusts probing fallback flow based on this info.
2021-02-18Setting Thread.Name sets the native thread name on MacOS. (#47465)Eric Soros
* Setting Thread.Name sets the native thread name on MacOS. Setting Thread.Name will now set the name of the native thread on MacOS - due to API constraints this will not work cross thread. Fix #47087 * adding tests and formatting fixes
2021-02-18Adjust logic in cor.h, corhdr.h, corinfo.h, corjit.h and such so that they ↵David Wrighton
may be included without the PAL (#46055) This was done via simple substitution of the standard sized integer types, and dealing with the fallout. It is tested by using the ICorJitInfo interface directly within the crossgen2 jitinterface thunk library. Effort was made to use a minimum number of casts, as casts in such a large change are likely to be wrong somewhere. - Exceptions are the use of casting to handle some calls to the existing internal metadata api and around use of char16_t. In addition, a small amount of logic from the PAL headers were pulled into the proper header to allow compilation in the presence of some SAL annotation, and other small details.
2021-02-11Do not use /dev/zero to mmap anonymous memory (#48140)Vladimir Sadov
* return void * Always use MAP_ANON * remove HAVE_MMAP_DEV_ZERO config
2021-02-03Fix throw decl for math functions (#47687)Adeel Mujahid
2021-01-30Set some pointers to null after free()ing them (#47415)Omair Majid
These free() calls are done in the middle of the method body; it's possible that a duplicate free() can be called on these at the cleanup code that runs before the method returns. So set these pointers to null after free()ing them to avoid free() already free()d memory.
2021-01-30Clean up some of the math intrinsic logic and support constant folding (#47321)Tanner Gooding
* Removing unecessary casts to float/double from the classlibnative COMSingle and COMDouble types * Reordering NI_System_Math_* usages to make it easier to spot errors * Removing unecessary support for Cos/Sin as "target intrinsics" * Adding asserts and changing target cost for math intrinsics to be based on IsTargetIntrinsic * Don't include PAL math wrappers where no additional functionality is needed * Adding valuenum support for the remaining Math intrinsics, minus FMA and SinCos * Allow constant folding for all math intrinsics when not IsReadyToRun is false * Apply formatting patch * Adding THROW_DECL to match functions to satisfy GCC * noodes to nodes * Removing ScaleB named intrinsics * Update src/coreclr/jit/codegenxarch.cpp
2021-01-29pal: free tempfile_name if GetTempFileNameA fails (#47477)Omair Majid
If GetTempFileNameA fails, we don't free up the dynamically allocated memory that tempfile_name points to.
2021-01-29Fix some valgrind warnings about jumps based on uninitialized values. (#47620)Tom Deseyn
2021-01-28Retry sem_wait() on EINTR (#47536)Steve MacLean
2021-01-28Fix assert on unhandled SIGSEGV (#47538)Jan Vorlicek
When SIGSEGV is not handled by .NET runtime (e.g. when it occurs in code out of its control), the SIGSEGV handler ends up calling DiagnosticServer::Shutdown in the runtime via a registered shutdown callback. That method ends up calling Thread::GetFrame, which asserts if the current SP is out of a valid range for the regular stack. The problem is that SIGSEGV handler is called on an alternate stack and so this callback ends up being called on that stack too. That causes this assertion to fail, because the current thread is not marked as executing on alternate stack, which would skip that assert. This change fixes it by passing through a bool flag indicating whether the callback was called on an alternate stack or not. And in that callback, we set the flag on the thread accordingly.
2021-01-26Added C# implementation of System.Math.ScaleB and System.MathF.ScaleB… ↵Alex Covington
(#42476) * Added C# implementation of System.Math.ScaleB and System.MathF.ScaleB, removed old bindings, added test cases. * Moved tests into System.Runtime.Extensions tests. * Removed unmanaged scalbn and scalbnf from pal and mono * Update src/libraries/System.Private.CoreLib/src/System/Math.cs Co-authored-by: Adeel Mujahid <adeelbm@outlook.com> * Styling changes. * Conditionally include ScaleB for Mono. * Update src/mono/mono/metadata/sysmath.c Tabs, not spaces. Co-authored-by: Adeel Mujahid <adeelbm@outlook.com> * Removing more scalb from PAL * Completely removed ScaleB from Mono * Cleaning up more scalbn * Added comments for ScaleB, updated licenses for musl and Sun * Fixed whitespace. * Removing old references, fixing double ScaleB definition that merge didn't resolve Co-authored-by: Adeel Mujahid <adeelbm@outlook.com>
2021-01-22Linux: don't use deprecated sysctl (#45753)Tom Deseyn
* Linux: don't use deprecated sysctl * Handle deprecated sysctl in coreclr, gc, corehost.
2021-01-14Prefer ucontext.h over sys/ucontext.h (#46790)Adeel Mujahid
* Prefer ucontext.h over sys/ucontext.h * Cleanup redundant _XOPEN_SOURCE definitions * Remove unused makefile from PAL tests