[PATCH] D134380: [GlobalISel] Fix known bits for G_ASSERT_ALIGN.
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 21 13:58:34 PDT 2022
arsenm added inline comments.
================
Comment at: llvm/lib/CodeGen/GlobalISel/GISelKnownBits.cpp:42
// TODO: Min with source
- int64_t LogAlign = MI->getOperand(2).getImm();
- return Align(1ull << LogAlign);
+ return Align(std::max(1LL, MI->getOperand(2).getImm()));
}
----------------
This might have been a misuse
================
Comment at: llvm/lib/CodeGen/GlobalISel/GISelKnownBits.cpp:475
case TargetOpcode::G_ASSERT_ALIGN: {
- int64_t LogOfAlign = MI.getOperand(2).getImm();
- if (LogOfAlign == 0)
----------------
I thought 0 would be rejected by the verifier. This shouldn’t have been produced
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134380/new/
https://reviews.llvm.org/D134380
More information about the llvm-commits
mailing list