[PATCH] D135263: [ValueTracking][SimplifyLibCalls] Fix bug in getConstantDataArrayInfo for wchar_t
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 5 06:10:34 PDT 2022
nikic added a reviewer: nikic.
nikic added inline comments.
================
Comment at: llvm/lib/Analysis/ValueTracking.cpp:4269
+ assert((StartIdx % ElementSizeInBytes) == 0 &&
+ "Constant offset not a multiple of the ElementSize.");
+ Offset += StartIdx / ElementSizeInBytes;
----------------
I don't think this assertions holds. What happens if you have something like `getelementptr i8, ptr @ws, i64 3`?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D135263/new/
https://reviews.llvm.org/D135263
More information about the llvm-commits
mailing list