Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mono] Many libraries tests failing due to The type initializer for 'DynamicDelegateLightup' threw an exception on tvos-arm64 #90494

Closed
ivanpovazan opened this issue Aug 13, 2023 · 5 comments · Fixed by #90519
Assignees
Labels
area-System.Linq.Expressions blocking-clean-ci Blocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms' Known Build Error Use this to report build issues in the .NET Helix tab os-ios Apple iOS
Milestone

Comments

@ivanpovazan
Copy link
Member

ivanpovazan commented Aug 13, 2023

Build Information

Build: https://dev.azure.com/dnceng-public/cbb18261-c48f-4abb-8651-8cdcb5474649/_build/results?buildId=371961

Affected pipelines:

  • runtime-extra-platforms

Build error legs:

  • net8.0-tvos-Release-arm64-Mono_Release-OSX.13.Amd64.AppleTV.Open

Work items failing:

  • Microsoft.Extensions.DependencyModel.Tests
  • System.ComponentModel.Composition.Registration.Tests
  • System.Composition.Convention.Tests
  • System.Composition.Hosting.Tests
  • System.Composition.TypedParts.Tests
  • System.Linq.Queryable.Tests
  • System.Linq.Tests
  • System.Numerics.Vectors.Tests
  • System.Private.Xml.Tests
  • System.Text.Json.Tests
  • System.Xml.XmlSerializer.ReflectionOnly.Tests

Crash log example:

[FAIL] System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte   Test name: System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte
[11:51:46.1955960] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    Assembly:  [System.Numerics.Vectors.Tests, Version=8.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51]
[11:51:46.1956340]    Exception messages: System.TypeInitializationException : The type initializer for 'DynamicDelegateLightup' threw an exception.
[11:51:46.1957100] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777] ---- System.NullReferenceException : Object reference not set to an instance of an object   Exception stack traces:    at System.Linq.Expressions.Interpreter.LightLambda.MakeDelegate(Type delegateType)
[11:51:46.1957300]    at System.Linq.Expressions.Interpreter.LightDelegateCreator.CreateDelegate(IStrongBox[] closure)
[11:51:46.1957360] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    at System.Linq.Expressions.Interpreter.LightDelegateCreator.CreateDelegate()
[11:51:46.1957930] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    at System.Linq.Expressions.Expression`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Compile()
[11:51:46.1959270] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].CreateCustomNoMatchDelegate(MethodInfo invoke)
[11:51:46.1960510] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].MakeUpdateDelegate()
[11:51:46.1960900] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetUpdateDelegate(Func`3& addr)
[11:51:46.1964690] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetUpdateDelegate()
[11:51:46.1982050] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]..ctor(CallSiteBinder binder)
[11:51:46.1982950] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Create(CallSiteBinder binder)
[11:51:46.1983030]    at System.Numerics.Tests.Util.GenerateSingleValue[Int32](Int32 min, Int32 max)
[11:51:46.1983600] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Numerics.Tests.GenericVectorTests.TestCopyToWithOffset[SByte]()
[11:51:46.1983670]    at System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte()
[11:51:46.1983720]    at System.Reflection.MethodBaseInvoker.InterpretedInvoke_Method(Object obj, IntPtr* args)
[11:51:46.1984460] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)
[11:51:46.1984660] ----- Inner Stack Trace -----
[11:51:46.1984720]    at System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup.CreateObjectArrayDelegateInternal()
[11:51:46.1985120] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup..cctor()
[11:51:46.1985240]    Execution time: 0.0709817
[11:51:46.2161210] 2023-08-12 08:51:46.287 System.Numerics.Vectors.Tests[64278:31862777]    Test name: System.Numerics.Tests.GenericVectorTests.LessThanAllInt16
[11:51:46.2161580] 2023-08-12 08:51:46.287 System.Numerics.Vectors.Tests[64278:31862777]    Exception messages: System.TypeInitializationException : The type initializer for 'DynamicDelegateLightup' threw an exception.

Pull request: #90023

Error Message

Fill the error message using step by step known issues guidance.

