Konstantin Baladurin [Tue, 3 Oct 2017 11:08:06 +0000 (14:08 +0300)]
[x86/Linux] Fix regdisplay initialization in case of WIN64EXCEPTIONS (dotnet/coreclr#14296)
Method Debugger::IsThreadAtSafePlaceWorker for x86 sets values only
for ControlPC and PCTAddr fields of REGDISPLAY but there is assert
in StackFrameIterator::Init that checks that field pCurrentContext
is not NULL if WIN64EXCEPTIONS is defined.
This patch uses FillRegDisplay function to correctly initialize
regdisplay in case of WIN64EXCEPTIONS.
Commit migrated from https://github.com/dotnet/coreclr/commit/
8eb9adbe7f069638c1457b458c2c5a569eaaabf8
Sergey Andreenko [Tue, 3 Oct 2017 02:09:01 +0000 (19:09 -0700)]
delete the old workaround. (dotnet/coreclr#14288)
gcc is not supported.
Commit migrated from https://github.com/dotnet/coreclr/commit/
71f15df5a6d2c003f3c132b07a103a159d3831b5
Bruce Forstall [Mon, 2 Oct 2017 23:29:45 +0000 (16:29 -0700)]
Merge pull request dotnet/coreclr#14220 from wateret/ryu-arm-bitcast-cleanup
[RyuJIT/arm32] Code cleanup
Commit migrated from https://github.com/dotnet/coreclr/commit/
70b3c9e5dd35d898562e980d1e5b3349cc75d13e
Hanjoung Lee [Mon, 2 Oct 2017 23:22:48 +0000 (08:22 +0900)]
Improve runtest.sh concurrency (dotnet/coreclr#14036)
* Imporove runtest.sh concurrency
`runtest.sh` runs next tests immediately after any of child processes is done
* Fix runtest.sh getting number of processors
For linux, check if `nproc` or `getconf` exists
when getting number of processors.
* Add tests that fail with OOM to unsupported list
Add several tests that consumes a lot of memory to unsupported test list(arm32).
This change is temporary until we properly handle these test with memory issue.
Commit migrated from https://github.com/dotnet/coreclr/commit/
5643bfeb4b507a1d70465ddcf245a5866d331b38
Carol Eidt [Mon, 2 Oct 2017 20:44:10 +0000 (13:44 -0700)]
Merge pull request dotnet/coreclr#14274 from fiigii/vexencoding
[RyuJIT] Fix VEX.vvvv for cvtss2sd and cvtsd2ss
Commit migrated from https://github.com/dotnet/coreclr/commit/
bd7493440cefe9cdfb3648de99178e208f8df5df
Sean Gillespie [Mon, 2 Oct 2017 20:27:31 +0000 (13:27 -0700)]
Fix a jump over variable initialization (dotnet/coreclr#14286)
Commit migrated from https://github.com/dotnet/coreclr/commit/
0c9e96e1c2c484e7c80bf7f7a7765e6650cbdf73
Viktor Hofer [Mon, 2 Oct 2017 19:54:19 +0000 (21:54 +0200)]
Merge pull request dotnet/coreclr#14181 from ViktorHofer/MutexCodeCleanup
Mutex code cleanup and removal of unused types
Commit migrated from https://github.com/dotnet/coreclr/commit/
97e0093e0941e7d5650d3f705bae17f1041c839f
Stephen Toub [Mon, 2 Oct 2017 19:17:58 +0000 (15:17 -0400)]
Workaround GetSystemTimePreciseAsFileTime inaccuracies (dotnet/coreclr#14283)
* Workaround GetSystemTimePreciseAsFileTime inaccuracies
On misconfigured systems, GetSystemTimePreciseAsFileTime may drift quickly from GetSystemTimeAsFileTime. We want to use the former, though. As a workaround/heuristic, when checking whether we have GetSystemTimePreciseAsFileTime, invoke both and ensure they're "close", falling back to GetSystemTimeAsFileTime if it seems like the precise variant has run away.
* Update comment
Commit migrated from https://github.com/dotnet/coreclr/commit/
0e8bc684c6e15591708d49a773183fb6cd9eda34
José Rivero [Mon, 2 Oct 2017 16:53:20 +0000 (09:53 -0700)]
Small bug fixes on "perf.groovy" (dotnet/coreclr#14259)
- `submission-metadata` option is `--user-email`, not `--user`
- We need to escape user input. On batch, " -> ""
Commit migrated from https://github.com/dotnet/coreclr/commit/
b5d08755c552961640df581ff532e87d187a4be3
tvass83 [Mon, 2 Oct 2017 13:27:48 +0000 (15:27 +0200)]
The !DumpArray sos command emits invalid DML for array elements (dotnet/coreclr#13855)
Element Methodtable is reported correctly but for individual elements, the generated DML uses the MT of the array, not the element, thus giving incorrect results
Only value types are affected
0:007> !DumpArray /d
02b16574
Name: WindowsFormsApplication2_SOS_bug.Test[]
MethodTable:
011c82ec
EEClass:
011c8290
Size: 412(0x19c) bytes
Array: Rank 1, Number of elements 100, Type VALUETYPE
Element Methodtable:
011c824c
[0]
02b1657c => here is the problem
Commit migrated from https://github.com/dotnet/coreclr/commit/
fb2064e5d8b621dad56db25ad7b1af9909b4b4a2
Ahson Ahmed Khan [Sat, 30 Sep 2017 01:56:42 +0000 (18:56 -0700)]
Adding a patch to fix coreclr build for VS 15.5 (using older SDKs). (dotnet/coreclr#14272)
Commit migrated from https://github.com/dotnet/coreclr/commit/
c90a41bb6b9b5c5cc7f8f29a9d06aa2f9d0e51fd
Fei Peng [Sat, 30 Sep 2017 00:35:34 +0000 (17:35 -0700)]
Fix VEX.vvvv for cvtss2sd and cvtsd2ss
Commit migrated from https://github.com/dotnet/coreclr/commit/
806de466073c81d0ae67829cc146a2b0ba1b7fab
Sergey [Fri, 29 Sep 2017 23:16:44 +0000 (02:16 +0300)]
StompWriteBarrier initialization path refactoring (dotnet/coreclr#14105)
* refactored arm, arm64, amd64 and x86 to signal about icache flush and ee restarts
* refactored gc init stage to stomp write barrier (hence flush icache) only once
* review fixes, care taken of icache invalidation during StompResize
* fixed heap boundaries initialization bug introduced after refactoring gc.cpp
* stylistic review fixe
* global variable rename
* global variable rename once more
Commit migrated from https://github.com/dotnet/coreclr/commit/
5b10f0eb85d8e8ccdcf9b5e38e5dd372e241e24e
Mike McLaughlin [Fri, 29 Sep 2017 22:54:48 +0000 (15:54 -0700)]
Update build clang/llvm/lldb 3.9 (dotnet/coreclr#14096)
Update build scripts, docs and build pipeline docker images to clang/llvm/lldb 3.9
Commit migrated from https://github.com/dotnet/coreclr/commit/
32c46737c396afa05ab748fbcc243de7512c11ec
Borislav Ivanov [Fri, 29 Sep 2017 22:52:46 +0000 (01:52 +0300)]
Fix spelling errors (dotnet/coreclr#14218)
Fix some spelling errors and capitalization.
Commit migrated from https://github.com/dotnet/coreclr/commit/
1ed2739e1a9c6f621f800ba0ffd3a28797149a1b
Mike McLaughlin [Fri, 29 Sep 2017 22:50:10 +0000 (15:50 -0700)]
Add info on loading core dumps in lldb. (dotnet/coreclr#13955)
Commit migrated from https://github.com/dotnet/coreclr/commit/
5dd0b008a62233d6d296268e931295a4f971ce44
Fei Peng [Sun, 24 Sep 2017 17:54:56 +0000 (10:54 -0700)]
Enable hardware intrinsic in debug and reflection
Commit migrated from https://github.com/dotnet/coreclr/commit/
03c5c252281325e5a7b94cec6a198946f903b359
Fei Peng [Fri, 15 Sep 2017 20:01:13 +0000 (13:01 -0700)]
Implement IsSuppoored for all ISA classes
Commit migrated from https://github.com/dotnet/coreclr/commit/
4252e77681840228d95318e920d649bb5b27ea82
Matt Galbraith [Fri, 29 Sep 2017 20:54:11 +0000 (13:54 -0700)]
Merge pull request dotnet/coreclr#14265 from MattGal/build_def_updates
Build definition publishing behavior tweaks
Commit migrated from https://github.com/dotnet/coreclr/commit/
77eb81c4c5a72017b9fd95811e3e92adcb5a9d75
Matt Galbraith [Fri, 29 Sep 2017 20:04:55 +0000 (13:04 -0700)]
Build definition publishing behavior tweaks
Commit migrated from https://github.com/dotnet/coreclr/commit/
2b9cf9e4cddf46e5ea37f93c8b8c43d3410c9878
Hyung-Kyu Choi [Fri, 29 Sep 2017 19:01:16 +0000 (04:01 +0900)]
[RyuJIT/ARM32] hotfix for a regression (dotnet/coreclr#14252)
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
Commit migrated from https://github.com/dotnet/coreclr/commit/
4082dee53d266770a769b50b396f36a06dbcc52f
Konstantin Baladurin [Fri, 29 Sep 2017 17:15:35 +0000 (20:15 +0300)]
[x86/Linux] Fix CopyREGDISPLAY for WIN64EXCEPTIONS (dotnet/coreclr#14254)
When WIN64EXCEPTIONS is defined, fields pCurrentContextPointers,
pCallerContextPointers, pCurrentContext and pCallerContext of the
REGDISPLAY are used. So we need to fix their values after coping.
Commit migrated from https://github.com/dotnet/coreclr/commit/
2eed20ce511fa25085742d4aaffc29a3939e84dd
Konstantin Baladurin [Fri, 29 Sep 2017 14:03:17 +0000 (17:03 +0300)]
[x86/Linux][SOS] Fix DumpStack command output on x86 (dotnet/coreclr#14189)
On x86 DumpStack command doesn't print symbol information for
caller and callee. This patch fixes it and make output the same
as on AMD64.
Commit migrated from https://github.com/dotnet/coreclr/commit/
c8a49ac3abce30092f51e397136098f9cdd9ba5f
Steve MacLean [Fri, 29 Sep 2017 12:10:32 +0000 (08:10 -0400)]
Allow cross machine re-crossgen (dotnet/coreclr#14241)
Commit migrated from https://github.com/dotnet/coreclr/commit/
581a8d93840212355fc467b3620b74b267df806e
Konstantin Baladurin [Fri, 29 Sep 2017 08:08:01 +0000 (11:08 +0300)]
[x86/Linux] Fix assert in HelperMethodFrame::UpdateRegDisplay (dotnet/coreclr#14235)
In some cases during execution of the SOS command 'clrstack -i'
portability assert in HelperMethodFrame::UpdateRegDisplay occurs.
This patch removes this assert and adds corresponding implementation.
Commit migrated from https://github.com/dotnet/coreclr/commit/
9b49593f5ca1b3168a4ff947cbfc3d52a97671cb
Ahson Ahmed Khan [Fri, 29 Sep 2017 03:05:35 +0000 (20:05 -0700)]
Fixing Retain to return MemoryHandle with correct PinnedPointer (dotnet/coreclr#14248)
* Fixing Retain to return MemoryHandle with correct PinnedPointer.
* Make MemoryHandle AddOffset internal.
Commit migrated from https://github.com/dotnet/coreclr/commit/
eab3a973346bf4bc5ddffc5201f862141a96b000
Roman Artemev [Fri, 29 Sep 2017 02:30:36 +0000 (19:30 -0700)]
Merge pull request dotnet/coreclr#14247 from rartemev/issue_13420
Fixed difference between produced code in CHK and REL modes
Commit migrated from https://github.com/dotnet/coreclr/commit/
591983b2b475f9d2a08e29b5640d6a70b124d816
Kristian Hellang [Fri, 29 Sep 2017 01:12:24 +0000 (03:12 +0200)]
Added CopyToAsync overload using default buffer size (dotnet/coreclr#14219)
* Added CopyToAsync overload using default buffer size
* Address feedback
* Added comment about overrides and argument validation
* Renamed helper method to GetCopyBufferSize
To convey that this method should only be used for
getting a buffer size to be passed to CopyTo{Async}.
Commit migrated from https://github.com/dotnet/coreclr/commit/
b78107d55e4e53805630099f3aa875e6a1273959
Roman Artemev [Fri, 29 Sep 2017 00:22:08 +0000 (17:22 -0700)]
Fixed differenece between produced code in CHK and REL modes
Commit migrated from https://github.com/dotnet/coreclr/commit/
2cb0faedbe72e05c8e9620c74b54a22eecf4ac2a
Sergey Andreenko [Thu, 28 Sep 2017 23:16:06 +0000 (16:16 -0700)]
ignore GT_ARGPLACE before gtUseNum check. (dotnet/coreclr#14233)
Commit migrated from https://github.com/dotnet/coreclr/commit/
322b440079db0e61fdd9aba3d95891a1d3d00d0d
Sergey Andreenko [Thu, 28 Sep 2017 17:37:15 +0000 (10:37 -0700)]
Add the capability to force JIT options on the SPMI command line. (dotnet/coreclr#14209)
expand the grammar for jit{,2}option to -jitoption [force] key=value
Commit migrated from https://github.com/dotnet/coreclr/commit/
212a6baa708f40e25860581557b3dda717b709d9
Konstantin Baladurin [Thu, 28 Sep 2017 16:26:39 +0000 (19:26 +0300)]
[x86/Linux] Fix typo in SetDebuggerREGDISPLAYFromREGDISPLAY (dotnet/coreclr#14221)
Fix typo in SetDebuggerREGDISPLAYFromREGDISPLAY: Esi -> Eax.
Commit migrated from https://github.com/dotnet/coreclr/commit/
0a17ae10d45db4731071e9a450178933b6d9d1f5
Carol Eidt [Thu, 28 Sep 2017 16:00:16 +0000 (09:00 -0700)]
Merge pull request dotnet/coreclr#14225 from fiigii/falsedependency
[RyuJIT] Fix bad VEX encoding to avoid false register dependency
Commit migrated from https://github.com/dotnet/coreclr/commit/
f8b5f537bcb234d1df53445e13f187cadb186c37
Andy Ayers [Thu, 28 Sep 2017 14:56:24 +0000 (07:56 -0700)]
JIT: have gtClone handle long constants (dotnet/coreclr#14201)
The `Enum.HasFlag` opt needs to clone the enum values, and they
can be long constants. Make sure `gtClone` handles this case.
Closes dotnet/coreclr#14149.
Commit migrated from https://github.com/dotnet/coreclr/commit/
ec160a4bed52ac7c6aff3a87c0846c1da228936a
Bruce Forstall [Thu, 28 Sep 2017 05:16:27 +0000 (22:16 -0700)]
Merge pull request dotnet/coreclr#14232 from BruceForstall/Fix14196
Fix issue with HFA altjit api
Commit migrated from https://github.com/dotnet/coreclr/commit/
2dcf8488e71c79c879bb0212bc2211e35e211321
Fei Peng [Wed, 27 Sep 2017 17:33:18 +0000 (10:33 -0700)]
fix bad VEX.vvvv to avoid false register dependency
Commit migrated from https://github.com/dotnet/coreclr/commit/
57c40213c0bdce1babcaefb1e66ef4f2b106e58d
Brian Sullivan [Thu, 28 Sep 2017 00:28:42 +0000 (17:28 -0700)]
Merge pull request dotnet/coreclr#14192 from sdmaclea/PR-ARM64-JCMP
[Arm64] Add GT_JCMP node
Commit migrated from https://github.com/dotnet/coreclr/commit/
00bce3384795a4f6fc56f5fa9a0bbdac3c1e892f
Hanjoung Lee [Wed, 27 Sep 2017 11:04:03 +0000 (20:04 +0900)]
[RyuJIT/arm32] Code cleanup
- Add an assertion for double type arg regs for armel
- Merge two if statements that have same body
Commit migrated from https://github.com/dotnet/coreclr/commit/
f8c8f0041c680c1dbdf82321a6f987e57e93b85f
Viktor Hofer [Wed, 27 Sep 2017 23:10:40 +0000 (01:10 +0200)]
Merge pull request dotnet/coreclr#14231 from fiigii/fixintrinsic
fix bugs from dotnet/coreclr#14164
Commit migrated from https://github.com/dotnet/coreclr/commit/
d113b5fd56d49ff7ed3cb9b34cc122676026d240
William Godbe [Wed, 27 Sep 2017 23:07:07 +0000 (16:07 -0700)]
Merge pull request dotnet/coreclr#14234 from dotnet/ConditionLoc
Move Condition location in dotnet-trusted-publish
Commit migrated from https://github.com/dotnet/coreclr/commit/
d450f23430dad8af47264f02bf8987be38fc2377
William Godbe [Wed, 27 Sep 2017 23:03:35 +0000 (16:03 -0700)]
Move Condition location in dotnet-trusted-publish
Commit migrated from https://github.com/dotnet/coreclr/commit/
377dfa1ca07959f460705c7831edf24e46ba3b33
Viktor Hofer [Wed, 27 Sep 2017 22:52:49 +0000 (00:52 +0200)]
nit pr feedback
Commit migrated from https://github.com/dotnet/coreclr/commit/
6626baf81d9eb4fe27225c1593a457f8ec1745b4
Bruce Forstall [Wed, 27 Sep 2017 21:42:04 +0000 (14:42 -0700)]
Fix issue with HFA altjit api
One case in the Interop\ArrayMarshalling\ByValArray\MarshalArrayByValTest\MarshalArrayByValTest.cmd
test marshals an array of strings as members of a struct. The !FEATURE_HFA
code for IsHFA() needs to check for value type before calling CheckForHFA(),
which will assert if it is not a value type.
Fixes dotnet/coreclr#14196.
Commit migrated from https://github.com/dotnet/coreclr/commit/
83124c7aaf7f4236e24f4c4fde3863f1736f7d47
Steve MacLean [Wed, 27 Sep 2017 21:16:51 +0000 (17:16 -0400)]
[Arm64] Respond to feedback
Commit migrated from https://github.com/dotnet/coreclr/commit/
932b8b5cdd0fda242dfd183599a7e022bc2b66e3
Fei Peng [Wed, 27 Sep 2017 21:28:07 +0000 (14:28 -0700)]
fix bug from dotnet/coreclr#14164
Commit migrated from https://github.com/dotnet/coreclr/commit/
8592fa1f3386cc9646154d16dadd0f8133debdf5
Ahson Ahmed Khan [Wed, 27 Sep 2017 21:21:28 +0000 (14:21 -0700)]
Adding {RO}Memory<T> debugger view (dotnet/coreclr#14130)
* Adding memory debugger view and fixing ToArray impl.
* Addressing PR feedback and adding span debugger display string.
* Adding link to specific VSTS instance.
* Removing redundant info in comments.
Commit migrated from https://github.com/dotnet/coreclr/commit/
9e8fd361f3df5911d46778ba79697e2ec66845aa
William Godbe [Wed, 27 Sep 2017 21:14:40 +0000 (14:14 -0700)]
Merge pull request dotnet/coreclr#14230 from dotnet/CondInjection
Condition Injection on SignType
Commit migrated from https://github.com/dotnet/coreclr/commit/
4f455e83b431c093a0281a8de69333f2eba1f463
William Godbe [Wed, 27 Sep 2017 21:13:27 +0000 (14:13 -0700)]
Condition Injection on SignType
Commit migrated from https://github.com/dotnet/coreclr/commit/
dbec18efc6f99144499c6dd6f6d5e7511bc2f37d
William Godbe [Wed, 27 Sep 2017 20:44:39 +0000 (13:44 -0700)]
Merge pull request dotnet/coreclr#14229 from dotnet/PB_Fix
Change PB_ConfigurationGroup to ConfigurationGroup
Commit migrated from https://github.com/dotnet/coreclr/commit/
0dc72a58d49ef7b05093c141972de60f7d658412
William Godbe [Wed, 27 Sep 2017 20:44:07 +0000 (13:44 -0700)]
Update DotNet-Trusted-Publish.json
Commit migrated from https://github.com/dotnet/coreclr/commit/
d013e3ba9e02ca192e8781614b80be224cefd37d
Jan Kotas [Tue, 26 Sep 2017 00:17:20 +0000 (17:17 -0700)]
Fix modf and fmod casing for consistency
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
Commit migrated from https://github.com/dotnet/coreclr/commit/
4ade034c829a38a656cbe52a96fbfc98275bbc46
Sergey Andreenko [Wed, 27 Sep 2017 19:00:33 +0000 (12:00 -0700)]
[Jit] fix DevDiv_499435 (dotnet/coreclr#14179)
fix DevDiv_499435
Commit migrated from https://github.com/dotnet/coreclr/commit/
bb2f5e780f7e0c12afb65261790fe84b2f02462e
William Godbe [Wed, 27 Sep 2017 18:26:16 +0000 (11:26 -0700)]
Merge pull request dotnet/coreclr#14226 from dotnet/SymbolPkgInject
Conditionally Inject signed symbol packages on SignType
Commit migrated from https://github.com/dotnet/coreclr/commit/
f363e64c5f72f30b47d205c342f256f7cc615a01
William Godbe [Wed, 27 Sep 2017 18:12:04 +0000 (11:12 -0700)]
Conditionally Inject signed symbol packages on SignType
Commit migrated from https://github.com/dotnet/coreclr/commit/
074e63ef162618153140a754845ea435bc82a017
Steve MacLean [Wed, 27 Sep 2017 17:38:05 +0000 (13:38 -0400)]
[ARM64/Unix] Enable FEATURE_EVENT_TRACE (dotnet/coreclr#14176)
* [ARM64/Unix] Enable FEATURE_EVENT_TRACE
* [Arm64] Remove _PlatformDoesNotSupportEventTrace
Commit migrated from https://github.com/dotnet/coreclr/commit/
fa30eeba02ad0a5ffeb1122467c5cb47bac285a8
Sean Gillespie [Wed, 27 Sep 2017 17:17:38 +0000 (10:17 -0700)]
Additional parameter validation for StartNoGCRegion (dotnet/coreclr#14088)
* Additional parameter validation for StartNoGCRegion
* Fix the clang build by moving some defs before the first goto
* Guard against size_t overflow when scaling allocation budgets
* Move some parameter validation for managed code, throw better exceptions on parameter validation errors
* Remove stray comma
* Address code review feedback - unify code branches that branch to the failure case. Also keep data types as uint64_t as long as possible to avoid size_t overflow
* Fix the clang build
* Code review feedback:
1. Remove useless asserts
2. Remove a dead code path
3. Add a LocalGC TODO to comment
Commit migrated from https://github.com/dotnet/coreclr/commit/
00e7aa00a42debda47a7dbe2b54e924670eaefdd
Jarret Shook [Wed, 27 Sep 2017 17:13:48 +0000 (10:13 -0700)]
Merge pull request dotnet/coreclr#13897 from hseok-oh/ryujit/ftc_arg_count
Argument register & stack size calculation for fast tail call
Commit migrated from https://github.com/dotnet/coreclr/commit/
02c0ef24fc332f5f09e0e717462413603027c97c
Steve MacLean [Wed, 27 Sep 2017 16:41:52 +0000 (12:41 -0400)]
[Arm64] Add JCMP comments per review
Commit migrated from https://github.com/dotnet/coreclr/commit/
415e7a7c6a01d5f2c5c722ace07c16e3c4aafa95
Steve MacLean [Tue, 26 Sep 2017 23:31:18 +0000 (19:31 -0400)]
[Arm64] Fix JCMP lsra binding
Commit migrated from https://github.com/dotnet/coreclr/commit/
021ecc08732cfd8d95ff5c1abd477f8bcf2a30f6
Carol Eidt [Wed, 27 Sep 2017 15:49:42 +0000 (08:49 -0700)]
Merge pull request dotnet/coreclr#14207 from CarolEidt/Fix14028
Handle GT_SIMD in GenTree::Compare
Commit migrated from https://github.com/dotnet/coreclr/commit/
dbdaf348f8a8ace5bd02a9074bef98c2ded95f3d
Bruce Forstall [Wed, 27 Sep 2017 15:46:19 +0000 (08:46 -0700)]
Merge pull request dotnet/coreclr#14090 from BredPet/interface_dispatch_cell
ARM32: fix interface dispatch cell address transfer
Commit migrated from https://github.com/dotnet/coreclr/commit/
0d3c6848351a7a59a9bb586cdf3e064b09f87383
Andy Ayers [Wed, 27 Sep 2017 14:15:04 +0000 (07:15 -0700)]
JIT: devirtualization support for EqualityComparer<T>.Default (dotnet/coreclr#14125)
Mark `EqualityComparer<T>.Default`'s getter as `[Intrinsic]` so
the jit knows there is something special about it. Extend the jit's
named intrinsic recognizer to recognize this method.
Add a new jit interface method to determine the exact type returned
by `EqualityComparer<T>.Default`, given `T`. Compute the return type by
mirroring the logic used in the actual implementation. Bail out when
`T` is not final as those cases won't simplify down much and lead to
code bloat.
Invoke this interface method when trying to devirtualize calls where
the 'this' object in the call comes from `EqualityComparer<T>.Default`.
The devirtualized methods can then be inlined. Since the specific comparer
`Equal` and `GetHashCode` methods look more complicated in IL than they
really are, mark them with AggressiveInlining attributes.
If devirtualization and inlining happen, it is quite likely that the value
of the comparer object itself is not used in the body of the comparer. This
value comes from a static field cache on the comparer helper.
When the comparer value is ignored, the jit removes the field access since it
is non-faulting. It also removes the the class init helper that is there to
ensure that the (no-longer accessed) field is properly initialized. This helper
has relatively high overhead even in the fast case where the class has been
initialized aready.
Add a perf test.
Closes dotnet/coreclr#6688.
Commit migrated from https://github.com/dotnet/coreclr/commit/
ccc5e17738a4b2f652059f31e8146513163dbee7
Igor Kulaychuk [Wed, 27 Sep 2017 13:32:39 +0000 (16:32 +0300)]
[GDBJIT] Provide full file names in generated DWARF (dotnet/coreclr#14172)
* Fix compile unit info
Provide full path to source in SequencePoints for GDBJIT
Use source file and directory path for compile unit info in DWARF instead of module name.
* Add a class for building Directory Table and File Table
* Fix code inconsistencies and add comments
Commit migrated from https://github.com/dotnet/coreclr/commit/
9509fc86a50ad107ee4d601e917cf072f135aa5e
Stephen Toub [Wed, 27 Sep 2017 12:32:54 +0000 (08:32 -0400)]
Merge pull request dotnet/coreclr#14214 from stephentoub/quwi_preferlocal
Add ThreadPool.QueueUserWorkItem(..., bool preferLocal)
Commit migrated from https://github.com/dotnet/coreclr/commit/
863625426be65b96f2a3c085fc049cfcd2f1a82a
Petr Bred [Wed, 20 Sep 2017 17:52:05 +0000 (20:52 +0300)]
ARM32: fix interface dispatch cell address transfer
Signed-off-by: Petr Bred <bredpetr@gmail.com>
Commit migrated from https://github.com/dotnet/coreclr/commit/
74478f481290e3e5fb8ee3c2669b66a71ae0056c
Jonghyun Park [Wed, 27 Sep 2017 08:55:30 +0000 (17:55 +0900)]
Use FCDECL2_VI instead of FCDECL_VV (dotnet/coreclr#14215)
Commit migrated from https://github.com/dotnet/coreclr/commit/
e8f69d0a160d6f6f69ad40350ea30346bc030b80
Jonghyun Park [Wed, 27 Sep 2017 08:54:51 +0000 (17:54 +0900)]
Permit to disable FEATURE_EVENT_TRACE on Tizen (dotnet/coreclr#14217)
Commit migrated from https://github.com/dotnet/coreclr/commit/
06763844394cc40933162f31fa911ab518ed5518
Hyeongseok Oh [Wed, 20 Sep 2017 06:22:09 +0000 (15:22 +0900)]
Remove useless variable
Remove compArgRegCount and compFlatArgRegCount in Info struct
Commit migrated from https://github.com/dotnet/coreclr/commit/
20b54accdfb51c52830ec63e7ad7a4f5c26a99e2
Hyeongseok Oh [Tue, 12 Sep 2017 00:47:37 +0000 (09:47 +0900)]
Fix typo
Fix typo in lclvars.cpp and register_arg_convention.h
Commit migrated from https://github.com/dotnet/coreclr/commit/
44eebc7fb37ade75cc8de6c78cba95c2f7c0388d
Hyeongseok Oh [Mon, 11 Sep 2017 11:21:05 +0000 (20:21 +0900)]
Enhancement caller register & stack calculation for fast tail call
Save caller register count & stack size using argument varDsc initialization
It remove duplicate calculation for register count
and add stack size count in varDsc initialization
Commit migrated from https://github.com/dotnet/coreclr/commit/
a303fc2f10aead0e2377849bde8a293159effbc9
Hyeongseok Oh [Wed, 27 Sep 2017 04:20:06 +0000 (13:20 +0900)]
[RyuJIT/ARM32] Fast tail call: Init LSRA to use R12 to save jump target (dotnet/coreclr#14184)
* [RyuJIT/ARM32] Fast tail call: use R12 to save jump target
To save jump target of fast tail call on ARM32, we use r12.
* Use pre-defined mask and fix comment
Use pre-defined mask: RBM_R12
fix comment: mov pc -> br
Commit migrated from https://github.com/dotnet/coreclr/commit/
d7e798c7901c55fe8511632d98a2710affdd70ff
Stephen Toub [Wed, 27 Sep 2017 03:10:46 +0000 (23:10 -0400)]
Add ThreadPool.QueueUserWorkItem(..., bool preferLocal)
Commit migrated from https://github.com/dotnet/coreclr/commit/
f28f313685345275e47f25eef9c155feeb59faad
Stephen Toub [Wed, 27 Sep 2017 02:39:38 +0000 (22:39 -0400)]
Merge pull request dotnet/coreclr#14178 from stephentoub/async_avoid_delegate
Avoid async method delegate allocation
Commit migrated from https://github.com/dotnet/coreclr/commit/
ef08c8221aa4d33f6ad1399d13bdaab9b10b84a0
Roman Artemev [Wed, 27 Sep 2017 02:25:13 +0000 (19:25 -0700)]
Merge pull request dotnet/coreclr#14197 from rartemev/fixed_test_build_restore
Fixed Linux test build
Commit migrated from https://github.com/dotnet/coreclr/commit/
536cf25edfada76589a84e1620f93c39c15db167
Carol Eidt [Wed, 27 Sep 2017 00:19:35 +0000 (17:19 -0700)]
Handle GT_SIMD in GenTree::Compare
Fix dotnet/coreclr#14028
Commit migrated from https://github.com/dotnet/coreclr/commit/
c68ddbfe82a553b53f1a5821843194f62bd2d81d
Xiangyang (Mark) Guo [Wed, 27 Sep 2017 00:11:55 +0000 (17:11 -0700)]
Add SetThreadIdealProcessorEx PAL API (dotnet/coreclr#13606)
* add SetThreadIdealProcessorEx PAL API
* fix lpPreviousIdealProcessor
Commit migrated from https://github.com/dotnet/coreclr/commit/
73ef3c13c9b710cb04b67a904b098fb196c224c7
Brian Robbins [Tue, 26 Sep 2017 23:47:12 +0000 (16:47 -0700)]
Update linux-performance-tracing.md (dotnet/coreclr#14194)
Add documentation on how to resolve framework symbols on Linux performance traces.
Commit migrated from https://github.com/dotnet/coreclr/commit/
44f570e6efc8e908cebaef8d98b36f1b0c6f5c4a
Viktor Hofer [Tue, 26 Sep 2017 00:02:01 +0000 (02:02 +0200)]
Mutex code cleanup and removal of unused types
Commit migrated from https://github.com/dotnet/coreclr/commit/
eff880d5ff8c3c44246e5cc7c33f083108e0a397
Dmitri-Botcharnikov [Tue, 26 Sep 2017 22:57:20 +0000 (01:57 +0300)]
Enable event tracing for Tizen. (dotnet/coreclr#14137)
Commit migrated from https://github.com/dotnet/coreclr/commit/
485bbd5cd77d3824218149093e071e7dd8434627
Sergey Andreenko [Tue, 26 Sep 2017 22:35:01 +0000 (15:35 -0700)]
Fix for a special CoreRT helper CORINFO_HELP_JIT_PINVOKE_BEGIN (dotnet/coreclr#14147)
Commit migrated from https://github.com/dotnet/coreclr/commit/
cc4769bdcc9f7ed60df8893a99a02f1406fb056f
William Godbe [Tue, 26 Sep 2017 22:25:20 +0000 (15:25 -0700)]
Merge pull request dotnet/coreclr#14202 from wtgodbe/SigningDisableInstall
Install signing plugin with Real signing
Commit migrated from https://github.com/dotnet/coreclr/commit/
9b3e8b16e3d1a1c46b4f550a861c9692de4b4a4a
wtgodbe [Tue, 26 Sep 2017 22:25:02 +0000 (15:25 -0700)]
Install signing plugin with Real signing
Commit migrated from https://github.com/dotnet/coreclr/commit/
716de0e29a573afbe8001af0b512e90088eafd40
Steve MacLean [Tue, 26 Sep 2017 21:04:24 +0000 (17:04 -0400)]
[Arm64] Fix GT_JCMP lsra
Commit migrated from https://github.com/dotnet/coreclr/commit/
21dab2e6c9a3be7d528de219b8ba272d55850566
Dan Moseley [Tue, 26 Sep 2017 21:19:16 +0000 (14:19 -0700)]
Replace Contract.Assumes and Contract.Assert with Debug.Assert/Debug.Fail (dotnet/coreclr#14136)
* Remove use of Contract.Assert and Contract.Assumes in favor of Debug.xx
* Remove dead IA64 blocks
* Remove use of Contract.Requires in favor of Debug.Assert
* Remove Contract.EndContractBlock()
* Dead comments
* Straggler EndcontractBlock
* Remove all Contract.Ensures
* Remove [Pure] attribute and using statements
* Remove using statements for M.D.Contracts.Internal.Contract
* Rmove CA suppressions for Contracts
* Remove M.D.Contracts.Internal stub
* Comments and extra using
* Revert accidentallly removed #if
* Unix build
* Merge Math*
* Fix assert not updated since desktop
* Asserts add no value: remove
* Avoid infinite recursion in StringBuilder assert
* Remove asserts that should be public parameter validation
* Fix comment
* Remove blank line after open curly
Commit migrated from https://github.com/dotnet/coreclr/commit/
da8b7181dbe362fbfe64c7ef72ff3a4a7db68f24
Roman Art [Sat, 23 Sep 2017 00:09:42 +0000 (17:09 -0700)]
Fixed Linux test build
Commit migrated from https://github.com/dotnet/coreclr/commit/
93b646c2833daf3b518ac5fb110494b30114fc60
William Godbe [Tue, 26 Sep 2017 21:06:06 +0000 (14:06 -0700)]
Merge pull request dotnet/coreclr#14195 from wtgodbe/SignType
Use Real signType to install plugin
Commit migrated from https://github.com/dotnet/coreclr/commit/
94cbb624a62f7a5712292a3e4da650ba335be4da
wtgodbe [Tue, 26 Sep 2017 21:04:57 +0000 (14:04 -0700)]
Use Real signType to install plugin
Commit migrated from https://github.com/dotnet/coreclr/commit/
2dfcf509b71ef6fefeb4dc9f289b7224aeb2d377
William Godbe [Tue, 26 Sep 2017 20:34:37 +0000 (13:34 -0700)]
Merge pull request dotnet/coreclr#14193 from wtgodbe/SigningInfra
Update publish infra to parameterize PB_SignType
Commit migrated from https://github.com/dotnet/coreclr/commit/
6fa6b7e135fb16fa1943e506d3c9400e2c1da5a7
wtgodbe [Tue, 26 Sep 2017 20:16:49 +0000 (13:16 -0700)]
Update publish infra to parameterize PB_SignType
Commit migrated from https://github.com/dotnet/coreclr/commit/
c84c7768410bc5eaab4d3a8f7009b339d0f4975d
Koundinya Veluri [Tue, 26 Sep 2017 20:14:53 +0000 (13:14 -0700)]
Remove Monitor asm helpers (dotnet/coreclr#14146)
- Removed asm helpers on Windows and used portable C++ helpers instead
- Rearranged fast path code to improve them a bit and match the asm more closely
Perf:
- The asm helpers are a bit faster. The code generated for the portable helpers is almost the same now, the remaining differences are:
- There were some layout issues where hot paths were in the wrong place and return paths were not cloned. Instrumenting some of the tests below with PGO on x64 resolved all of the layout issues. I couldn't get PGO instrumentation to work on x86 but I imagine it would be the same there.
- Register usage
- x64: All of the Enter functions are using one or two (TryEnter is using two) callee-saved registers for no apparent reason, forcing them to be saved and restored. r10 and r11 seem to be available but they're not being used.
- x86: Similarly to x64, the compiled functions are pushing and popping 2-3 additional registers in the hottest fast paths.
- I believe this is the main remaining gap and PGO is not helping with this
- On Linux, perf is >= before for the most part
- Perf tests used for below are updated in PR https://github.com/dotnet/coreclr/pull/13670
Commit migrated from https://github.com/dotnet/coreclr/commit/
8f0ac5d2041d0c577607e2f778f2fbca1f7d732e
Steve MacLean [Fri, 22 Sep 2017 16:07:43 +0000 (12:07 -0400)]
[Arm64] Add GT_JCMP node
Create new node type GT_JCMP to represent a
fused Relop + JTrue which does not set flags
Add lowering code to create GT_JCMP when
Arm64 could use cbz, cbnz, tbz, or tbnz
Commit migrated from https://github.com/dotnet/coreclr/commit/
d4bec111d70761857fcebd122cb36eb8bc383ef6
Carol Eidt [Tue, 26 Sep 2017 14:55:29 +0000 (07:55 -0700)]
Merge pull request dotnet/coreclr#14171 from wateret/ryu-arm-putarg-bitcast
[RyuJIT/armarch] Put arguments with GT_BITCAST
Commit migrated from https://github.com/dotnet/coreclr/commit/
296aaf12b40ddd7478b6a14d6099f48b4b049438
Hanjoung Lee [Mon, 25 Sep 2017 11:50:27 +0000 (20:50 +0900)]
[RyuJIT/armarch] Put arguments with GT_BITCAST
Put arguments with GT_BITCAST instead of GT_COPY for arm32/arm64
Fix dotnet/coreclr#14008
Commit migrated from https://github.com/dotnet/coreclr/commit/
0603f5b9ab96b20f72d006ab78a9b0c608c034df
Stephen Toub [Mon, 25 Sep 2017 16:02:10 +0000 (12:02 -0400)]
Avoid async method delegate allocation
Previously when a task-returning async method would yield for the first time, there would be four allocations: the task, the state machine object boxed to the heap, a context "runner" object, and a delegate that points to the boxed state machine's MoveNext method. A recent PR changed this to avoid the separate box object and the runner, but that still left the task and the delegate.
This PR avoids the delegate as well in a common case. For async methods that only ever await Task/Task`1, that aren't using a custom sync context/scheduler, and for which tracing isn't enabled, we know the inner workings of both the builder and the awaiter and can thus bypass the awaiter's pattern APIs; instead of creating the delegate that gets passed to the awaiter and then stored in the wrapped task's continuation slot/list, we can instead just store the boxed state machine directly in the slot/list.
Commit migrated from https://github.com/dotnet/coreclr/commit/
9a0630152c4339324ba9ac0fa886f9fb4916e759
Hyung-Kyu Choi [Tue, 26 Sep 2017 00:37:04 +0000 (09:37 +0900)]
[ARM32] Update armel rootfs for Tizen (dotnet/coreclr#14173)
* [Tizen/ARM32] Update armel rootfs for Tizen
- Add lttng-ust-dev to Tizen rootfs for cross build
- Use rootfs of the latest Tizen 4.0
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
* [Tizen/ARM32] Update Tizen CI script
- Update arm32 CI script for Tizen to use the latest environment
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
Commit migrated from https://github.com/dotnet/coreclr/commit/
10c320c512e5246b658c76c1c699233e1ec8a35d
Bruce Forstall [Tue, 26 Sep 2017 00:22:03 +0000 (17:22 -0700)]
Add CI PR triggers for x86_arm and x64_arm64 testing (dotnet/coreclr#14158)
* Add CI PR triggers for x86_arm and x64_arm64 testing
* Fix bug
* Don't do GC stress with altjit
Commit migrated from https://github.com/dotnet/coreclr/commit/
466cc6ecdaef5273b78b4022b459433ddd9d4e64
Brian Sullivan [Mon, 25 Sep 2017 23:54:25 +0000 (16:54 -0700)]
Merge pull request dotnet/coreclr#14041 from sdmaclea/PR-ARM64-SET-FLAGS
[Arm64] Use GTF_SET_FLAGS/GTF_USE_FLAGS
Commit migrated from https://github.com/dotnet/coreclr/commit/
40f63d9d3421d41df225e6f5d41645a4394a8ae1
Steve MacLean [Mon, 25 Sep 2017 19:07:22 +0000 (15:07 -0400)]
[Arm64] Repsond to feedback
Commit migrated from https://github.com/dotnet/coreclr/commit/
d11ca21103627ef5eed573cb8ce5b208d385adbb
Steve MacLean [Tue, 19 Sep 2017 22:27:11 +0000 (18:27 -0400)]
Cleanup gentree per comments
Commit migrated from https://github.com/dotnet/coreclr/commit/
e74fe85a47260881a5ebc0c2e3d5af7a6409a299
Steve MacLean [Fri, 15 Sep 2017 22:08:09 +0000 (18:08 -0400)]
[Arm64] Use GTF_SET_FLAGS/GTF_USE_FLAGS
Commit migrated from https://github.com/dotnet/coreclr/commit/
95f69bf863b500c645a072bc7a46f52bbdb3c491