Age | Commit message (Collapse) | Author | Files | Lines |
|
* Abstract away NOINLINE statement
MSVC and GNU compilers use different attributes for noinline.
Abstract away compiler differences.
* Replace __sync_swap with __atomic_exchange_n
__sync_swap doesn't exist on GNU. Replacing with __atomic_exchange_n
which is universally available.
* Define CDECL for GNUC
__cdecl is not defined by default on GNU compilers.
* Define gcc version of __declspec(thread)
* Correct pointer casting
A pointer value is usually unsigned long on most platforms.
Casting it to integer causes signedness issues. Use size_t
to be efficient on all 32 and 64 bit architectures.
* Put quotes around the error string
Correct error statement. GNU G++ is picky about the string
following the error statement with ' character in it. It needs
to be enclosed with double quotes.
* Fix casting problem
Seeing these warnings with GNU G++ compiler
src/pal/src/sync/cs.cpp: In function ‘void CorUnix::InternalInitializeCriticalSectionAndSpinCount(PCRITICAL_SECTION, DWORD, bool)’:
src/pal/src/sync/cs.cpp:630:48: warning: converting to non-pointer type ‘SIZE_T {aka long unsigned int}’ from NULL [-Wconversion-null]
pPalCriticalSection->OwningThread = NULL;
^
src/pal/src/sync/cs.cpp: In function ‘void CorUnix::InternalLeaveCriticalSection(CorUnix::CPalThread*, _CRITICAL_SECTION*)’:
src/pal/src/sync/cs.cpp:880:43: warning: converting to non-pointer type ‘SIZE_T {aka long unsigned int}’ from NULL [-Wconversion-null]
pPalCriticalSection->OwningThread = NULL;
^
* Abstract optnone compiler attribute
GNU compiler doesn't support optnone attribute.
pal/src/exception/seh-unwind.cpp:449:77: warning: ‘optnone’ attribute directive ignored [-Wattributes]
* Set the aligned attribute for GNU compiler
* Make __rotl and __rotr functions portable
GNU compiler doesn't have an intrinsic for these. Open code them
using the provided implementation.
* Define deprecated attribute for gcc
* Add throw specifier for GCC
/usr/include/string.h:43:28: error: declaration of ‘void* memcpy(void*, const void*, size_t) throw ()’ has a different exception specifier
size_t __n) __THROW __nonnull ((1, 2));
|
|
|
|
* Add -skipcrossarchnative option to build.cmd
This allows you to skip building the cross-architecture native components.
* Add -skipcrossarchnative to build.sh
|
|
The former does extra work that the latter doesn't do, and they're equivalent when we know it contains a value, such as immediately after a HasValue check.
|
|
expression evaluation in ProjectN async stepping.
[tfs-changeset: 1732745]
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
* increase arm64 debug/checked timeout.
* Increase timeout only for corefx jobs.
|
|
tracing/eventsourcetrace/eventsourcetrace/eventsourcetrace.sh (#22328)
Marking this test `GCStressIncompatible` = True for now.
|
|
Move Jenkins off the Ubuntu.1604.Arm64.Open queue so it can be repurposed for Azure DevOps. This "Iron" queue should only be used by Jenkins.
|
|
Thanks to tons of help from Jan Vorlicek I found out that a huge
failure bucket in the CoreCLR Pri#1 tests is caused by incorrect
GC info for generic methods causing failures in catch clauses
where the exception type is a generic referring to a generic
parameter of the method.
As part of investigation of this issue I'm adding provisions for
dumping the GC info alongside methods to make the differences
between CPAOT and Crossgen easier to analyze.
For now I have only implemented the AMD64 variant of the GC info.
Thankfully it turns out that the same GC info is used by both ARM32
and ARM64 so that the only remaining debt is supplying a variant
of the new code for X86.
Thanks
Tomas
|
|
Use the same logic that's used in build.sh/build.cmd to lookup python:
first search for `python3`, then fall back to `python2` and finally to
`python`.
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
GC stress testing revealed a deficiency in GC ref map on ARM64 - we weren't
emitting the entry corresponding to the X8 return buffer address because
a recent refactoring changed its location in the transition block. This change
generalizes transition block by exposing a new function
GetOffsetOfFirstGCRefMapSlot()
that returns the same value as
GetOffsetOfArgumentRegisters()
except on ARM64 where it returns the offset of the X8 register in the
transition block (above the callee-saved registers and 8-byte padding i.e.
at position 13 corresponding to offset 0x68, or
GetOffsetOfArgumentRegisters() - 8).
Thanks
Tomas
|
|
* Add design document for the unloadability
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
(#22305)
* Stop collecting source line information during a stacktrace for the Exception.Source property.
* Code review feedback
|
|
|
|
(#22312)
|
|
master-20190130.3, respectively (#22310)
|
|
This moves us one step away from buildtools and towards arcade.
This replaces run.sh and run.cmd (and all invocations) with "dotnet.sh msbuild" and "msbuild.cmd".
- I'm using these wrapper scripts for now instead of those in eng/common in order to retain the very helpful "Running <command>" output in the build logs.
- I'm using msbuild.cmd instead of dotnet.sh to match the current behavior that uses desktop msbuild on windows, instead of dotnet.
All of the arguments that used to be implicitly generated by run.exe and config.json are now explicit, resulting in longer (but easier to copy+paste) commands. Some of these arguments are likely unnecessary, but in this change my goal is just to match the run.exe behavior. Later, I would like to go through and clean up parameters that don't need to be passed in every invocation. I might also consider moving more of the common arguments out into variables in a later change.
Some of the wrapper scripts now have limited support for parsing "-Argument=Value" style parameters, to support our existing buildpipeline infrastructure, since I thought this was easier to test than changing our buildpipeline definitions. We can remove that parsing logic once we stop using buildpipeline (which has happened at this point).
Some subtle parts of the change:
* Add msbuild.cmd
This simulates the behavior of Tools\msbuild.cmd, which calls desktop msbuild.
* Fix BuildOS processing in package build and publish
Previously, config.json had its own processing that would set
OSName. Instead, we now pass it in explicitly where it's
needed (building packages), or not at all (publishing them).
* Handle "=" in publish-packages.cmd and other scripts
This seems necessary to properly handle the azure access token
* Set __BuildOS in PublishPackages
Required for cases where the build OS isn't detected during the build
such as freebsd.
* Use dotnet msbuild in runtest.py
This prevents us from having to deal with different quote escape
behavior on windows and linux. Previously, arguments like
fileloggerparameters and the logger were given quotes to escape
semicolons in the argument. On unix, this prevented the argument from
being split up by bash. On windows, it seems that the run.cmd/run.exe
tools would prevent the extra quotes from being passed to
msbuild.exe (desktop msbuild would choke on the quotes if they were
passed along).
Unlike desktop msbuild, dotnet msbuild is able to parse the quoted
strings, so we simply psas the quoted arguments directly to it on
windows. We may be able to do the same on unix.
* Fix build-test.sh problem with BuildOS
When copying native files during the unix test build, we rely on
__BuildOS being set. Fixing the import order and always setting
__BuildOS fixes this. We should eventually fix the inconsistent use of
BuildOS vs __BuildOS.
|
|
-0.0" (#22300)
|
|
|
|
|
|
* JIT\jit64\opt\cse\hugeexpr1 on Linux/arm
Related issue: https://github.com/dotnet/coreclr/issues/22260
* baseservices\threading\interlocked\compareexchange\CompareExchangeTClass
* baseservices\threading\interlocked\compareexchange\CompareExchangeTClass_1
Related issue: https://github.com/dotnet/coreclr/issues/22303
|
|
IsVarAddr was checking GTF_ADDR_ONSTACK to determine if
the GT_ADDR node is an address of a local. This change removes both
GTF_ADDR_ONSTACK and IsVarAddr and uses IsLocalAdrExpr instead.
IsLocalAddrExpr uses opcodes to determine if GT_ADDR node is
a local address.
GTF_ADDR_ONSTACK flag is ancient, added before 2002 so I couldn't find
the checkin that introduced it.
I changed the assert to a check and an assignment since simplifications
inside fgMorphArgs between
https://github.com/dotnet/coreclr/blob/1a1e4c4d5a8030cb8d82a2e5b06c2ab357b92534/src/jit/morph.cpp#L3709
(which causes https://github.com/dotnet/coreclr/blob/1a1e4c4d5a8030cb8d82a2e5b06c2ab357b92534/src/jit/morph.cpp#L3057)
and
https://github.com/dotnet/coreclr/blob/1a1e4c4d5a8030cb8d82a2e5b06c2ab357b92534/src/jit/morph.cpp#L3790
may result in more GT_ADDR nodes recognized by IsLocalAdrExpr.
x86 and x64 pmi frameworks had no code diffs and some gcinfo reductions
(15 methods with gcinfo diffs in x86).
Fixes #22190.
|
|
This requires merging/adapting the implementation with EnvironmentAugments (which goes away completely), the shared files, what corert has, etc.
|
|
The checked in batch script was only usable if you have a Razzle environment and even then it didn't update the right files.
|
|
|
|
Moving to the namespace that was approved in dotnet/corefx#34124.
|
|
When we unified the implementations of these across all of our runtimes, we lost all size optimizations people have been doing on the Project N side over the past six years.
This restores a bit of the loss. For one sample app with lots of async usage, this removes 2.1 MB of generic instantiations.
There is more we can do, but I can't spend time on that right now. These two things jumped out on me when I was looking at it back in December and were an easy fix I wanted to do for a while.
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|
|
|
|
FailOnWorkItemFailure (#22261)
* For ReadyToRun tests in AzDO set RunCrossGen=true during Helix test running
* Set __TestTimeout and introduce TimeoutPerTestInMinutes for test jobs
* Set FailOnWorkItemFailure - fail the AzDO step on Helix work item "catastrophic failure"
|
|
|
|
captureless (#22263)
|
|
GCHeapHardLimit - specifies a hard limit for the GC heap
GCHeapHardLimitPercent - specifies a percentage of the physical memory this process is allowed to use
If both are specified, GCHeapHardLimit is checked first and only when it's not specified
would we check GCHeapHardLimitPercent.
If neither is specified but the process is running inside a container with a memory
limit specified, we will take this as the hard limit:
max (20mb, 75% of the memory limit on the container)
If one of the HardLimit configs is specified, and the process is running inside a container
with a memory limit, the GC heap usage will not exceed the HardLimit but the total memory
is still the memory limit on the container so when we calculate the memory load it's based
off the container memory limit.
An example,
process is running inside a container with 200mb limit
user also specified GCHeapHardLimit as 100mb.
if 50mb out of the 100mb is used for GC, and 100mb is used for other things, the memory load
is (50 + 100)/200 = 75%.
Some notes on these configs -
+ The limit is the commit size.
+ This is only supported on 64-bit.
+ For Server GC the minimum *reserved* segment size is 16mb per heap, this is to avoid the
scenario where the hard limit is small but the process can use many procs and we end up
with tiny segments which doesn't make sense. We then keep track of the committed on the segments
so the total does not exceed the hard limit.
|
|
* Add Marshal ansi conversion to shared partition
* Ignore bestFit/throwOnUnmappableChar on Unix
* Use same assert in StringToAnsiString
* wideCharLen parameter rename
|
|
* Fix various fgMorphInitBlock issues
* Remove unnecessary destAddr variable
* Extend/fix comment headers
|
|
(#22202)
On Arm and Arm64 unwind records can only cover a limited range of code
(512K and 1MB respectively). So for methods larger than this the jit
will emit multiple "fragment" unwind records to cover the full method code
range. Only the first of these describes the behavior of the method prolog.
When mapping an offset back to a method's entry point unwind, make sure to
find this "root" unwind record instead of one of the internal fragments.
Fixes #19209.
|
|
|
|
|
|
BinaryReader.ReadInt32() has nice optimization which was missing from the ReadUInt32() version. Now both implementations are aligned.
ReadUInt32 and all the 64 bits types are now 30% to 50% faster than original implementation.
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|
|
* Remove defunct netstandard code from ValueTask
* Remove several uses of VoidTaskResult
Currently TrySetResult/Canceled/Exception live on `Task<T>`. There's no reason `TrySetCanceled` and `TrySetException` need to live there, as they only access state from the base `Task`, and so can be moved down. `TrySetResult` needs the `TResult`, however in a variety of cases `Task<T>` is used with a `VoidTaskResult`, and for such cases we can just have a parameterless `TrySetResult()` on the base class as well, which can be used any time there is no `TResult` or when `default(TResult)` is the desired result. This lets us switch several cases where we were using `Task<VoidTaskResult>` to just be `Task`, which saves 8 bytes on the task instance on 64-bit. It also avoids an Interlocked.Exchange as part of the TrySetResult call.
This primarily affects Task.Delay and the non-generic variants of Task.WhenAll, ValueTask.AsTask(), Task.FromCanceled, and Task.FromException.
|
|
* Move Timer to shared CoreLib partition.
* Move SignalNoCallbacksRunning back to shared code, add static EventWaitHandle.Set.
* Remove AppDomain references from shared Timer code, reshuffle some code out of SetTimer in non-shared code.
* Change m_ prefix to match code style.
|
|
|
|
(#21979)
|
|
* Move Marshal::ZeroFree* to shared partition
* Add managed version of SysStringByteLen
|
|
|