- 19 2月, 2018 3 次提交
-
-
由 Jared Parsons 提交于
-
由 Jared Parsons 提交于
-
由 Jared Parsons 提交于
-
- 17 2月, 2018 1 次提交
-
-
由 Jared Parsons 提交于
This unifies our API naming convention. When standard is in the name then we are using the netstandard2.0 API set and when it is not then it is the simple desktop mscorlib46. Both variants are necessary for CompileAndVerify style functions because many of our tests that use it can only run on desktop or simply need to have some of the netstandard2.0 API set missing.
-
- 05 1月, 2018 1 次提交
-
-
由 vsadov 提交于
-
- 30 6月, 2017 1 次提交
-
-
由 vsadov 提交于
Instead of mapping the pointer to a pointer temp, it was mapped to the managed pinned reference (which does not even have the same type). At all the places where the pointer was used, the actual reference was converted to the pointer, repeatedly. I.E. ```C# fixed(int * p = &v) { Use(p); Use(p); Use(p); } ``` was emitted as ```C# try { pinned ref int refTemp = ref v; Use((int*)refTemp); // unsafely cast pinned ref Use((int*)refTemp); // unsafely cast pinned ref Use((int*)refTemp); // unsafely cast pinned ref } finally { // zero-out refTemp } ``` instead of logical pattern matching the semantics: ```C# try { pinned ref int refTemp = ref v; int * p = (int*)refTemp; // unsafely cast pinned ref Use(p); Use(p); Use(p); } finally { // zero-out refTemp } ``` The reason for the strange emit was never truly understood. In fact, in other cases, like fixed string, the more obvious variant was used. One theory was that this codegen was just because of the lack of internal expressiveness in the old compiler around byref locals and we simply carried it forward. The inconsistency required special casing of such `fixed` statements in binding, lowering, codegen and in the semantical model, which must expose the "logical" shape of the statement. Another guess was that this kind of emit was better for JIT. That turned out to be not true. To the contrary - while a pointer temp would be very optimizable, repeated accesses to the pinned ref actually results in noticeable overhead in the JITted code, forcing users to use workarounds like: ```C# fixed(int * p = &v) { // PERF: accessing p has additional expenses, so store it in another temp; int * cheapP = p; Use(cheapP); Use(cheapP); Use(cheapP); } ``` Users should not need to do the above. Compiler should do that in the first place. Fixes: #18615
-
- 08 4月, 2017 1 次提交
-
-
由 Andy Gocke 提交于
-
- 17 3月, 2017 1 次提交
-
-
由 vsadov 提交于
-
- 26 1月, 2016 1 次提交
-
-
由 Jared Parsons 提交于
-
- 02 7月, 2015 1 次提交
-
-
由 Jared Parsons 提交于
Fell out of our normal cadence for this during the push for RTM. Now that we had a bit more breathing room getting us back on track here.
-
- 10 6月, 2015 1 次提交
-
-
由 AlekseyTs 提交于
Fixes #3392.
-
- 06 6月, 2015 1 次提交
-
-
由 AlekseyTs 提交于
Addresses DevDiv 1171076.
-
- 01 2月, 2015 1 次提交
-
-
由 beep boop 提交于
Background: As discussed in the dev team all hands all code under the GitHub dotnet foundation is using a single process for contribution, API review, infrastructure and coding style. The idea is to present a unified view to our customer and give them a single story for contributing to any project under the dotnet foundation. https://github.com/dotnet/corefx/wiki/Contributing#c-coding-style The coding style transition is automated using a Roslyn based rewrite tool: https://github.com/dotnet/codeformatter This will be applied in stages across our developer tree. Right now the focus is on the Open directory as this is what is being presented on github. Code owners will be contacted before the transition happens. Note: this is a soft style requirement. There are no build errors that come from this change. (changeset 1408227)
-
- 15 1月, 2015 1 次提交
-
-
由 jaredpar 提交于
-
- 14 1月, 2015 1 次提交
-
-
由 RoslynTeam 提交于
-
- 02 10月, 2014 1 次提交
-
-
由 TomasMatousek 提交于
This shelveset implements following changes to metadata reference compiler API in order to remove duplication in the public surface and prevent users from unexpected metadata lifetime issues: 1) MetadataImageReference and MetadataFileReference overlap Currently MetadataImageReference can be constructed from a Stream. MetadataImageReference supports metadata prefetch (reading the blob into memory and close the underlying stream) as well deferred reading (no content is read until the reference is consumed during compilation). MetadataFileReference only supports deferred reading. Lifetime of MetadataFileReference is non-deterministic, the underlying file is locked until no references exist and we GC the metadata. On the other hand, it is possible to construct MetadataImageReference in such a way that allows controlling the underlying resources deterministically. Remove MetadataFileReference, use MetadataImageReference instead. 2) Lifetime management AssemblyMetadata and ModuleMetadata objects hold on resources and implement IDisposable. When using MetadataFileReference constructors and some MetadataImageReference constructors to create references the underlying metadata objects are created implicitly and the user doesn’t have a way to explicitly dispose them. Make MetadataImageReference constructors internal and instead add factory method GetReference on AssemblyMetadata/ModuleMetadata. The usage pattern is: using (var metadata = AssemblyMetadata.CreateFromXxx(…)) { var compilation = CSharpCompilation.Create(syntaxTrees, new[] { metadata.GetReference() }); … } In addition the shelveset makes MetadataImageReference internal and adds the following convenience APIs, that are not the most efficient but are very convenient, easy to discover and safe to use for customers that don’t wanna explicitly manage the lifetime of metadata objects. (changeset 1345987)
-
- 15 8月, 2014 1 次提交
-
-
由 TomasMatousek 提交于
Reduce the variety of optimization related compilation option values used in tests to: Release, DebuggableRelease and Debug. By default tests should use Release, which enables all optimizations. PDB tests should mostly use Debug. We should have targeted tests for DebuggableRelease, for optimizations that are selectively disabled to improve debuggability of release builds. (changeset 1312277)
-
- 15 4月, 2014 1 次提交
-
-
由 YingP99 提交于
-
- 19 3月, 2014 1 次提交
-
-
由 Pilchie 提交于
-