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

[NO-MERGE] CoreCLR runtime instrumentation for measuring type load performance #95288

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Add support for inclusive / exclusive time measurement

278114e
Select commit
Loading
Failed to load commit list.
Open

[NO-MERGE] CoreCLR runtime instrumentation for measuring type load performance #95288

Add support for inclusive / exclusive time measurement
278114e
Select commit
Loading
Failed to load commit list.
Build Analysis / Build Analysis failed Dec 15, 2023 in 0s

.NET Result Analysis

Details

Build Failures

runtime / Build / CoreCLR Product Build linux arm checked / Build CoreCLR Runtime

[:construction: Report infrastructure issue] [:page_facing_up: Report repository issue]
    ❌Failed to build "CoreCLR component".
    ❌Bash exited with code '2'.

runtime / Build / CoreCLR Product Build linux arm64 checked / Build CoreCLR Runtime

[:construction: Report infrastructure issue] [:page_facing_up: Report repository issue]
    ❌Failed to build "CoreCLR component".
    ❌Bash exited with code '2'.

runtime / Build / CoreCLR Product Build linux_musl x64 checked / Build CoreCLR Runtime

[:construction: Report infrastructure issue] [:page_facing_up: Report repository issue]
    ❌Failed to build "CoreCLR component".
    ❌Bash exited with code '2'.

26 other jobs are failing and were not displayed due to space limitations.
Builds with failures: [runtime] [dotnet-linker-tests] [runtime-dev-innerloop]

Test Failures (106 tests failed)

