[PATCH] D14590: [SimplifyLibCalls] Constant folding for fls, flsl, flsll
Davide Italiano via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 14 18:30:28 PST 2016
davide added a comment.
In https://reviews.llvm.org/D14590#623196, @davide wrote:
> SimplifyLibCalls needs to know how to translate the pair `(DataLayout, C99 type)` -> `LLVM IR Type` in order to make this transformation. Until then, there's no reliable way to know how big a `long` is and that could cause a wrong constant folding of `fls()`. I haven't audited all the transformations here, but I wouldn't be surprised if other functions are incorrectly transformed assuming sizes of primitive types.
https://llvm.org/bugs/show_bug.cgi?id=31385
https://reviews.llvm.org/D14590
More information about the llvm-commits
mailing list