[PATCH] D64084: [AArch64][GlobalISel] Teach tryOptSelect to handle G_ICMP
Jessica Paquette via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 3 11:34:27 PDT 2019
paquette marked an inline comment as done.
paquette added inline comments.
================
Comment at: llvm/trunk/lib/Target/AArch64/AArch64InstructionSelector.cpp:2816
+ LLT CmpTy = MRI.getType(LHS.getReg());
+ assert(CmpTy.isScalar() || CmpTy.isPointer() && "Expected scalar or pointer");
+ if (CmpTy == LLT::scalar(32)) {
----------------
bjope wrote:
> This looks incorrect ( `&&` has higher precedence than `||` ). So I assume it should be
>
> assert((CmpTy.isScalar() || CmpTy.isPointer()) && "Expected scalar or pointer");
>
> And we get a warning when building with gcc:
>
> ../lib/Target/AArch64/AArch64InstructionSelector.cpp:2938:48: error: suggest parentheses around '&&' within '||' [-Werror=parentheses]
> assert(CmpTy.isScalar() || CmpTy.isPointer() && "Expected scalar or pointer");
Oh, you're right! Should be fixed in r365069.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D64084/new/
https://reviews.llvm.org/D64084
More information about the llvm-commits
mailing list