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

Some ASP.NET Core 10.0 dlls are not R2R compiled #111997

Open
tmds opened this issue Jan 30, 2025 · 4 comments
Open

Some ASP.NET Core 10.0 dlls are not R2R compiled #111997

tmds opened this issue Jan 30, 2025 · 4 comments
Labels
area-ReadyToRun-coreclr untriaged New issue has not been triaged by the area owner

Comments

@tmds
Copy link
Member

tmds commented Jan 30, 2025

As part of our test suite, we have a test that checks .NET's dlls are R2R compiled.

That test is failing for these ASP.NET Core 10.0 dlls:

Microsoft.AspNetCore.Metadata.dll
Microsoft.AspNetCore.ResponseCaching.Abstractions.dll

To determine whether the assembly is R2R we check PEHeaders.CorHeader.ManagedNativeHeaderDirectory.Size != 0 (cfr #1802 (comment)).

The check is passing for the other ASP.NET Core dlls. The two dlls that fail don't have much in them (some interface definitions).

I wonder if there has been a change to crossgen which would causes these dlls to be skipped for R2R?

The check passes for the 9.0 version of these dlls.

cc @jkoritzinsky @jkotas @omajid @nicrowe00

@dotnet-policy-service dotnet-policy-service bot added the untriaged New issue has not been triaged by the area owner label Jan 30, 2025
@jkotas
Copy link
Member

jkotas commented Jan 30, 2025

I wonder if there has been a change to crossgen which would causes these dlls to be skipped for R2R?

I am not aware of any.

Do you see crossgen2 running on these assemblies in your build log? Does it produce any errors?

@tmds
Copy link
Member Author

tmds commented Jan 30, 2025

I don't see any errors in the log, and I found:

Emitting R2R PE file: /home/tester/dotnet/src/aspnetcore/artifacts/obj/Microsoft.AspNetCore.App.Runtime.Composite/Release/fedora.40-x64/R2R/Microsoft.AspNetCore.Metadata.dll

I took a look in the aspnetcore repo, and I didn't find a reason why this project would be treated differently from the others (which are passing the R2R check).

I'll do a local build so I can see if any Microsoft.AspNetCore.Metadata.dll in aspnetcore artifacts pass the check.

@EgorBo
Copy link
Member

EgorBo commented Jan 30, 2025

@tmds are you sure that the assembly has functions to prejit? if it's only a bunch of interfaces/facades, then presumably there is no work for R2R. From a quick look, Microsoft.AspNetCore.Metadata looks to be so - isn't just an assembly with just two interfaces?

@jkotas
Copy link
Member

jkotas commented Jan 30, 2025

@tmds are you sure that the assembly has functions to prejit?

crossgen2 will produce R2R image even if there is no code to compile. R2R image has other good stuff in addition to the code, for example indexes for some metadata tables.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-ReadyToRun-coreclr untriaged New issue has not been triaged by the area owner
Projects
None yet
Development

No branches or pull requests

3 participants