{
  "ErrorMessage": "The type initializer for 'DynamicDelegateLightup' threw an exception",
  "ErrorPattern": "",
  "BuildRetry": false,
  "ExcludeConsoleLog": false
}

Known issue validation

Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=371961
Error message validated: The type initializer for 'DynamicDelegateLightup' threw an exception
Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 8/13/2023 7:26:42 PM UTC

Report

Build Definition Test Pull Request
372647 dotnet/runtime System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte #90421
372587 dotnet/runtime System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte #90515
372550 dotnet/runtime System.Linq.Tests.CountTests.Empty
372445 dotnet/runtime System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte #90270
372307 dotnet/runtime System.Linq.Tests.LegacyTests.SelectManyTests.ResultsSelectedIndexUsed
372186 dotnet/runtime System.Linq.Tests.SkipTests.Skip
372071 dotnet/runtime System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte
371961 dotnet/runtime System.Linq.Tests.AverageTests.MultipleNullableFloatSource #90023

Summary

24-Hour Hit Count 7-Day Hit Count 1-Month Count
4 8 8
@ivanpovazan ivanpovazan added blocking-clean-ci Blocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms' Known Build Error Use this to report build issues in the .NET Helix tab labels Aug 13, 2023
@ivanpovazan ivanpovazan added this to the 8.0.0 milestone Aug 13, 2023
@dotnet-issue-labeler dotnet-issue-labeler bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Aug 13, 2023
@ivanpovazan
Copy link
Member Author

ivanpovazan commented Aug 13, 2023

/cc: @premun I assume this is the reason for the spike you reported at: #90023 (comment)
in any case, that PR seems to be stable now

@ivanpovazan
Copy link
Member Author

Some more information:
The failures - ~ 1600 failing tests were first observed in build: https://dev.azure.com/dnceng-public/public/_build/results?buildId=371518&view=results
which suggests that the regression could have been introduced in the following range: https://github.com/dotnet/runtime/compare/34b6db9..2d9acc6f789b7ed098c251151c609eb68f21f68c

@ivanpovazan ivanpovazan added the os-ios Apple iOS label Aug 13, 2023
@ghost
Copy link

ghost commented Aug 13, 2023

Tagging subscribers to 'os-ios': @steveisok, @akoeplinger, @kotlarmilos
See info in area-owners.md if you want to be subscribed.

Issue Details

Build Information

Build: https://dev.azure.com/dnceng-public/cbb18261-c48f-4abb-8651-8cdcb5474649/_build/results?buildId=371961

Affected pipelines:

  • runtime-extra-platforms

Build error legs:

  • net8.0-tvos-Release-arm64-Mono_Release-OSX.13.Amd64.AppleTV.Open

Work items failing:

  • Microsoft.Extensions.DependencyModel.Tests
  • System.ComponentModel.Composition.Registration.Tests
  • System.Composition.Convention.Tests
  • System.Composition.Hosting.Tests
  • System.Composition.TypedParts.Tests
  • System.Linq.Queryable.Tests
  • System.Linq.Tests
  • System.Numerics.Vectors.Tests
  • System.Private.Xml.Tests
  • System.Text.Json.Tests
  • System.Xml.XmlSerializer.ReflectionOnly.Tests

Crash log example:

