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
Poor code quality for Interlocked.{Compare}Exchange(nint) #47266
Comments
The easiest fix is probably to just expand it: EgorBo@34fdd14 Or we can convert Interlocked intrinsics to the new-style NamedIntrinsics and handle it there. |
I have left a few comments on the commit.
That would be nice too. But the easiest fix above is still useful to reduce number of FCalls. |
Fixes dotnet/runtime#47266 Co-authored-by: EgorBo <EgorBo@users.noreply.github.com>
C#:
Result on .NET 5 (x64):
I would expect the JIT to expand the
nint
methods to the exact same code as either theint
orlong
methods.The text was updated successfully, but these errors were encountered: