Skip to content

Commit

Permalink
Fix Interlocked.Or/And for arm64 (#91557)
Browse files Browse the repository at this point in the history
  • Loading branch information
EgorBo authored Sep 6, 2023
1 parent 1487d46 commit 23987d2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
6 changes: 1 addition & 5 deletions src/coreclr/jit/importercalls.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9200,8 +9200,6 @@ NamedIntrinsic Compiler::lookupNamedIntrinsic(CORINFO_METHOD_HANDLE method)
{
if (strcmp(className, "Interlocked") == 0)
{
#ifndef TARGET_ARM64
// TODO-CQ: Implement for XArch (https://github.com/dotnet/runtime/issues/32239).
if (strcmp(methodName, "And") == 0)
{
result = NI_System_Threading_Interlocked_And;
Expand All @@ -9210,9 +9208,7 @@ NamedIntrinsic Compiler::lookupNamedIntrinsic(CORINFO_METHOD_HANDLE method)
{
result = NI_System_Threading_Interlocked_Or;
}
else
#endif
if (strcmp(methodName, "CompareExchange") == 0)
else if (strcmp(methodName, "CompareExchange") == 0)
{
result = NI_System_Threading_Interlocked_CompareExchange;
}
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/jit/lsraarm64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1044,8 +1044,8 @@ int LinearScan::BuildNode(GenTree* tree)
}
setInternalRegsDelayFree = true;
}
buildInternalRegisterUses();
}
buildInternalRegisterUses();
if (dstCount == 1)
{
BuildDef(tree);
Expand Down

0 comments on commit 23987d2

Please sign in to comment.