-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Permalink
Choose a base ref
{{ refName }}
default
Choose a head ref
{{ refName }}
default
Comparing changes
Choose two branches to see what’s changed or to start a new pull request.
If you need to, you can also or
learn more about diff comparisons.
Open a pull request
Create a new pull request by comparing changes across two branches. If you need to, you can also .
Learn more about diff comparisons here.
base repository: dotnet/runtime
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: f6bed512
Could not load branches
Nothing to show
Loading
Could not load tags
Nothing to show
{{ refName }}
default
Loading
...
head repository: dotnet/runtime
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 2819a944
Could not load branches
Nothing to show
Loading
Could not load tags
Nothing to show
{{ refName }}
default
Loading
- 6 commits
- 69 files changed
- 5 contributors
Commits on Feb 21, 2023
-
Fix generic parameter data flow validation in NativeAOT (#82392)
[This is a revert of a revert of #81532 with additional fixes for #81779] This reworks how generic parameter data flow validation is done in the NativeAOT compiler. Previously generic data flow was done from generic dictionary nodes. Problem with that approach is that there's no origin information at that point. The warnings can't point to the place where the problematic instantiation is in the code - we only know that it exists. Aside from it being unfriendly for the users, it means any RUC or suppressions don't work on these warnings the same way they do in linker/analyzer. This change modifies the logic to tag the method as "needs data flow" whenever we spot an instantiation of an annotated generic in it somewhere. Then the actual validation/marking is done from data flow using the trim analysis patterns. The only exception to this is generic data flow for base types and interface implementations, that one is done on the EEType nodes. Note that AOT implements a much more precise version of the generic data flow validation as compared to linker/analyzer. See the big comment at the beginning of `GenericParameterWarningLocation.cs` for how that works. Due to an issue with DependencyInjection, this change also implements a behavior where if a method or field is reflection accessible, the compiler will perform generic argument data flow on all types in the signature of the method/field (which it normally wouldn't do). See #81358 for details about the issue and discussions on the fix approach. Due to the DI behavior described above, there's also the problem with nested generics. If a nested generic applies annotation on a specific type and this whole thing is done from within a DI, the compiler will not apply the annotation, since it doesn't see the type being used anywhere for real. See #81779 for detailed description of the issue. The fix for this is to extend the "needs data flow analysis" logic to look into generic arguments recursively and finding any annotation then triggers the data flow processing of the calling code. Then in that processing when applying generic argument data flow, do so recursively over all generic parameters. Test changes: Adds the two tests from linker which cover this functionality. Change the test infra to use token to compare message origins for expected warnings. Consistently converting generic types/methods into strings across two type systems is just very difficult - the tokens are simple and reliable. Changes the tests to avoid expecting specific generic types/methods formatting in the messages - again, it's too hard to make this consistent without lot of effort. And the tests don't really need it. Adds a test for marking behavior related to generic argument data flow. This is to catch issues like #81779. Adds a smoke test which has a simplified version of the DI problem from #81358. Fixes #77455 Fixes #75898 Fixes #81358 Fixes #81779
Configuration menu - View commit details
-
Copy full SHA for 463954d - Browse repository at this point
Copy the full SHA 463954dView commit details -
Configuration menu - View commit details
-
Copy full SHA for a4c9243 - Browse repository at this point
Copy the full SHA a4c9243View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1a321fd - Browse repository at this point
Copy the full SHA 1a321fdView commit details -
[RISC-V] others except coreclr (#82382)
* [RISCV-V] others except coreclr - Successfully cross-build for RISC-V. - Run A simple application "helloworld" - Fail a test in clr.paltest * Add risc-v * Put riscv64 to the last
Configuration menu - View commit details
-
Copy full SHA for ff10999 - Browse repository at this point
Copy the full SHA ff10999View commit details -
Fix GetHashCode implementation for InterproceduralState (#82431)
This is a port of dotnet/linker#3163 to runtime repo.
Configuration menu - View commit details
-
Copy full SHA for 9507a9c - Browse repository at this point
Copy the full SHA 9507a9cView commit details -
Expose missing BinaryPrimitives APIs (#82310)
* Expose missing BinaryPrimitives APIs * Fix the BinaryPrimitives doc comments to match the actual documentation * Use newer BinaryPrimitives APIs where applicable
Configuration menu - View commit details
-
Copy full SHA for 2819a94 - Browse repository at this point
Copy the full SHA 2819a94View commit details
Loading
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff f6bed512...2819a944