Skip to content

ILLink takes a mysteriously long time to process Microsoft.Graph #87050

Closed
@NickDarvey

Description

@NickDarvey

Description

  1. Clone https://github.com/microsoftgraph/msgraph-sample-maui
  2. Remove bundle resource 'appSettings.Development.json' from project
  3. Run dotnet publish -c Release -f net7.0-ios16.1 -r ios-arm64

Alternatively, these alternate repros might work on Windows:

cc @vitek-karas, @filipnavara

Data

Including Microsoft.Graph.dll in the ILLink task
msbuild_.6.zip
ILLink duration: 52 mins 53 seconds

Excluding Microsoft.Graph.dll
msbuild_(7).zip
ILLink duration: 3 mins 10 seconds

Configuration

  • dotnet SDK 7.0.102
  • macOS Ventura 13.13.1
  • 2017 MacBook Pro (Intel)

Analysis

  • Microsoft.Graph.dll is only being copied/skipped by the linker, not actually trimmed.
  • The last log line I see before ILLink wanders off into the wilderness for 50 mins is
    ILLink: Cannot inline constant result of 'System.Data.DataCommonEventSource.EnterScope<T1,T2>(String, T1, T2)' call due to presence of side effects
    
    then when it resumes, the next log line is
    ILLink: Processing embedded substitution descriptor 'ILLink.Substitutions.xml' from 'System.Runtime.InteropServices, Version=7.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
    
    (but I'm not sure if that's helpful if it's doing things in parallel)
  • RE: PublishTrimmed causing dotnet publish to hang #86379 (comment)
    @filipnavara, if you have any guidance on how I can profile the linker like this I'll happily do it and post the results back here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-Tools-ILLink.NET linker development as well as trimming analyzerstenet-performancePerformance related issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions