-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
.NET 7 AOT x86/x64 Unable to build a method of a generic class that returns Type #79710
Comments
Happens on all platforms. |
This happens because the the bb->needs_decompose flag is not propagated by some optimizations in branch-opts.c. |
jandupej
added a commit
to jandupej/runtime
that referenced
this issue
Dec 20, 2022
marek-safar
removed
the
untriaged
New issue has not been triaged by the area owner
label
Dec 20, 2022
jandupej
added a commit
that referenced
this issue
Dec 20, 2022
carlossanlop
pushed a commit
that referenced
this issue
Jan 6, 2023
Co-authored-by: Jan Dupej <[email protected]>
ghost
locked as resolved and limited conversation to collaborators
Feb 9, 2023
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
From @akravch on Mon, 12 Dec 2022 15:50:00 GMT
Android application type
Android for .NET (net6.0-android, etc.)
Affected platform version
.NET 7.0.100
Description
Can't build an app for x86 or x64 if there is a method that satisfies the following conditions:
Type
if
,switch
or a ternary operator)typeof(T)
Same code compiles just fine for ARM/ARM64 with .NET 7, or any runtime including x86/x64 with .NET 6.
Repro steps below or just see this repo: https://github.com/akravch/net_7_aot_issue
Steps to Reproduce
<RuntimeIdentifiers>android-x64</RuntimeIdentifiers>
<RunAOTCompilation>true</RunAOTCompilation>
Expected:
The build has succeeded
Actual:
AOT compilation failed
Did you find any workaround?
Any of the following methods would work:
Although, in my case the issue actually comes from a NuGet package, so applying the workaround is somewhat complicated.
Relevant log output
Also attaching a binlog: binlog.zip
Copied from original issue dotnet/android#7631
The text was updated successfully, but these errors were encountered: