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

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-10-30Stabilize object file images (#4818)Simon Nattress
* Determinism test harness Add a /determinism mode to runtest.cmd that will invoke ILC twice with different random determinism seeds. This causes graph expansion to be randomized based on seed (though deterministic for a given seed). * Add Utf8String.CompareTo Implementation taken from S.P.CoreLib. All the loop unrolling optimizations were excluded; we re-implement them if this function becomes a perf bottleneck. * Define the mechanisms for determinism To ensure deterministic output, all nodes that are emitted to the binary are sorted after compilation when retrieving the final marked nodes list. The overall approach is to sort nodes of the same type together (ie, all EETypeNodes come before NonGcStaticsNodes). Within nodes of the same type, a comparison function uses a CompilerComparer to compare the key identifying data of a node. For example, an EETypeNode is defined by a TypeDesc. The CompilerComparer provides a stable comparison function for comparing various type system primitives. Some nodes need to be emitted in an early and specific order for compiler correctness; this is provided by partitioning all sorted nodes into two phases: the first phase containined specifically ordered nodes, and a second phase for all other nodes whose ordering in the output binary doesn't matter. Add SortableDependencyNode abstract class which provides the sortability layer on top of a DependencyNodeCore. Both ObjectNode and EmbeddedObjectNode derive from SortableDependencyNode to provide sortability across all nodes that are emitted to the output binary. Introduce `ISortableSymbolNode` to provide sortability for nodes that are currently referred to in the compiler via the ISymbolNode interface. Such nodes are actually `ObjectNode` or `EmbeddedObjectNode` instances that we've lost type information for. Instances that implement `ISortableSymbolNode` redirect to the matching SortableDependencyNode methods. Add `EmbeddedDataContainerNode` as a base class of `ArrayOfEmbeddedDataNode` to allow comparison of different instantiations. Refactor the interface dispatch map index calculation so it's done when the dispatch map is emitted at the end of compilation. Previously it was done when the indirection cell in the dispatch map array got marked. This mechanism is incompatible with generating stable dispatch map indices. The arrays of embedded nodes now stabilize IDs as they emit their final data. This introduces an output ordering dependency - OptionalEETypeNodes must be emitted after the dispatch map since they encode dispatch map indices. Manually enforce this with C++ code generation, since it doesn't emit the real dispatch map structure and builds its own. Modify InterfaceDispatchMapNode to use the type name in name mangling instead of an index into the dispatch map table. Modify ObjectDumper to also amit a sha256 hash of each node's data. This dump is used to diff the map files and prove determinism. * Fill out ordering functions for all nodes Most of these are not very interesting. Here's the overall approach: - Every different type of node needs a unique ClassCode. These were generated using Math.Random. - The various metadata / native layout nodes plus arrays of EmbeddedObjectNodes get placed in the Ordered phase with specific ordering of each. - All other nodes go in the Unordered phase - To order nodes of the same type, the data that represents the key for the node in NodeFactory is compared. Ie, for an EEType, that would be its defining TypeDesc, whereas a FrozenStringNode is defined by the string it represents). - The marked nodes list also contains raw DependencyNodeCore<T> nodes, which aren't emitted. Those are all shuffled after the emitted nodes and not sorted amongst themselves. That hasn't proven to be a problem with determinism and saves a bunch of hopefully unnecessary comparisons.
2017-06-24Update CoreRT build to use latest .NET CLI and build tools (#3916)Jan Kotas
- Pick up latest .NET Core 2.0 CLI and buildtools - Remove all project.json references and convert everything to msbuild projects - Stick to vanilla .NET CLI project shape as much as possible. Minimize dependencies on buildtools special behaviors
2017-06-17Merge remote-tracking branch 'upstream/nmirror' into nmirror-mergeJan Kotas
2017-06-17Delete ToolsVersion attribute from msbuild filesJan Kotas
The latest project templates do not have it, and it is only good for generating warnings like the following in the detailed build log: Project file contains ToolsVersion="4.0". This toolset may be unknown or missing, in which case you may be able to resolve this by installing the appropriate version of MSBuild, or the build may have been forced to a particular ToolsVersion for policy reasons. Treating the project as if it had ToolsVersion="14.0". For more information, please see http://go.microsoft.com/fwlink/?LinkId=293424. [tfs-changeset: 1662024]
2017-06-15Enable IL scanner and use it to provide VTable information (#3884)Michal Strehovský
This exposes a command line switch to enable IL scanner. When IL scanner is enabled, it determines the shape of all VTables to be used during compilation, allowing codegen to generate inline vtable lookups (instead of calling an assembly helper that does the lookup). * Factoring of Compilation and ILScanner so that they both can provide lists of compiled methods and generated EETypes * `IMethodBodyNode` to mark the node that represents a method body in a given compilation. * Diff the results of scanning and compilation phases to find potential issues in the scanner. * Native layout is asking for vtables of RuntimeDetermined things. Switching it over to ask for the canon versions. Known analysis discrepancies: * SIMD intrinsics not getting recognized as intrinsics in the scanner. There's just too many of them. Worked around by ignoring all scan/compilation diffs in the SIMD module. * Type system entities injected by interop/reflection not surviving across scan/compile phases. For now, ignoring them under an active issue (#3873)
2017-05-19Fixing the processing of dynamic dependencies to not recompute already ↵Fadi Hanna
computed results (90% perf improvement on Release builds for the ASPNet benchmark app (22 mins to 2 mins total compile time) (#3652)
2017-05-16Add IL scanner phase (#3503)Michal Strehovský
This adds an initial implementation of an IL scanner that will scan method bodies, starting from the provided compilation roots, and expand the dependency graph based on scanning the IL, to determine the set of methods (and types, and other interesting artifacts) that will be compiled. This nicely plugs into the existing architecture where the scanner looks almost just like another codegen backend - we have a separate NodeFactory for it, a separate builder class, and a separate compilation class. The actual IL parsing reuses the importer written for CppCodegen and ILVerifier. The results of the scanning phase will flow into the metadata generator and potentially other parts of the system.
2017-05-11Fix assert generating dependency logSimon Nattress
FirstMarkLogStrategy.VisitLogNodes contains a HashSet, combinedNodesReporting, that ensures we only report duplicate combined dependencies once. We were checking the HashSet didn't already contain an entry but failing to add the entry after visiting the node.
2017-03-17Experimental prototype of jit for CoreRTDavid Wrighton
- Refactorings and tweaks of various ILCompiler infrastructure to allow use within the runtime - Refactor delegate creation info off of CompilerTypeSystemContext onto TypeSystemContext - Tweak jit interface to always refer to nodes via interfaces instead of concrete types - adjust CorInfoImpl.constructStringLiteral to respect the RepresentsIndirectionCell flag - Initial copy of JitCodeManager. Currently only supports Windows. - System.Private.Jit - Uses infrastructure from the ILCompiler such as the CorInfoImpl, jitinterface, and the dependency node infrastructure to define a way to express newly generated code and its dependencies. - Where relocs from jitted code depend on resolving to other components, they are always indirected through an indirection cell, and the final value is computed by the dynamic type loader GenericDictionaryCell system (which is poorly named, and is actually a general purpose runtime component resolution system.) - New concept of dynamic MethodEntrypoints in the type loader. This is used to bridge to the jit where necessary - The various bits of build time goo to produce experimental versions of System.Private.Reflection.Core, System.Private.Reflection.Execution, and System.Private.TypeLoader which contain the ECMA based type loader, and support the jit. - The new behavior is only enabled for these new experimental builds. - As the existing ECMA 335 based typeloader/reflection logic hasn't been enabled for building, there are fixes to make it work again [tfs-changeset: 1651156]
2017-03-14Merge pull request #2952 from MichalStrehovsky/genericDependencyLogWriterMichal Strehovský
Remove most of the usages of static name mangler
2017-03-13Make GetName protected but not internalMichal Strehovský
This is so that "this node is implemented in the same assembly as the dependency analysis framework" and "this node is implemented in a different assembly" doesn't require conflicting accessibility rules on `GetName` overrides (one is "protected internal" the other is just "protected").
2017-03-11Make GetName method accept the dependency contextMichal Strehovský
2017-03-10Move GetName method to the generic dependency nodeMichal Strehovský
2017-03-10Add copyright header to new fileDavid Wrighton
[tfs-changeset: 1650235]
2017-03-10Track UTC code generation through NonExternMethodSymbolNodes instead of ↵David Wrighton
ExternMethodSymbolNodes - Remove current duplicate nodes - Distinguish between methods compiled in current compilation and code referenced from other modules - Add IDependencyNode concepts so that ShadowConcreteMethodNode can work off of an interface only. (Also, made ISymbolNode inherit from it, so that we can easily do more such work) [tfs-changeset: 1650230]
2017-03-01Make DgmlWriter call GetName instead of ToString (#2845)Michal Strehovský
We agreed in the past that `ToString` is allowed to return debugger-friendly strings and doesn't need to be the symbolic name. Disentangle pieces of `DgmlWriter` so that it can call the right method instead of `ToString`. This is a step towards getting rid of the static name mangler. In the next step, `GetName` will be updated to accept a `DependencyContextType` parameter (`NodeFactory` in the `ILCompiler` world) so that it can get to the `NameMangler` associated with the factory and we can get rid of the static that makes everything non-unit testable (two different name manglers can't coexist in a single process right now), limiting what we can test in xunit.
2017-02-25Update build tools to latest (#2815)Jan Kotas
* Update BuildToolsVersion to latest * Cleanup CLSCompliant warnings * Delete workaround that is no longer needed * Download .NET Core 1.1 * Fix Roslyn props * MSBuild.exe was renamed to MSBuild.dll * Fix CoreCLR tests * Rename netcoreapp12 -> netcoreapp20 * Fix UnitTests runs * Fix RemoveEmptyFinalizers CodeAnalysis warnings * Port init-tools.sh cleanup from CoreCLR
2017-02-14Upgrade .NET Core NuGet packages to latest versions (#2667)Jan Kotas
2017-02-07RI from ProjNdev3dotnet-bot
[tfs-changeset: 1646943]
2017-02-03Port internal changes to allow hosting ILCompiler as a library (#2648)Simon Nattress
* Add a few new node types used when the UTC compiler hosts ILCompiler: `ThreadStaticsIndexNode`, `ThreadStaticsOffsetNode`, `GCStaticDescNode`, `UtcDictionaryLayoutNode`. * Add a UTC-specific `UtcNodeFactory` * Various type visibility changes
2017-01-07Hide a garbage Tools item from Solution Explorer (#2456)Michal Strehovský
This thing is useless in the VS Solution Explorer and has an annoying warning sign.
2016-12-20Add packaging build changes and scripts. (#2325)Chris Rummel
2016-12-09Make ordering of modifiers more consistent (#2318)Jan Kotas
- s/readonly static/static readonly/ - s/static internal/internal static/ - s/static private/private static/ - s/static public/public static/ - s/static protected/protected static/ - s/unsafe static/static unsafe/ - s/unsafe extern/extern unsafe/ - s/internal protected/protected internal/
2016-09-29Make GetName protected internal (#1946)Michal Strehovský
`GetName` is "get the name to be used in the diagnostic log". The rules around it in the compier are: * if the node is a `ISymbolNode` it should include the mangled name so that it's easy to crossreference it with the object file (doesn't necessarily have to be equal to the mangled name - see EETypeNode and friends that append "constructed", etc.) * if the node is not an `ISymbolNode`, get something that will be useful to search for in the dependency log I'm making the API protected and internal to avoid misuse and fixing the places misusing this API (the spot in ObjectWriter was just wrong, CppWriter was okay, but with problems waiting to happen). I'm also unsealing ToString. We'll want to override it on a case-by-case basis to make debugger experience more pleasant.
2016-09-27Update buildtools to 1.0.26-prerelease-00809-01 (#1922)Jan Kotas
2016-09-24Make a few writable properties immutable (#1917)Michal Strehovský
Today I learned: omitting the `private set;` part will make the C# compiler emit a `initonly` backing field (and as such, allow assigning the property in the constructor only).
2016-09-20Update CLIJan Kotas
2016-04-29Merge pull request #1209 from MichalStrehovsky/sealEqualsAndGetHashCodeDavid Wrighton
Seal Equals and GetHashCode on DependencyNode
2016-04-27Implement Equals/GetHashCode for CombinedDependencyListEntry (#1202)Michal Strehovský
This was falling back to the runtime supplied implementation which has pretty bad perf characteristics. Also made the fields read only and implemented IEquatable for good measure.
2016-04-27Seal Equals and GetHashCode on DependencyNodeMichal Strehovský
Dependency nodes always use referential equality. Trying to provide other semantics would break the dependency analysis engine, so let's forbid that.
2016-04-25Fix build warnings on Ubuntu 14.04 x64 (#1195)Manu
Add ubuntu.14.04-x64 and osx.10.10-x64 to list of supported runtimes.
2016-04-22Update buildtoolsMichal Strehovský
This version has the "make ILPROJ project buildable from VS" fix.
2016-04-15Update to Microsoft.DiaSymReader with proper netstandard support (#1150)Jan Kotas
2016-04-15Update ILCompiler to netstandard1.3 (#1148)Jan Kotas
2016-04-12Update nuget package versionsJan Kotas
2016-03-24Drop xunit.netcore.extensions from test projectsMichal Strehovský
Seems like the only value we were getting out of it was this warning as part of the build: ``` Found conflicts between different versions of the same dependent assembly that could not be resolved. ``` I can live without that.
2016-03-10Upgrade System.Reflection.Metadata reference to v1.3Michal Strehovský
2016-02-10Switch to live CLI buildJan Kotas
This reverts commit 374d1f1f2d901b4ef1096fbac2bb3da85e73949e. This reverts commit 81fe8e5d944fdbe2560815f4aead1ab4a447fb5a. This reverts commit 3d2d89e793d1588e1aa7d2273fc880ae208352f5. This reverts commit a1f2ba2cae2dac1d134ae9afd60462cf57dde3c3.
2016-02-06Revert "Merge pull request #717 from schellap/break2"Senthil
This reverts commit 766f4ea7ff4d9dcd0422da1ebd115eb6b279e684, reversing changes made to ce31cfa86e2d82af79212a1b09b7c1fe05baf3f6. Revert "Merge pull request #767 from schellap/wmain" This reverts commit 86e568eb6e82e2526ace252fcb49903e298e708d, reversing changes made to 1d3ef5fd841effc0599511e3073a0cad53bed88b. Revert formatting to old project.json and cppcompilerflag in runtest.cmd
2016-01-29Fix project.json syntax for dotnet restoreSenthil
2016-01-28Merge branch 'nmirror' into nmirror_mergeJan Kotas
Conflicts: src/Common/src/Interop/Windows/mincore/Interop.MEMORY_BASIC_INFORMATION.cs src/ILCompiler.Compiler/src/Compiler/PdbSymbolProvider.cs src/Native/Bootstrap/platform.h src/Native/Bootstrap/platform.windows.cpp src/Native/gc/env/gcenv.windows.cpp src/System.Private.CoreLib/src/Internal/Runtime/CompilerHelpers/ArrayMethodILHelpers.cs tests/src/Simple/AsgAdd1/AsgAdd1.cs
2016-01-28Update licensing headersdotnet-bot
2016-01-17Add hook for interop code pregenerated by Mcg toolJan Kotas
The hook looks for assembly with .McgInterop suffix. If there is one, the PInvoke marshalling code is forwarded to it. Otherwise, the existing ILEmitter-bases solution is used.
2016-01-05Upgrade beta framework references to rc2Jan Kotas
2015-12-18Update package and build tools versionsJan Kotas
2015-11-20Updated formattingManu
Using the https://github.com/dotnet/codeformatter tool with the following command line: /rule-:FieldNames,ReadonlyFields ILCompiler.sln
2015-11-14Rename ILToNativeJan Kotas
- Rename the compiler .exe to ilc.exe - Rename ILToNative.* to ILCompiler.* everywhere else