🔹 [All failing tests from runtime]

    ⚠️ 101 failing tests not displayed for this pipeline due to space limitations

    baseservices/TieredCompilation/TieredVtableMethodTests/TieredVtableMethodTests.cmd [Console] [Details] [Artifacts] [0.01% failure rate]
    [:construction: Report test infrastructure issue] [:page_facing_up: Report test repository issue]

    Failing Configurations (3)

    Exception Message
    Assert failure(PID 40756 [0x00009f34], Thread: 9068 [0x236c]): Consistency check failed: AV in clr at this callstack:
    ------
    CORECLR! MethodTable::_GetFullyQualifiedNameForClass + 0x1AA (0x00007ffc`c8c86d9a)
    CORECLR! TypeHandle::GetName + 0xD8 (0x00007ffc`c8eced48)
    CORECLR! DumpTypeLoadTimingInfo + 0x98 (0x00007ffc`c906cff8)
    CORECLR! CorHost2::UnloadAppDomain2 + 0x7C (0x00007ffc`c8ccae8c)
    CORECLR! coreclr_shutdown_2 + 0x55 (0x00007ffc`c95517f5)
    CORERUN! <no symbol> + 0x0 (0x00007ff6`b9822e6a)
    CORERUN! GetCurrentClrDetails + 0x273 (0x00007ff6`b9827693)
    CORERUN! GetCurrentClrDetails + 0xB0F9 (0x00007ff6`b9832519)
    CORERUN! GetCurrentClrDetails + 0xB01E (0x00007ff6`b983243e)
    CORERUN! GetCurrentClrDetails + 0xAEDE (0x00007ff6`b98322fe)
    CORERUN! GetCurrentClrDetails + 0xB16E (0x00007ff6`b983258e)
    KERNEL32! BaseThreadInitThunk + 0x14 (0x00007ffc`f69684d4)
    NTDLL! RtlUserThreadStart + 0x21 (0x00007ffc`f8941791)
    -----
    .AV on tid=0x236c (9068), cxr=000000F63A57DF40, exr=000000F63A57E430
    FAILED: false
    

    CORECLR! CHECK::Trigger + 0x1E6 (0x00007ffc`c93d7496)
    CORECLR! CLRVectoredExceptionHandlerPhase3 + 0x4B5 (0x00007ffc`c8d07d55)
    CORECLR! CLRVectoredExceptionHandlerPhase2 + 0x91 (0x00007ffc`c8d07631)
    CORECLR! CLRVectoredExceptionHandler + 0xDFD (0x00007ffc`c8d0758d)
    CORECLR! CLRVectoredExceptionHandlerShim + 0x1B4 (0x00007ffc`c8d07fd4)
    NTDLL! RtlInitializeCriticalSection + 0x190 (0x00007ffc`f8956b40)
    NTDLL! RtlImageNtHeaderEx + 0x17B (0x00007ffc`f89246cb)
    NTDLL! KiUserExceptionDispatcher + 0x3A (0x00007ffc`f8999a2a)
    CORECLR! MethodTable::_GetFullyQualifiedNameForClass + 0x1AA (0x00007ffc`c8c86d9a)
    CORECLR! TypeHandle::GetName + 0xD8 (0x00007ffc`c8eced48)
    File: D:�_work1ssrccoreclr�mexcep.cpp Line: 7179
    Image: C:hwAE840951pcorerun.exe

    Return code: 1
    Raw output file: C:hwAE840951wAB1209B4uploadsTieredCompilationTieredVtableMethodTestsoutput.txt
    Raw output:
    BEGIN EXECUTION
    "C:hwAE840951pcorerun.exe" -p "System.Reflection.Metadata.MetadataUpdater.IsSupported=false" -p "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization=true" TieredVtableMethodTests.dll
    Output file: C:hwAE840951wAB1209B4e�aseservicesTieredCompilationTieredVtableMethodTests iming-info.txt
    CALLS/INDEX | THREAD | INCLUSIVE SECS | EXCLUSIVE SECS | SUBTREE SECS | EXCLUSIVE % | SUBTREE % | ACTION
    0 | 236c | 0.000465900 | 0.000465900 | 0.000000000 | 100.00 | 0.00 | System.Object
    1 | 236c | 0.000073000 | 0.000073000 | 0.000000000 | 100.00 | 0.00 | System.__Canon
    2 | 236c | 0.000092900 | 0.000092900 | 0.000000000 | 100.00 | 0.00 | System.ValueType
    3 | 236c | 0.000105800 | 0.000105800 | 0.000000000 | 100.00 | 0.00 | System.IComparable
    4 | 236c | 0.000057200 | 0.000057200 | 0.000000000 | 100.00 | 0.00 | System.IFormattable
    5 | 236c | 0.000110900 | 0.000053700 | 0.000057200 | 48.42 | 51.58 | System.ISpanFormattable
    6 | 236c | 0.000149200 | 0.000149200 | 0.000000000 | 100.00 | 0.00 | System.IConvertible
    7 | 236c | 0.000004800 | 0.000004800 | 0.000000000 | 100.00 | 0.00 | System.IComparable
    8 | 236c | 0.000003300 | 0.000003300 | 0.000000000 | 100.00 | 0.00 | System.ISpanFormattable
    9 | 236c | 0.000002900 | 0.000002900 | 0.000000000 | 100.00 | 0.00 | System.IFormattable
    10 | 236c | 0.000002900 | 0.000002900 | 0.000000000 | 100.00 | 0.00 | System.IConvertible
    11 | 236c | 0.001647000 | 0.001267200 | 0.000379800 | 76.94 | 23.06 | System.Enum
    12 | 236c | 0.000092500 | 0.000092500 | 0.000000000 | 100.00 | 0.00 | System.Reflection.ICustomAttributeProvider
    13 | 236c | 0.000314900 | 0.000222400 | 0.000092500 |

    CallStack
       at Xunit.Assert.True(Nullable`1 condition, String userMessage) in /_/src/Microsoft.DotNet.XUnitAssert/src/BooleanAsserts.cs:line 146
       at TestLibrary.OutOfProcessTest.RunOutOfProcessTest(String assemblyPath)
       at Program.<<Main>$>g__TestExecutor23|0_24(StreamWriter tempLogSw, StreamWriter statsCsvSw, <>c__DisplayClass0_0&)
    baseservices/typeequivalence/simple/Simple/Simple.cmd [Console] [Details] [Artifacts] [0.00% failure rate]
    [:construction: Report test infrastructure issue] [:page_facing_up: Report test repository issue]

    Failing Configuration

    Exception Message
    Assert failure(PID 6820 [0x00001aa4], Thread: 7048 [0x1b88]): *fixupCell != NULL
    

    CORECLR! Module::FixupNativeEntry + 0x1DA (0x7153b83a)
    CORECLR! Module::FixupDelayListAux<Module *,int (__thiscall Module::*)(READYTORUN_IMPORT_SECTION *,unsigned long,unsigned long *,int)> + 0x1A7 (0x7170616d)
    CORECLR! ReadyToRunInfo::GetEntryPoint + 0x23D (0x71708180)
    CORECLR! MethodDesc::GetPrecompiledR2RCode + 0xA4 (0x71696b6e)
    CORECLR! MethodDesc::GetPrecompiledCode + 0x8E (0x71696990)
    CORECLR! MethodDesc::PrepareILBasedCode + 0x2B3 (0x71698efb)
    CORECLR! MethodDesc::PrepareCode + 0xB0 (0x71698c16)
    CORECLR! CodeVersionManager::PublishVersionableCodeIfNecessary + 0x265 (0x71582956)
    CORECLR! MethodDesc::DoPrestub + 0x406 (0x716938bc)
    CORECLR! PreStubWorker + 0x31C (0x7169bb8b)
    File: D:�_work1ssrccoreclr�mceeload.cpp Line: 4326
    Image: C:hwB1C2094Apcorerun.exe

    Return code: 1
    Raw output file: C:hwB1C2094AwA3EE08FDuploads ypeequivalencesimpleSimpleoutput.txt
    Raw output:
    BEGIN EXECUTION
    "C:hwB1C2094Apcorerun.exe" -p "System.Reflection.Metadata.MetadataUpdater.IsSupported=false" -p "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization=true" Simple.dll
    InterfaceTypesFromDifferentAssembliesAreEquivalent
    ValidateTypeInstanceEquality
    InterfaceTypesMethodOperations
    CallSparseInterface
    TestByRefEquivalence
    TestArrayEquivalence
    TestGenericClassNonEquivalence
    TestGenericInterfaceEquivalence
    TestTypeEquivalenceWithTypePunning
    -- GetFunctionPointer()
    -- Ldftn
    -- Ldvirtftn
    TestLoadingValueTypesWithMethod
    -- ValueTypeWithStaticMethod
    Expected: 100
    Actual: -1073740286
    END EXECUTION - FAILED
    FAILED
    Test failed. Trying to see if dump file was created in C:cores since 12/15/2023 9:42:06 PM
    Processing C:corescorerun.exe.6820.dmp
    Invoking: C:Program Files (x86)Windows Kits10Debuggers�cdb.exe -c "$<C:hwB1C2094A mp4hzxwz.tmp" -z "C:corescorerun.exe.6820.dmp"
    stdout:
    Microsoft (R) Windows Debugger Version 10.0.18362.1 X86
    Copyright (c) Microsoft Corporation. All rights reserved.

    Loading Dump File [C:corescorerun.exe.6820.dmp]
    User Mini Dump File with Full Memory: Only application data is available

    ************* Path validation summary **************
    Response Time (ms) Location
    OK C:hwB1C2094ApPDB
    Symbol search path is: C:hwB1C2094ApPDB
    Executable search path is:
    Windows 10 Version 14393 MP (4 procs) Free x86 compatible
    Product: Server, suite: TerminalServer DataCenter SingleUserTS
    10.0.14393.6343 (rs1_release.230913-1727)
    Machine Name:
    Debug session time: Fri Dec 15 21:42:09.000 2023 (UTC + 0:00)
    System Uptime: 0 days 0:53:42.573
    Process Uptime: 0 days 0:00:03.000
    .......................................

    ************* Symbol Loading Error Summary **************
    Module name Error
    ntdll The system cannot find the file specified

    You can troubleshoot most symbol related issues by turning on symbol loading diagnostics (!sym noisy) and repeating the command that caused symbols to be loaded.
    You should also verify that your symbol search path (.sympath) is correct.
    This dump file has an exception of interest stored in it.
    The stored exception information can be accessed via .ecxr.
    (1aa4.1b88): Unknown exception - code c0000602 (first/second chance not available)
    For analysis of this file, run !analyze -v
    *** WARNING: Unable to verify checksum for coreclr.dll
    eax=0337a6a0 ebx=00000000 ecx=00000000 edx=00000000 esi=0337a650 edi=0337a6a0
    eip=71a49133 esp=0337a984 ebp=0337ba1c iopl=0 nv up ei pl nz ac po nc
    cs=0023 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00000212
    coreclr!FailFastOnAssert+0x21:
    71a49133 5e pop esi
    0:000> cdb: Reading initial command '$<C:hwB1C2094A mp4hzxwz.tmp'
    0:000> .load C:Users
    unner.dotnetsossos.dll
    0:000> ~*k

    . 0 Id: 1aa4.1b88 Suspend: 0 Teb: 03150000 Unfrozen
    ChildEBP RetAddr
    0337a990 71a49e22 coreclr!FailFastOnAssert+0x21
    0337ba1c 71a49534 coreclr!_DbgBreakChe

    CallStack
       at Xunit.Assert.True(Nullable`1 condition, String userMessage) in /_/src/Microsoft.DotNet.XUnitAssert/src/BooleanAsserts.cs:line 146
       at TestLibrary.OutOfProcessTest.RunOutOfProcessTest(String assemblyPath)
       at Program.<<Main>$>g__TestExecutor26|0_27(StreamWriter tempLogSw, StreamWriter statsCsvSw, <>c__DisplayClass0_0&)
    ComInterfaceGenerator.Unit.Tests.WorkItemExecution [Console] [Details] [Artifacts] [1.66% failure rate]
    [:construction: Report test infrastructure issue] [:page_facing_up: Report test repository issue]
    This is a helix work item crash with status: BadExit. To investigate look the [Console log] / navigate to [Helix Artifacts]

    Failing Configurations (2)

    global::Program.TestEntryPoint() [Console] [Details] [Artifacts] [0.01% failure rate]
    [:construction: Report test infrastructure issue] [:page_facing_up: Report test repository issue]

    Failing Configuration

    Exception Message
    Method not found: 'System.String Xunit.Sdk.ArgumentFormatter.Format(!!0, Int32)'.
    CallStack
       at Xunit.Assert.Equal[T](T expected, T actual, IEqualityComparer`1 comparer)
       at Program.<<Main>$>g__TestExecutor2|25_3(StreamWriter tempLogSw, StreamWriter statsCsvSw, <>c__DisplayClass25_0&)
    HostActivation.Tests.StandaloneAppActivation.NoDepsJson_NoRuntimeConfig [Details] [0.04% failure rate]
    [:construction: Report test infrastructure issue] [:page_facing_up: Report test repository issue]

    Failing Configurations (2)

    Exception Message
    Command did not output with Expected Output. Expected: 'Hello World!
    

    .NET 9.0.0-ci
    '
    File Name: D:\a\_work\1\s\artifacts\tests\host\windows.x64.Release\ha\qw40zmvs.4gb\HelloWorld\HelloWorld.exe
    Arguments:
    Exit Code: 0
    StdOut:
    Hello World!

    .NET 9.0.0-ci
    Output file: D:\a\_work\1\s\artifacts\bin\HostActivation.Tests\Release\net8.0\timing-info.txt
    CALLS/INDEX | THREAD | INCLUSIVE SECS | EXCLUSIVE SECS | SUBTREE SECS | EXCLUSIVE % | SUBTREE % | ACTION
    0 | 27fc | 0.000264700 | 0.000264700 | 0.000000000 | 100.00 | 0.00 | System.Object
    1 | 27fc | 0.000010600 | 0.000010600 | 0.000000000 | 100.00 | 0.00 | System.__Canon
    2 | 27fc | 0.000015400 | 0.000015400 | 0.000000000 | 100.00 | 0.00 | System.ValueType
    3 | 27fc | 0.000047400 | 0.000047400 | 0.000000000 | 100.00 | 0.00 | System.IComparable
    4 | 27fc | 0.000010200 | 0.000010200 | 0.000000000 | 100.00 | 0.00 | System.IFormattable
    5 | 27fc | 0.000026500 | 0.000016300 | 0.000010200 | 61.51 | 38.49 | System.ISpanFormattable
    6 | 27fc | 0.000029900 | 0.000029900 | 0.000000000 | 100.00 | 0.00 | System.IConvertible
    7 | 27fc | 0.000000900 | 0.000000900 | 0.000000000 | 100.00 | 0.00 | System.IComparable
    8 | 27fc | 0.000000900 | 0.000000900 | 0.000000000 | 100.00 | 0.00 | System.ISpanFormattable
    9 | 27fc | 0.000000800 | 0.000000800 | 0.000000000 | 100.00 | 0.00 | System.IFormattable
    10 | 27fc | 0.000000700 | 0.000000700 | 0.000000000 | 100.00 | 0.00 | System.IConvertible
    11 | 27fc | 0.000265800 | 0.000158700 | 0.000107100 | 59.71 | 40.29 | System.Enum
    12 | 27fc | 0.000035500 | 0.000035500 | 0.000000000 | 100.00 | 0.00 | System.Reflection.ICustomAttributeProvider
    13 | 27fc | 0.000083000 | 0.000047500 | 0.000035500 | 57.23 | 42.77 | System.Reflection.MemberInfo
    14 | 27fc | 0.000021900 | 0.000021900 | 0.000000000 | 100.00 | 0.00 | System.Reflection.IReflect
    15 | 27fc | 0.000277600 | 0.000172700 | 0.000104900 | 62.21 | 37.79 | System.Type
    16 | 27fc | 0.000003600 | 0.000003600 | 0.000000000 | 100.00 | 0.00 | System.Reflection.IReflectableType
    17 | 27fc | 0.000327900 | 0.000046700 | 0.000281200 | 14.24 | 85.76 | System.Reflection.TypeInfo
    18 | 27fc | 0.000003000 | 0.000003000 | 0.000000000 | 100.00 | 0.00 | System.ICloneable
    19 | 27fc | 0.000000800 | 0.000000800 | 0.000000000 | 100.00 | 0.00 | System.Reflection.MemberInfo
    20 | 27fc | 0.000001900 | 0.000001100 | 0.000000800 | 57.89 | 42.11 | System.Type
    21 | 27fc | 0.000003000 | 0.000001100 | 0.000001900 | 36.67 | 63.33 | System.Reflection.TypeInfo
    22 | 27fc | 0.000000800 | 0.000000800 | 0.000000000 | 100.00 | 0.00 | System.Reflection.ICustomAttributeProvider
    23 | 27fc | 0.000000700 | 0.000000700 | 0.000000000 | 100.00 | 0.00 | System.Reflection.IReflect
    24 | 27fc | 0.000000700 | 0.000000700 | 0.000000000 | 100.00 | 0.00 | System.Reflection.IReflectableType
    25 | 27fc | 0.000000800 | 0.000000800 | 0.000000000 | 100.00 | 0.00 | System.ICloneable
    26 | 27fc | 0.000459400 | 0.000122500 | 0.000336900 | 26.67 | 73.33 | System.RuntimeType
    27 | 27fc | 0.000013400 | 0.000013400 | 0.000000000 | 100.00 | 0.00 | System.Collections.I

    CallStack
       at FluentAssertions.Execution.XUnit2TestFramework.Throw(String message)
       at FluentAssertions.Execution.TestFrameworkProvider.Throw(String message)
       at FluentAssertions.Execution.DefaultAssertionStrategy.HandleFailure(String message)
       at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc)
       at Microsoft.DotNet.CoreSetup.Test.CommandResultAssertions.HaveStdOut(String expectedOutput) in /_/src/installer/tests/TestUtils/Assertions/CommandResultAssertions.cs:line 51
       at HostActivation.Tests.StandaloneAppActivation.NoDepsJson_NoRuntimeConfig() in /_/src/installer/tests/HostActivation.Tests/StandaloneAppActivation.cs:line 55
       at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
       at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)

Was this helpful? Yes No