Skip to content

Commit

Permalink
[Clang][OpenMP]Solved the the always truth condition in Arm64
Browse files Browse the repository at this point in the history
There was a bug in the getAArch64MTV function on the third if statement which returns truth  as reported by this issue [[ #61319 |[Clang] Condition is always true which is caused by a possible copy-pasted bug in CGOpenMPRuntime.cpp
 ]].
All the testcases are passing. The first unit tests I could find are for functions that are 6 levels from this issue. The function is very low level and couldn't find a way to affect it from the higher functions.

Reviewed By: jhuber6

Differential Revision: https://reviews.llvm.org/D146370
  • Loading branch information
samuelmaina authored and xgupta committed May 6, 2023
1 parent 9ad45b4 commit c1ab198
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clang/lib/CodeGen/CGOpenMPRuntime.cpp
Expand Up @@ -11160,7 +11160,7 @@ static bool getAArch64MTV(QualType QT, ParamKindTy Kind) {
if (Kind == ParamKindTy::Uniform)
return false;

if (Kind == ParamKindTy::LinearUVal || ParamKindTy::LinearRef)
if (Kind == ParamKindTy::LinearUVal || Kind == ParamKindTy::LinearRef)
return false;

if ((Kind == ParamKindTy::Linear || Kind == ParamKindTy::LinearVal) &&
Expand Down

0 comments on commit c1ab198

Please sign in to comment.