summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2015-11-17Merge pull request #2079 from mikedn/no-decompJan Kotas1-0/+2
Ifdef out useless code in JIT lowering
2015-11-17Merge pull request #2082 from BruceForstall/Fix2053Bruce Forstall1-1/+3
Fix RyuJIT assert 'emitCurIG != emitPrologIG'
2015-11-17Merge pull request #2042 from kouvel/StartupFlagsJan Kotas3-12/+97
Allow setting some startup flags outside Windows
2015-11-17Merge pull request #2049 from stephentoub/uuid_generate_randomJan Kotas1-3/+3
Use uuid_generate_random instead of uuid_generate in CoCreateGuid
2015-11-17Fix RyuJIT assert 'emitCurIG != emitPrologIG'Bruce Forstall1-1/+3
This occurs when the call-to-finally block exists as the last code in the function (including any funclets). After we generate all "normal" code, we start over and generate code for all the prologs and epilogs. In this case, we didn't reset the emitForceNewIG global, which determines if we should force a new IG to be created the next time code is generated. It is used for specifying no-GC regions. This fix initializes it (along with emitNOGCIG) at the beginning of generating and prolog or epilog.
2015-11-17Merge pull request #2016 from steveharter/CMakeSteve Harter12-44/+125
Enable Clang sanitizers for debug builds (address sanitizer, undefined behavior sanitizer and leak sanitizer)
2015-11-17Ifdef out useless codeMike Danes1-0/+2
In 64 bit builds Lowering::DecompNodeHelper does nothing so walking the trees is pointless. Profiling indicates that this accounts for 0.5% of the mscorlib crossgen time.
2015-11-17Merge pull request #1983 from LLITCHEV/SystemVStructsCleanupPat Gavlin4-21/+69
Fixed a bad merge issue.
2015-11-17Enable CLANG sanitizers for native debug buildsSteve Harter12-44/+125
2015-11-16Fixed a bad merge issue and some internal API cleanup.Lubomir Litchev4-21/+69
Sometime ago when the SystemVStructs branch was PRed into master a bad merge has occured. Some struct classification cleanup for native vs. managed struct layout representation. When classifying a native layout of the struct use the following algorithm. 1. If the struct has special marshaling it has a native layout. In such cases the classifier needs to use the native layout. 2. For structs with no native layout, the managed layout should be used even if classified for the purposes of marshaling/PInvoke passing.
2015-11-16Fix for a rotation transformation bug.Eugene Rozenfeld1-2/+3
rotatedValueBitSize should be calculated from genActualType(rotatedValue->gtType) instead of rotatedValue->gtType. I added a test that was failing with an assert because of this bug: rol32ushort.
2015-11-15Add USEARCH_DONE check to StartsWith in System.Globalization.Nativestephentoub1-22/+24
The StartsWith ICU wrapper was not checking the result of usearch_first to see if it was USEARCH_DONE, indicating no match found. This has two ramifications: 1. When there isn't a match, USEARCH_DONE (-1) gets passed in as the textLength argument to ucol_openElements, which treats -1 as meaning the string isn't null-terminated, and thus ends up walking the string looking for non-ignorable collation elements. Our tests have been passing because they've been using strings containing only non-ignorable elements, and thus the first character checked causes us to bail and correctly return false. If nothing else, this is an unnecessary perf overhead. 2. But on top of that if there are only ignorable collation elements before the first null character in the string (e.g. if the string begins with a null character), then because we told ICU that the string ended at the first null character, it'll stop walking the string and return a match. e.g. "\0bug".StartsWith("test") returns true incorrectly. This commit simply adds a check for USEARCH_DONE to StartsWith. EndsWith already has such a check.
2015-11-15Merge pull request #2043 from stephentoub/startsendswith_nullStephen Toub3-16/+16
Pass target string lengths to ICU on Unix
2015-11-14Use uuid_generate_random instead of uuid_generate in CoCreateGuidstephentoub1-3/+3
The PAL implementation of CoCreateGuid is currently using uuid_generate. This will be based on high-quality randomness if available, otherwise it falls back to an algorithm that incorporates the local ethernet MAC address along with the current time and a pseudo-random generator. To avoid potential privacy issues, this commit switches to using uuid_generate_random, which instead falls back purely to a pseudo-random generator.
2015-11-13Allow setting some startup flags outside WindowsKoundinya Veluri3-12/+97
Allowing the GC-related flags to be set using properties passed into coreclr_initialize.
2015-11-13Remove an unsafe memory write in HeapFreeJohn Chen1-2/+0
The PAL implementation of HeapFree assumes that the memory region always have at least 4 bytes. Depending on the heap implementation, this is not necessarily true, and can potentially cause memory corruption.
2015-11-13Fix buffer overrun in SetMscorlibPathJohn Chen1-4/+6
2015-11-13Pass target string lengths to ICU on Unixstephentoub3-16/+16
Our current ICU shims for StartsWith, EndsWith, IndexOf, and LastIndexOf take the length of the source string but not the length of the target string. This forces ICU to compute the length of the string by searching for a null terminator. We can save those costs and be more accurate around nulls in the target string by passing the known length in.
2015-11-13Merge pull request #2034 from dotnet-bot/from-tfsJan Kotas1-2/+4
Merge changes from TFS
2015-11-12Merge pull request #2033 from brianrob/crossgen_perfmap2Brian Robbins7-58/+374
Enable Offline Generation of Text-Based Symbol Tables for NGEN Images
2015-11-12Merge pull request #2030 from jkotas/vs2015-update1-buildbreakJan Kotas1-1/+1
Fix build break on VS2015 Update 1
2015-11-12Merge pull request #2013 from mikem8361/createthreadMike McLaughlin13-58/+171
Fix Thread.Start while debugging bug on OSX.
2015-11-13Merge pull request #2031 from janvorli/fix-exceptions-in-filterJan Vorlicek1-1/+28
Fix processing of unhandled exception in exception filter
2015-11-12Fix Thread.Start while debugging bug on OSX.Mike McLaughlin13-58/+171
The OSX exception logic is running on a separate thread from the one that the exception happened. The CatchHardwareExceptionHolder::IsEnabled used to check for h/w exception holders assumed it was running on the thread the exception/holders happened not the exception notification thread. Moved the h/w exception holder count to the CPalThread object instead of a TLS thread variable so the OSX exception code can check it given a CPalThread instance. The main problem was that the stubmgr when creating a thread (for the start notification) put a breakpoint in ThePreStubPatch which is in the coreclr text section and because the h/w exception holder check was broken, it thought the breakpoint wasn't the debugger's and aborted the coreclr process. The other part of this fix is to put a h/w exception holder around the called to ThePreStubPatch in prestub.cpp. The stubmgr's delegate invoke subclass used the wrong registers for Linux/OSX to read the "this" and parameter registers. Added the proper ifdefs and registers (ecx -> rdi, rdx -> rsi) for the Unix platforms. On both Linux and OSX, the h/w exception holder check in the exception routing logic needed to check if the int3/trap is in DBG_DebugBreak so asserts always abort/core dump. Move DBG_DebugBreak to an assembly worker so the start/end address can be used for this check.
2015-11-12Fix inconsistent security annotationsJan Kotas1-2/+4
[tfs-changeset: 1547876]
2015-11-12Enable offline generation of text-based symbol tables for native images. ↵Brian Robbins7-58/+374
This is needed in order to profile applications on Linux using perf_event. This change also modifies the runtime to emit a perfmap entry when a native image is loaded so that offline trace processing tools can identify when a perfmap file for a native image is needed and generate it.
2015-11-12Merge pull request #2024 from jkotas/crossgen-ifdefsJan Kotas5-10/+16
Improve FEATURE_NATIVE_IMAGE_GENERATION ifdefs
2015-11-12Fix build break on VS2015 Update 1Jan Kotas1-1/+1
2015-11-12Fix processing of unhandled exception in exception filterJan Vorlicek1-1/+28
This change fixes processing of unhandled exceptions in exception filter on Unix. Before this fix, such exception leads to assert in the exception handling code due to the fact that the exception tracker of the unhandled exception is not popped from the exception tracker stack of the thread. Although the PopTrackers method was being called, it bailed out due to the fact that the exception tracker belonging to the unhandled exception has empty scanned stack range. The fix is to explicitly pop the tracker in the EX_CATCH that catches the exception from the filter. I have also re-enabled the JIT test b68872 that has uncovered the issue.
2015-11-12Merge pull request #2009 from LLITCHEV/Issue1995-1Lubomir Litchev3-17/+89
Fix for issue 1995.
2015-11-12Merge pull request #2026 from AlfredoMS/async_fixAlfredo Menendez Sancho1-2/+39
Fix Task so that RunContinuationsAsynchronously flag works with all continuations
2015-11-11Fix for issue 1995.Lubomir Litchev3-17/+89
This changes containg a fix for Issue 1995. When remorphing an argument that has been already completed (in case of CSE rewriting for example, as in this case) the classification code was not run properly and it is triggering an assertion. As the Issue 1995 states the assert failure is benign since the generated code is correct - the change of registers used during completed argument classification is not allowed and the code is not changing them. This changes add the necessary code to properly classify and assign registes for completed arguments remorphing, which complies with the expectations of the failing assert.
2015-11-11Merge pull request #2027 from erozenfeld/RotationImprovementsEugene Rozenfeld2-19/+67
Implement improvements for rotation matching.
2015-11-11Merge pull request #2025 from jkotas/fatal-errorJan Kotas1-1/+2
Use volatile store for g_hrFatalError
2015-11-11Implement improvements for rotation matching.Eugene Rozenfeld2-19/+67
1. Recognize patterns with XOR instead of OR, e.g., (x << 5) ^ (x >> 27). 2. Recognize patterns with instance or static fields and ref params. Only GTF_PERSISTENT_SIDE_EFFECTS (i.e., calls and assignments) and GTF_ORDER_SIDEEFF (i.e., volatile accesses) prevent tree matching. Before this change we used GTF_ALL_EFFECT.
2015-11-11Fix Task so that RunContinuationsAsynchronously flag works with all types of ↵Alfredo Menendez Sancho1-2/+39
continuation
2015-11-11Use volatile store for g_hrFatalErrorJan Kotas1-1/+2
2015-11-11Improve FEATURE_NATIVE_IMAGE_GENERATION ifdefsJan Kotas5-10/+16
2015-11-11Merge pull request #2015 from kouvel/TpaBinderJan Kotas8-13/+41
Fix a couple of issues involving assembly loading
2015-11-11Merge pull request #2017 from dotnet-bot/from-tfsJan Kotas1-1/+1
Merge changes from TFS
2015-11-11Fix a couple of issues involving assembly loadingKoundinya Veluri8-13/+41
Fixes #1740 - After an assembly is loaded through a custom load context, when its dependencies are being loaded and the dependencies are in an app folder but not on the TPA list, don't search app paths when using the TPA binder, and instead use the default binder for the dependent assembly to load dependencies through the same custom AssemblyLoadContext. Fixes #1187 - In the AssemblyName created by AssemblyLoadContext.GetAssemblyName(), don't initialize the CodeBase property since it's not in the exposed surface area for .NET Core. If the AssemblyName is passed to Assembly.Load(), note that regardless of the path sent to GetAssemblyName(), default search orders are still used to load the assembly by name. A custom AssemblyLoadContext would need to be used to control where an assembly is loaded from. - Fixed a couple of error messages that mentioned phone
2015-11-10Fix for build breakKyungwoo Lee1-0/+2
When building llilc against coreclr in Linux, m_IsSlotTableFrozen is defined under _DEBUG but it is used without guard "#ifdef _DEBUG" This is fix for it.
2015-11-10Merge pull request #1999 from adityamandaleeka/remove_suspensionJan Kotas13-112/+53
More PAL thread cleanup (last one)
2015-11-09System.BitConverter.ToString(Byte[] value, Int32 startIndex, Int32 length) ↵dotnet-bot1-1/+1
value is null message [tfs-changeset: 1546665]
2015-11-09Remove InternalRand.Aditya Mandaleeka1-22/+1
2015-11-09Remove thread parameter from several more PAL functions.Aditya Mandaleeka12-90/+52
2015-11-09Merge pull request #1998 from pgavlin/AddNinjaSupportPat Gavlin1-2/+8
Add support for ninja to the CoreCLR build.
2015-11-09Merge pull request #1994 from dotnet-bot/from-tfsJan Kotas6-10/+93
Merge changes from TFS
2015-11-09Add support for ninja to the CoreCLR build.Pat Gavlin1-2/+8
Just what it says on the tin.
2015-11-08Merge pull request #1990 from stephentoub/fix_eventsource_typoVance Morrison1-1/+1
Fix a typo in EventSource_EventParametersMismatch error string