[PATCH] D18258: Have DataLayout::isLegalInteger accept a uint64_t
Michael Kuperstein via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 17 19:40:13 PDT 2016
mkuper added a comment.
Thanks, Mehdi!
================
Comment at: include/llvm/IR/DataLayout.h:239
@@ -238,3 +238,3 @@
/// The width is specified in bits.
- bool isLegalInteger(unsigned Width) const {
+ bool isLegalInteger(uint64_t Width) const {
for (unsigned LegalIntWidth : LegalIntWidths)
----------------
joker.eph wrote:
> I guess the case where `Width > MAX_INT_BITS` is rare enough that it's not worth an early exit here?
Yeah, had the same thought, I think it's most probably not worth it.
================
Comment at: test/Transforms/SROA/pr26972.ll:10
@@ +9,3 @@
+ %t0 = bitcast [1073741825 x i32]* %a to i8*
+ call void @llvm.lifetime.end(i64 4294967300, i8* %t0)
+ ret void
----------------
joker.eph wrote:
> Add a comment specifying that this constant is intended to trigger 32 bits overflow.
Right, thanks!
http://reviews.llvm.org/D18258
More information about the llvm-commits
mailing list