You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are seeing sporadic but significant failures that come down to a stack overflow in SimpleCovariantReturnEndToEndTests
Iniciando la ejecuci¢n de pruebas, espere...
1 archivos de prueba en total coincidieron con el patr¢n especificado.
[xUnit.net 00:00:49.28] Microsoft.CodeAnalysis.CSharp.UnitTests.Emit.CovariantReturnTests.CheckPreserveBaseOverride_01 [SKIP]
[xUnit.net 00:00:49.28] Microsoft.CodeAnalysis.CSharp.UnitTests.Emit.CovariantReturnTests.CovariantRuntimeHasRequiredMembers [SKIP]
[xUnit.net 00:00:49.28] Microsoft.CodeAnalysis.CSharp.UnitTests.Emit.CovariantReturnTests.SimpleCovariantReturnEndToEndTest [SKIP]
Omitidas Microsoft.CodeAnalysis.CSharp.UnitTests.Emit.CovariantReturnTests.CheckPreserveBaseOverride_01 [1 ms]
Omitidas Microsoft.CodeAnalysis.CSharp.UnitTests.Emit.CovariantReturnTests.CovariantRuntimeHasRequiredMembers [1 ms]
Omitidas Microsoft.CodeAnalysis.CSharp.UnitTests.Emit.CovariantReturnTests.SimpleCovariantReturnEndToEndTest [1 ms]
Se ha anulado la serie de pruebas activa. Motivo: Proceso de host de pruebas bloqueado : Process is terminated due to StackOverflowException.
The stack frames that are looping here
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitCore(Microsoft.CodeAnalysis.SyntaxNode node) Line 96 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitTypeDeclarationCore(Microsoft.CodeAnalysis.CSharp.Syntax.TypeDeclarationSyntax parent, Microsoft.CodeAnalysis.CSharp.BinderFactory.NodeUsage extraInfo) Line 712 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitTypeDeclarationCore(Microsoft.CodeAnalysis.CSharp.Syntax.TypeDeclarationSyntax parent) Line 696 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitStructDeclaration(Microsoft.CodeAnalysis.CSharp.Syntax.StructDeclarationSyntax node) Line 750 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.Syntax.StructDeclarationSyntax.Accept<System.__Canon>(Microsoft.CodeAnalysis.CSharp.CSharpSyntaxVisitor<System.__Canon> visitor) Line 9947 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitCore(Microsoft.CodeAnalysis.SyntaxNode node) Line 96 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitTypeDeclarationCore(Microsoft.CodeAnalysis.CSharp.Syntax.TypeDeclarationSyntax parent, Microsoft.CodeAnalysis.CSharp.BinderFactory.NodeUsage extraInfo) Line 712 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitTypeDeclarationCore(Microsoft.CodeAnalysis.CSharp.Syntax.TypeDeclarationSyntax parent) Line 696 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.BinderFactory.BinderFactoryVisitor.VisitStructDeclaration(Microsoft.CodeAnalysis.CSharp.Syntax.StructDeclarationSyntax node) Line 750 C#
Microsoft.CodeAnalysis.CSharp.dll!Microsoft.CodeAnalysis.CSharp.Syntax.StructDeclarationSyntax.Accept<System.__Canon>(Microsoft.CodeAnalysis.CSharp.CSharpSyntaxVisitor<System.__Canon> visitor) Line 9947 C#
The StackOverflowException is in EndToEndTests.DeeplyNestedGeneric(). That test contains deeply nested types: MyStruct0<T0> { MyStruct1<T1> { ... MyStructN<TN> { } ... } } and the StackOverflowException occurs when getting the Binder for a nested struct.
The reason the failure happens only sporadically is that BinderFactoryVisitor caches a Binder for each declaration SyntaxNode in BinderFactory._binderCache. The cache is small (50 items) and SyntaxNode relies on Object.GetHashCode() which calculates the hash code from the object reference, so each ParsedSyntaxTree is likely to have a different set of 50 items in the cache when visiting the same syntax.
In the worst case, getting the Binder for the inner most MyStructN<TN> { } might recurse through all containing types to get the containing Binder instances without any cache hits.
We are seeing sporadic but significant failures that come down to a stack overflow in SimpleCovariantReturnEndToEndTests
The stack frames that are looping here
Crash dump of the failure is available here https://helixre8s23ayyeko0k025g8.blob.core.windows.net/dotnet-roslyn-refs-heads-main-af6e9e6c69714fc4a2/Microsoft.CodeAnalysis.CSharp.Emit.UnitTests.dll.12/testhost.net472.x86.exe.6848.dmp?%3Fsv%3D2019-07-07%26se%3D2021-05-31T21%253A37%253A05Z%26sr%3Dc%26sp%3Drl%26sig%3Do42%252FHeF%252BlVcH6kcsyvtjd8YFOmtvtlD%252B9b4xhNOpuVo%253D
Runfo Tracking Issue: Stackoverflow in SimpleCovariantReturnsEndToEnd tests
Displaying 100 of 205 results
Build Result Summary
The text was updated successfully, but these errors were encountered: