Age | Commit message (Collapse) | Author |
|
Related to https://github.com/dotnet/coreclr/pull/16643
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
* Fix up some alignments
* Optional fields is a bunch of bytes without relocs. We don't need a pointer alignment.
* Sealed vtables are a bunch of 32bit relative relocs. They are not pointer sized.
* R2R helpers don't have addresses that are visible from managed code. We don't need to align them at 4 byte boundaries.
Saves around 10 kB on the size of a Hello world. Won't make a huge difference, but this was an easy thing.
* Fix ARM64 code alignment
|
|
When we have an open instance thunk for a method on a valuetype (i.e. a delegate whose signature has a `ref` (valuetype) first parameter), we shouldn't push the first argument to `GetActualTargetFunctionPointer` because that method expects a reference type.
Project N delegate transform already has this fix.
|
|
Prior to .NET Core 2.1, if a task was awaited in a default context (or if ConfigureAwait(false) was used), and if the task was then completed on a non-default context (e.g. code running a non-default TaskScheduler calling SetResult on a TaskCompletionSource), its await continuations are not allowed to be inlined, due to concerns that we could be running an arbitrary amount of unknown code in a scheduling environment that's not amenable to it, like a UI thread. The optimizations added in 2.1 erroneously ended up bypassing that IsValidLocationForInlining check, leading to continuations getting inlined in places they weren't previously.
This commit fixes that. Previously we'd made the IAsyncStateMachineBox interface inherit ITaskCompletionAction, with its Invoke interface method just delegating to MoveNext; then the box could be added to a task as a continuation. But that ITaskCompletionAction logic isn't specific to async/await and doesn't invoke IsValidLocationForInlining. We instead need to follow the Action logic that is meant to be used for async/await. I've removed the ITaskCompletionAction from IAsyncStateMachineBox, replacing it just with a MoveNext interface method, and added a case for IAsyncStateMachineBox to Task's RunContinuations logic. I then duplicated the AwaitTaskContinuation.RunOrScheduleAction logic that's there for Action and tweaked it for IAsyncStateMachineBox. In the process I cleaned up a little code to use some newer C# features.
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Mechanical find&replace to match https://github.com/dotnet/corefx/blob/master/Documentation/coding-guidelines/coding-style.md
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
We special case the method to avoid unnecessarily creating the body (it's pretty big). The codegen might ask questions about the vtable before realizing it's this special method. If the delegate type is not allocated, (not a ConstructedEEType) we wouldn't have vtable information for it from the scanner. Fixing that.
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Only premptively adding for FileSystemInfo if we end in period or space.
Long path is taken care of later.
Clean up code a little and add test for DirectoryInfo.Move.
Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
* Perf fix for month-day parsing ambiguity
* Use DateTime.TryCreate
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|
|
I'm preparing changes to enable running ILLink on SPC
(similarly to what we do on corefx assemblies).
There will be a separate PR for those changes.
This PR just removes the dead code flagged by ILLink from the sources.
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|
|
* add preliminary Library test project (#4985)
* update library test and make it pass on Windows (#4985)
* rename Library test project to SharedLibrary (#4985)
* update sharedlib test, make it pass on darwin (#4985)
* update msbuild tag names (#4985)
* move native runner rsp file to native intermediate output path (#4985)
* add test for static library, make it pass on unix (#4985)
* update static library test, make it pass on Windows
* skip shared library test for linux (#4985)
* fix StaticLibrary linux build (#4985)
* update unix linker args when building StaticLibrary native binary (#4985)
* add copyright headers to all newly added source files (#4985)
* fix multimodule build errors for native library builds (#4985)
* add comment explaining owning module of native library startup method (#4985)
* set owning module of native library startup method to gen'd module (#4985)
* remove unneeded System.Linq import (#4985)
|
|
method name and added some verbose output (#5416)
* Fix include/exclude pattern matching by using fully qualified method name and added some verbose output
* Added missing file
* fix stringification of FieldDesc, MethodDesc and TypeDesc
* Print progress as it goes
* Handle empty namespace in GetQualifiedMethodName
* Use simple counters for statistics and incorporated additional PR feedback
* Removed ProcessedMethodTracker class and do all counting/printing logic directly in the VerifyAssembly method
|
|
|
|
* CoreFX #24343 Vector using Span
dotnet/corefx#24343
* CoreFX #24343 Vector using Span
dotnet/corefx#24343
* CoreFX #24343 Vector using Span
dotnet/corefx#24343
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
* Implement static constructor triggering. Also includes several bug fixes found in the process:
* Don't make the ClassConstructorRunner depend on module intialization
* Moves non-GC statics and thread statics from globals to the type's data regions. GC statics can't be moved until we can call InitializeModules on startup.
* Devirtualizing interface calls to structs in order to be able to compile the class constructor runner.
* Add a prolog block before Block0 to allow branching to Block0, which happens in retail builds
* Correct use of unreachable in traps and at the end of finally blocks to fix more retail build problems
* Stop reusing spill slots when a spilled value is spilled again. This avoids cases where the spills feeding into a block don't use the same slot
* Enable thunks for NativeCallable methods and call RhpReversePInvoke for them
* Fix alignment for cases where a small type is followed by a larger one
* Workaround for Emscripten atomics bug
|
|
Merge nmirror to master
|
|
Merge changes from TFS
|
|
This change makes Project X SharedLibrary 0.9% smaller, and a CoreRT hello world almost 2% smaller. The savings are threefold:
* No longer generating empty dispatch maps (4 bytes per dispatch map)
* No longer needing optional fields for a lot of types (the only reason was to indicate there was a dispatch map)
* No longer needing a pointer to optional fields for a lot of types in the EEType
[tfs-changeset: 1690800]
|
|
Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
I wanted to get rid of the CppCodegen special casing around sealed vtables that was added last week; this became kind of tricky and I ran out of time I allocated myself for it. It seems like interface dispatch is kind of broken in general for CppCodeGen.
This has a couple changes towards the goal:
* Add TargetArchitecture.Cpp64 for CppCodegen so that we can distinguish it from x64
* This forced me to fix the misuse of x64 assembly unboxing helpers because there's no CPU emitter for Cpp64.
* Remove duplication of vtable slot calculation. The logic is different when sealed virtuals are in play. We should just use the common helper.
* Devirtualize calls to final methods. These could be in the sealed vtable which makes the dispatch tricky; just don't use the vtable.
|
|
|
|
* Remove libuuid usage
This change removes dependency on the libuuid library that is used for GUID creation only.
It implements it using a random generator instead.
It also modifies return type of PAL_Random to VOID since it was always
returning TRUE and none of the existing callers were checking it.
1. Port the GUID creation to managed code.
2. Modify the PAL_Random to have 6 times better perf so that the perf of the
CoCreateGuid that is used in the native runtime doesn't degrade that much
w.r.t the previous state when the libuuid was used.
3. Use Interop.GetRandomBytes on Unix and fix Windows
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
* Automatically execute WebAssembly tests on Windows by using emrun to launch a headless instance of Firefox (which doesn't interfere with any other Firefox usage). This should cut down on manual testing and help us move toward CI integration.
|
|
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
This should hopefully unblock official build publishing.
|
|
* Fix encoding methods for Span.Empty
Encoding had a historic confusion about handling null pointers. Make sure that this confusion is not leaking into the new Span methods.
* Use GetNonNullPinnableReference helper method
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
strings (#16672)
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|
|
* Fix MemoryDebugView and add Memory.ToString similar to Span
* Simplify implementation of ToString
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
* Remove StringSpanHelpers and start using MemoryExtensions
* Address PR feedback.
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|
|
|
|
|
|
|
|
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Part of https://github.com/dotnet/corefx/issues/26894
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Inlining doesn't streamline the cast logic any, but it facilitates
caller struct promotion which can substantially boost perf.
See discussion in dotnet/corefx#27485.
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
Contributes to https://github.com/dotnet/corefx/issues/16767
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
|
|
|