[FAIL] System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte   Test name: System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte
[11:51:46.1955960] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    Assembly:  [System.Numerics.Vectors.Tests, Version=8.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51]
[11:51:46.1956340]    Exception messages: System.TypeInitializationException : The type initializer for 'DynamicDelegateLightup' threw an exception.
[11:51:46.1957100] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777] ---- System.NullReferenceException : Object reference not set to an instance of an object   Exception stack traces:    at System.Linq.Expressions.Interpreter.LightLambda.MakeDelegate(Type delegateType)
[11:51:46.1957300]    at System.Linq.Expressions.Interpreter.LightDelegateCreator.CreateDelegate(IStrongBox[] closure)
[11:51:46.1957360] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    at System.Linq.Expressions.Interpreter.LightDelegateCreator.CreateDelegate()
[11:51:46.1957930] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    at System.Linq.Expressions.Expression`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Compile()
[11:51:46.1959270] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].CreateCustomNoMatchDelegate(MethodInfo invoke)
[11:51:46.1960510] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].MakeUpdateDelegate()
[11:51:46.1960900] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetUpdateDelegate(Func`3& addr)
[11:51:46.1964690] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetUpdateDelegate()
[11:51:46.1982050] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]..ctor(CallSiteBinder binder)
[11:51:46.1982950] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Create(CallSiteBinder binder)
[11:51:46.1983030]    at System.Numerics.Tests.Util.GenerateSingleValue[Int32](Int32 min, Int32 max)
[11:51:46.1983600] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Numerics.Tests.GenericVectorTests.TestCopyToWithOffset[SByte]()
[11:51:46.1983670]    at System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte()
[11:51:46.1983720]    at System.Reflection.MethodBaseInvoker.InterpretedInvoke_Method(Object obj, IntPtr* args)
[11:51:46.1984460] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)
[11:51:46.1984660] ----- Inner Stack Trace -----
[11:51:46.1984720]    at System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup.CreateObjectArrayDelegateInternal()
[11:51:46.1985120] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup..cctor()
[11:51:46.1985240]    Execution time: 0.0709817
[11:51:46.2161210] 2023-08-12 08:51:46.287 System.Numerics.Vectors.Tests[64278:31862777]    Test name: System.Numerics.Tests.GenericVectorTests.LessThanAllInt16
[11:51:46.2161580] 2023-08-12 08:51:46.287 System.Numerics.Vectors.Tests[64278:31862777]    Exception messages: System.TypeInitializationException : The type initializer for 'DynamicDelegateLightup' threw an exception.

Pull request: #90023

Error Message

Fill the error message using step by step known issues guidance.

{
  "ErrorMessage": "The type initializer for 'DynamicDelegateLightup' threw an exception",
  "ErrorPattern": "",
  "BuildRetry": false,
  "ExcludeConsoleLog": false
}

Known issue validation

Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=371961
Error message validated: The type initializer for 'DynamicDelegateLightup' threw an exception
Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 8/13/2023 7:26:42 PM UTC

Author: ivanpovazan
Assignees: -
Labels:

blocking-clean-ci, os-ios, Known Build Error, needs-area-label

Milestone: 8.0.0

@ghost
Copy link

ghost commented Aug 13, 2023

Tagging subscribers to this area: @cston
See info in area-owners.md if you want to be subscribed.

Issue Details

Build Information

Build: https://dev.azure.com/dnceng-public/cbb18261-c48f-4abb-8651-8cdcb5474649/_build/results?buildId=371961

Affected pipelines:

  • runtime-extra-platforms

Build error legs:

  • net8.0-tvos-Release-arm64-Mono_Release-OSX.13.Amd64.AppleTV.Open

Work items failing:

  • Microsoft.Extensions.DependencyModel.Tests
  • System.ComponentModel.Composition.Registration.Tests
  • System.Composition.Convention.Tests
  • System.Composition.Hosting.Tests
  • System.Composition.TypedParts.Tests
  • System.Linq.Queryable.Tests
  • System.Linq.Tests
  • System.Numerics.Vectors.Tests
  • System.Private.Xml.Tests
  • System.Text.Json.Tests
  • System.Xml.XmlSerializer.ReflectionOnly.Tests

Crash log example:

[FAIL] System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte   Test name: System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte
[11:51:46.1955960] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    Assembly:  [System.Numerics.Vectors.Tests, Version=8.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51]
[11:51:46.1956340]    Exception messages: System.TypeInitializationException : The type initializer for 'DynamicDelegateLightup' threw an exception.
[11:51:46.1957100] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777] ---- System.NullReferenceException : Object reference not set to an instance of an object   Exception stack traces:    at System.Linq.Expressions.Interpreter.LightLambda.MakeDelegate(Type delegateType)
[11:51:46.1957300]    at System.Linq.Expressions.Interpreter.LightDelegateCreator.CreateDelegate(IStrongBox[] closure)
[11:51:46.1957360] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    at System.Linq.Expressions.Interpreter.LightDelegateCreator.CreateDelegate()
[11:51:46.1957930] 2023-08-12 08:51:46.267 System.Numerics.Vectors.Tests[64278:31862777]    at System.Linq.Expressions.Expression`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Compile()
[11:51:46.1959270] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].CreateCustomNoMatchDelegate(MethodInfo invoke)
[11:51:46.1960510] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].MakeUpdateDelegate()
[11:51:46.1960900] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetUpdateDelegate(Func`3& addr)
[11:51:46.1964690] 2023-08-12 08:51:46.268 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].GetUpdateDelegate()
[11:51:46.1982050] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]..ctor(CallSiteBinder binder)
[11:51:46.1982950] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Runtime.CompilerServices.CallSite`1[[System.Func`3[[System.Runtime.CompilerServices.CallSite, System.Linq.Expressions, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a],[System.Object, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Int32, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].Create(CallSiteBinder binder)
[11:51:46.1983030]    at System.Numerics.Tests.Util.GenerateSingleValue[Int32](Int32 min, Int32 max)
[11:51:46.1983600] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Numerics.Tests.GenericVectorTests.TestCopyToWithOffset[SByte]()
[11:51:46.1983670]    at System.Numerics.Tests.GenericVectorTests.CopyToWithOffsetSByte()
[11:51:46.1983720]    at System.Reflection.MethodBaseInvoker.InterpretedInvoke_Method(Object obj, IntPtr* args)
[11:51:46.1984460] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)
[11:51:46.1984660] ----- Inner Stack Trace -----
[11:51:46.1984720]    at System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup.CreateObjectArrayDelegateInternal()
[11:51:46.1985120] 2023-08-12 08:51:46.270 System.Numerics.Vectors.Tests[64278:31862777]    at System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup..cctor()
[11:51:46.1985240]    Execution time: 0.0709817
[11:51:46.2161210] 2023-08-12 08:51:46.287 System.Numerics.Vectors.Tests[64278:31862777]    Test name: System.Numerics.Tests.GenericVectorTests.LessThanAllInt16
[11:51:46.2161580] 2023-08-12 08:51:46.287 System.Numerics.Vectors.Tests[64278:31862777]    Exception messages: System.TypeInitializationException : The type initializer for 'DynamicDelegateLightup' threw an exception.

Pull request: #90023

Error Message

Fill the error message using step by step known issues guidance.

{
  "ErrorMessage": "The type initializer for 'DynamicDelegateLightup' threw an exception",
  "ErrorPattern": "",
  "BuildRetry": false,
  "ExcludeConsoleLog": false
}

Known issue validation

Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=371961
Error message validated: The type initializer for 'DynamicDelegateLightup' threw an exception
Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 8/13/2023 7:26:42 PM UTC

Author: ivanpovazan
Assignees: -
Labels:

area-System.Linq.Expressions, blocking-clean-ci, os-ios, Known Build Error, needs-area-label

Milestone: 8.0.0

@ivanpovazan ivanpovazan self-assigned this Aug 13, 2023
@ivanpovazan ivanpovazan removed the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Aug 13, 2023
@ivanpovazan
Copy link
Member Author

ivanpovazan commented Aug 13, 2023

This regression seems to be introduced with: #88723

That PR changed the way System.Linq.Expressions.dll is built by disabling constant propagation during library build time. As a consequence, the library is now shipped with System.Dynamic.Utils.DelegateHelpers.DynamicDelegateLightup type which is always trimmed away during app deployment (trimming is always on for ios/tvos devices).

However, since we do not enable trimming for libraries tests, the type is preserved and Mono throws during its initialization.

What is left unanswered is, why we started seeing this recently and not when the change was made.

@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Aug 14, 2023
ivanpovazan added a commit that referenced this issue Aug 14, 2023
…ntime.Augments.DynamicDelegateAugments` in build scenarios without linking (#90519)

Fixes #90494

---------

Co-authored-by: Jan Kotas <[email protected]>
@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label Aug 14, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Sep 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.Linq.Expressions blocking-clean-ci Blocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms' Known Build Error Use this to report build issues in the .NET Helix tab os-ios Apple iOS
Projects
None yet
1 participant